Online Maps v3
Loading...
Searching...
No Matches
OnlineMapsProjection Class Referenceabstract

The base class of map projection. More...

Inheritance diagram for OnlineMapsProjection:
OnlineMapsProjectionSphericalMercator OnlineMapsProjectionWGS84

Public Member Functions

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

Static Public Attributes

const double DEG2RAD = Math.PI / 180
 Degrees-to-radians conversion constant.
 
const double PI2 = Math.PI * 2
 PI * 2.
 
const double PI4 = Math.PI * 4
 PI * 4.
 
const double RAD2DEG = 180 / Math.PI
 Radians-to-degrees conversion constant.
 

Detailed Description

The base class of map projection.

Member Function Documentation

◆ CoordinatesToTile()

void OnlineMapsProjection.CoordinatesToTile ( double lng,
double lat,
int zoom,
out double tx,
out double ty )
abstract

Converts geographic coordinates to tile coordinates.

Parameters
lngLongitude
latLatitude
zoomZoom
txTile X
tyTile Y

◆ TileToCoordinates()

void OnlineMapsProjection.TileToCoordinates ( double tx,
double ty,
int zoom,
out double lng,
out double lat )
abstract

Converts tile coordinates to geographic coordinates.

Parameters
txTile X
tyTile Y
zoomZoom
lngLongitude
latLatitude