MapTrip SDK Android Manual 9.9.7
Projection Class Reference

The SDK returns and expects coordinates in the "internal" projection. If you pass a coordinate to the SDK's methods or receive coordinates from the SDK, use this class to transform it in your representation
More...

Static Public Member Functions

static native Position internalCoordinatesToWGS84 (Position internalCoord)
 
static native Position toInternalCoordinates (CoordinateSystem projection_in, Position pos_in)
 
static native Position WGS84ToInternalCoordinates (Position wgsCoord)
 

Detailed Description

Currently the internal projection is "mercator" (EPSG 3857). If you provide coordinates already in mercator, we highly suggest to use the transformation methods for internal coordinates when you pass locations to the SDK. In that case you are safe if the internal SDK representations is changed in the future.

Attention
WGS84 coordinates come in (longitude, latitude) order, which is consequently (x, y)

Member Function Documentation

◆ internalCoordinatesToWGS84()

static native Position internalCoordinatesToWGS84 ( Position  internalCoord)
static

Projects internal coordinates to WGS84 coordinates

Parameters
internalCoordto project (x-position (easting), y-position (northing))
Returns
pos of WGS84 coordinates (longitude (easting) is x, latitude (northing) is y)

◆ toInternalCoordinates()

static native Position toInternalCoordinates ( CoordinateSystem  projection_in,
Position  pos_in 
)
static

Projects coordinates in a coordinate system defined in CoordinateSystem to SDK internal coordinates

Parameters
projection_in- specifies with which projection the passed coordinates shall be transformed based on CoordinateSystem.
pos_in- position in specified projection
Returns
pos in internal coordinates

◆ WGS84ToInternalCoordinates()

static native Position WGS84ToInternalCoordinates ( Position  wgsCoord)
static

Projects WGS84 coordinates to the internal coordinates

Parameters
wgsCoord(longitude (easting) is x, latitude (northing) is y)
Returns
pos in internal coordinates (x-position (easting), y-position (northing))

The documentation for this class was generated from the following file: