Online Maps  v3.3
OnlineMapsProjectionSphericalMercator Class Reference

Implementation of WGS84 Spherical Mercator (Web Mercator). More...

Inheritance diagram for OnlineMapsProjectionSphericalMercator:
OnlineMapsProjection

Public Member Functions

override void CoordinatesToTile (double lng, double lat, int zoom, out double tx, out double ty)
 Converts geographic coordinates to tile coordinates. More...
 
override void TileToCoordinates (double tx, double ty, int zoom, out double lng, out double lat)
 Converts tile coordinates to geographic coordinates. More...
 

Additional Inherited Members

- Public Attributes inherited from OnlineMapsProjection
const double DEG2RAD = Math.PI / 180
 Degrees-to-radians conversion constant. More...
 
const double PI2 = Math.PI * 2
 PI * 2 More...
 
const double PI4 = Math.PI * 4
 PI * 4 More...
 
const double RAD2DEG = 180 / Math.PI
 Radians-to-degrees conversion constant. More...
 

Detailed Description

Implementation of WGS84 Spherical Mercator (Web Mercator).

Member Function Documentation

◆ CoordinatesToTile()

override void OnlineMapsProjectionSphericalMercator.CoordinatesToTile ( double  lng,
double  lat,
int  zoom,
out double  tx,
out double  ty 
)
virtual

Converts geographic coordinates to tile coordinates.

Parameters
lngLongitude
latLatitude
zoomZoom
txTile X
tyTile Y

Implements OnlineMapsProjection.

◆ TileToCoordinates()

override void OnlineMapsProjectionSphericalMercator.TileToCoordinates ( double  tx,
double  ty,
int  zoom,
out double  lng,
out double  lat 
)
virtual

Converts tile coordinates to geographic coordinates.

Parameters
txTile X
tyTile Y
zoomZoom
lngLongitude
latLatitude

Implements OnlineMapsProjection.