public abstract class AbstractWMSTileSource extends TMSTileSource
| Modifier and Type | Field and Description |
|---|---|
private EastNorth |
anchorPosition |
private double[] |
degreesPerTile |
private static float |
SCALE_DENOMINATOR_ZOOM_LEVEL_1 |
private Projection |
tileProjection |
private int[] |
tileXMax |
private int[] |
tileXMin |
private int[] |
tileYMax |
private int[] |
tileYMin |
maxZoom, minZoom, osmMercatorbaseUrl, id, modTileFeatures, name, tileSizeattributionImage, attributionImageURL, attributionLinkURL, attributionText, termsOfUseText, termsOfUseURL| Constructor and Description |
|---|
AbstractWMSTileSource(TileSourceInfo info,
Projection tileProjection)
Constructs a new
AbstractWMSTileSource. |
| Modifier and Type | Method and Description |
|---|---|
private TileXY |
eastNorthToTileXY(EastNorth enPoint,
int zoom) |
private double |
getDegreesPerTile(int zoom) |
java.lang.String |
getServerCRS()
Get coordinate reference system for this tile source.
|
protected EastNorth |
getTileEastNorth(int x,
int y,
int z) |
Projection |
getTileProjection() |
int |
getTileXMax(int zoom)
Get maximum x index of tile for specified zoom level.
|
int |
getTileXMin(int zoom)
Get minimum x index of tile for specified zoom level.
|
int |
getTileYMax(int zoom)
Get maximum y index of tile for specified zoom level.
|
int |
getTileYMin(int zoom)
Get minimum y index of tile for specified zoom level
|
private void |
initAnchorPosition(Projection proj) |
void |
initProjection()
Initializes class with current projection in JOSM.
|
void |
initProjection(Projection proj)
Initializes class with projection in JOSM.
|
TileXY |
latLonToTileXY(double lat,
double lon,
int zoom)
Transforms longitude and latitude to tile indices.
|
TileXY |
latLonToTileXY(ICoordinate point,
int zoom)
Transforms longitude and latitude to tile indices.
|
java.awt.Point |
latLonToXY(double lat,
double lon,
int zoom)
Transforms longitude and latitude to pixel space (as if all tiles at specified zoom level where joined).
|
java.awt.Point |
latLonToXY(ICoordinate point,
int zoom)
Transforms longitude and latitude to pixel space (as if all tiles at specified zoom level where joined).
|
TileXY |
projectedToTileXY(IProjected p,
int zoom)
Convert projected coordinates to tile indices.
|
void |
setTileProjection(Projection tileProjection) |
ICoordinate |
tileXYToLatLon(int x,
int y,
int zoom)
Transforms tile indices to longitude and latitude.
|
ICoordinate |
tileXYToLatLon(Tile tile)
Determines to longitude and latitude of a tile.
|
ICoordinate |
tileXYToLatLon(TileXY xy,
int zoom)
Transforms tile indices to longitude and latitude.
|
IProjected |
tileXYtoProjected(int x,
int y,
int zoom)
Convert tile indices (x/y/zoom) into projected coordinates of the tile origin.
|
ICoordinate |
xyToLatLon(int x,
int y,
int zoom)
Transforms a point in pixel space to longitude/latitude (WGS84).
|
ICoordinate |
xyToLatLon(java.awt.Point point,
int zoom)
Transforms a point in pixel space to longitude/latitude (WGS84).
|
getCoveringTileRange, getDistance, getMaxZoom, getMinZoom, isInsidegetBaseUrl, getDefaultTileSize, getExtension, getId, getMetadata, getName, getTileId, getTilePath, getTileSize, getTileUrl, isModTileFeatures, isNoTileAtZoom, toStringgetAttributionImage, getAttributionImageURL, getAttributionLinkURL, getAttributionText, getTermsOfUseText, getTermsOfUseURL, requiresAttribution, setAttributionImage, setAttributionImageURL, setAttributionLinkURL, setAttributionText, setTermsOfUseText, setTermsOfUseURLprivate EastNorth anchorPosition
private int[] tileXMin
private int[] tileYMin
private int[] tileXMax
private int[] tileYMax
private double[] degreesPerTile
private static final float SCALE_DENOMINATOR_ZOOM_LEVEL_1
private Projection tileProjection
public AbstractWMSTileSource(TileSourceInfo info, Projection tileProjection)
AbstractWMSTileSource.info - tile source infotileProjection - the tile projectionprivate void initAnchorPosition(Projection proj)
public void setTileProjection(Projection tileProjection)
public Projection getTileProjection()
public void initProjection()
public void initProjection(Projection proj)
proj - new projection that shall be used for computationspublic ICoordinate tileXYToLatLon(Tile tile)
TileSourcetileXYToLatLon in interface TileSourcetileXYToLatLon in class AbstractTMSTileSourcetile - Tilepublic ICoordinate tileXYToLatLon(TileXY xy, int zoom)
TileSourcetileXYToLatLon in interface TileSourcetileXYToLatLon in class AbstractTMSTileSourcexy - X/Y tile indiceszoom - zoom levelpublic ICoordinate tileXYToLatLon(int x, int y, int zoom)
TileSourcetileXYToLatLon in interface TileSourcetileXYToLatLon in class TMSTileSourcex - x tile indexy - y tile indexzoom - zoom levelprivate TileXY eastNorthToTileXY(EastNorth enPoint, int zoom)
public TileXY latLonToTileXY(double lat, double lon, int zoom)
TileSourcelatLonToTileXY in interface TileSourcelatLonToTileXY in class TMSTileSourcelat - latitudelon - longitudezoom - zoom levelpublic TileXY latLonToTileXY(ICoordinate point, int zoom)
TileSourcelatLonToTileXY in interface TileSourcelatLonToTileXY in class AbstractTMSTileSourcepoint - pointzoom - zoom levelpublic int getTileXMax(int zoom)
TileSourcegetTileXMax in interface TileSourcegetTileXMax in class AbstractTMSTileSourcezoom - zoom levelpublic int getTileXMin(int zoom)
TileSourcegetTileXMin in interface TileSourcegetTileXMin in class AbstractTMSTileSourcezoom - zoom levelpublic int getTileYMax(int zoom)
TileSourcegetTileYMax in interface TileSourcegetTileYMax in class AbstractTMSTileSourcezoom - zoom levelpublic int getTileYMin(int zoom)
TileSourcegetTileYMin in interface TileSourcegetTileYMin in class AbstractTMSTileSourcezoom - zoom levelpublic java.awt.Point latLonToXY(double lat, double lon, int zoom)
TileSourcelatLonToXY in interface TileSourcelatLonToXY in class TMSTileSourcelat - latitudelon - longitudezoom - zoom levelpublic java.awt.Point latLonToXY(ICoordinate point, int zoom)
TileSourcelatLonToXY in interface TileSourcelatLonToXY in class AbstractTMSTileSourcepoint - pointzoom - zoom levelpublic ICoordinate xyToLatLon(java.awt.Point point, int zoom)
TileSourcexyToLatLon in interface TileSourcexyToLatLon in class AbstractTMSTileSourcepoint - pointzoom - zoom levelpublic ICoordinate xyToLatLon(int x, int y, int zoom)
TileSourcexyToLatLon in interface TileSourcexyToLatLon in class TMSTileSourcex - X coordinatey - Y coordinatezoom - zoom levelprotected EastNorth getTileEastNorth(int x, int y, int z)
private double getDegreesPerTile(int zoom)
public IProjected tileXYtoProjected(int x, int y, int zoom)
TileSourcetileXYtoProjected in interface TileSourcetileXYtoProjected in class TMSTileSourcex - x tile indexy - z tile indexzoom - zoom levelpublic TileXY projectedToTileXY(IProjected p, int zoom)
TileSourceprojectedToTileXY in interface TileSourceprojectedToTileXY in class TMSTileSourcep - projected coordinateszoom - zoom levelpublic java.lang.String getServerCRS()
TileSourcegetServerCRS in interface TileSourcegetServerCRS in class TMSTileSource