Examples of WMTTileFactory


Examples of org.locationtech.udig.catalog.internal.wmt.tile.WMTTile.WMTTileFactory

            return Collections.emptyMap();
        }
       
        ReferencedEnvelope extent = normalizeExtent(renderJob.getMapExtentTileCrs());
       
        WMTTileFactory tileFactory = getTileFactory();
               
        WMTZoomLevel zoomLevel = tileFactory.getZoomLevel(getZoomLevelToUse(renderJob.getZoomLevelMatcher(),
                scaleFactor, recommendedZoomLevel, layerProperties), this);
        long maxNumberOfTiles = zoomLevel.getMaxTileNumber();
               
        Map<String, Tile> tileList = new HashMap<String, Tile>();
       
        WMTPlugin.debug("[WMTSource.cutExtentIntoTiles] Zoom-Level: " + zoomLevel.getZoomLevel() //$NON-NLS-1$
                " Extent: " + extent, Trace.REQUEST); //$NON-NLS-1$
       
        // Let's get the first tile which covers the upper-left corner
        WMTTile firstTile = tileFactory.getTileFromCoordinate(
                extent.getMaxY(), extent.getMinX(), zoomLevel, this);
        tileList.put(firstTile.getId(), addTileToList(firstTile));
       
        WMTTile firstTileOfRow = null;
        WMTTile movingTile = firstTileOfRow = firstTile;
View Full Code Here

Examples of org.locationtech.udig.catalog.internal.wmt.tile.WMTTile.WMTTileFactory

   
    @Test
    public void testGetTileFromCoordinate() {
       
        NASAZoomLevel zoomLevel = source.getZoomLevel(0);
        WMTTileFactory tileFactory = source.getTileFactory();
       
        NASATile tile = (NASATile) tileFactory.getTileFromCoordinate(90, -180, zoomLevel, source);       
        assertEquals("Global Mosaic, pan sharpened visual_0_0_0", tile.getId());
       
        NASATile tile2 = (NASATile) tileFactory.getTileFromCoordinate(-90, -180, zoomLevel, source);       
        assertEquals("Global Mosaic, pan sharpened visual_0_0_2", tile2.getId());
       
        NASATile tile3 = (NASATile) tileFactory.getTileFromCoordinate(-90, -115, zoomLevel, source);       
        assertEquals("Global Mosaic, pan sharpened visual_0_1_2", tile3.getId());
    }
View Full Code Here

Examples of org.locationtech.udig.catalog.internal.wmt.tile.WMTTile.WMTTileFactory

   
    @Test
    public void testGetTileFromCoordinateUSA() {
       
        NASAZoomLevel zoomLevel = sourceUSA.getZoomLevel(3);
        WMTTileFactory tileFactory = sourceUSA.getTileFactory();
       
        NASATile tile = (NASATile) tileFactory.getTileFromCoordinate(50, -125, zoomLevel, sourceUSA);       
        assertEquals("Continental US Elevation_3_0_0", tile.getId());
       
        NASATile tile2 = (NASATile) tileFactory.getTileFromCoordinate(39, -125, zoomLevel, sourceUSA);       
        assertEquals("Continental US Elevation_3_0_1", tile2.getId());
       
        NASATile tile3 = (NASATile) tileFactory.getTileFromCoordinate(39, -114, zoomLevel, sourceUSA);       
        assertEquals("Continental US Elevation_3_1_1", tile3.getId());
    }
View Full Code Here

Examples of org.locationtech.udig.catalog.internal.wmt.tile.WMTTile.WMTTileFactory

     * @param zoomLevel
     * @param wmtSource
     * @return
     */
    private WMTTile getCenterTile(int zoomLevel, WMTSource wmtSource) {
        WMTTileFactory tileFactory = wmtSource.getTileFactory();
        WMTZoomLevel zoomLevelInstance = tileFactory.getZoomLevel(zoomLevel, wmtSource);
       
        // get the coordinates of the map centre (in TileCrs)
        Coordinate centerPoint = mapExtentTileCrs.centre();
       
        return tileFactory.getTileFromCoordinate(
                centerPoint.y,
                centerPoint.x,
                zoomLevelInstance,
                wmtSource);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.