Package org.geoserver.wms.map

Examples of org.geoserver.wms.map.RenderedImageMap


                subContext.setKeywords(mapContext.getKeywords());
                subContext.setAbstract(mapContext.getAbstract());
                subContext.setTransparent(true);

                // render the map
                RenderedImageMap imageMap;
                try {
                    imageMap = pngProducer.produceMap(subContext);
                } finally {
                    subContext.dispose();
                }
View Full Code Here


        ArgumentCaptor<Map> argument = ArgumentCaptor.forClass(Map.class);
        Mockito.when(mockGWC.dispatchOwsRequest(argument.capture(), (Cookie[]) anyObject()))
                .thenReturn(mockResult);

        BufferedImage image = new BufferedImage(256, 256, BufferedImage.TYPE_INT_ARGB);
        RenderedImageMap fakeDispatchedMap = new RenderedImageMap(new WMSMapContent(), image,
                "image/png");

        RenderedImageMapResponse fakeResponseEncoder = mock(RenderedImageMapResponse.class);
        MimeType mimeType = MimeType.createFromFormat("image/png");
        when(mockGWC.getResponseEncoder(eq(mimeType), (RenderedImageMap) anyObject())).thenReturn(
View Full Code Here

                        + Arrays.toString(metaTile.getMetaGridPos()));
            } else {
                LOGGER.finer("--> " + Thread.currentThread().getName()
                        + " submitting getMap request for meta grid location "
                        + Arrays.toString(metaTile.getMetaGridPos()) + " on " + metaTile);
                RenderedImageMap map;
                try {
                    long requestTime = System.currentTimeMillis();
                    map = dispatchGetMap(tile, metaTile);
                    checkNotNull(map, "Did not obtain a WebMap from GeoServer's Dispatcher");
                    metaTile.setWebMap(map);
View Full Code Here

        RenderedImage imageList = visitor.produce(frameCatalog.getWmsConfiguration());

        // run a single getmap to get the right mime type and map context
        WebMap wmsResponse = wms.getMap(request);

        return new RenderedImageMap(((RenderedImageMap) wmsResponse).getMapContext(), imageList,
                wmsResponse.getMimeType());
    }
View Full Code Here

                subContext.setKeywords(mapContent.getKeywords());
                subContext.setAbstract(mapContent.getAbstract());
                subContext.setTransparent(true);

                // render the map
                RenderedImageMap imageMap;
                try {
                    imageMap = pngProducer.produceMap(subContext);
                } finally {
                    subContext.dispose();
                }
View Full Code Here

               
                // collect the layer
                images.add(((RenderedImageMap)map).getImage());
            }
            RenderedImageList imageList = new RenderedImageList(images);
            return new  RenderedImageMap(mapContent, imageList , map.getMimeType());
        } else if(numElevations > 1 && isMultivaluedSupported) {
            WebMap map = null;
            List<RenderedImage> images = new ArrayList<RenderedImage>();
            for (Object currentElevation : elevations){
                map = executeInternal(mapContent, request, delegate, times, Arrays.asList(currentElevation));
               
                // remove layers to start over again
                mapContent.layers().clear();
               
                // collect the layer
                images.add(((RenderedImageMap)map).getImage());
            }
            RenderedImageList imageList = new RenderedImageList(images);
            return new  RenderedImageMap(mapContent, imageList , map.getMimeType());
        } else {
            return executeInternal(mapContent, request, delegate, times, elevations);   
        }

    }
View Full Code Here

            subContext.setKeywords(mapContent.getKeywords());
            subContext.setAbstract(mapContent.getAbstract());
            subContext.setTransparent(true);

            // render the map
            RenderedImageMap imageMap;
            try {
                imageMap = pngProducer.produceMap(subContext);
            } finally {
                subContext.dispose();
            }
View Full Code Here

TOP

Related Classes of org.geoserver.wms.map.RenderedImageMap

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.