globalmapper.ConvertCoordPixelToGround

globalmapper.ConvertCoordPixelToGround(sint32 aPixelX, sint32 aPixelY, GM_Rectangle_t aWorldBounds, GM_PixelRect_t aPixelRect) GM_Error_t32, float, float[source]

Convert a coordinate between pixel space and the current projection. The conversion space can be either the last drawn coordinate space or the caller can provide the coordinate space to work in.

Note that the input pixel coordinates are sint32’s. If you want to use floats instead, use the function ConvertCoordPixelToGroundDouble.

Parameters
  • aPixelX (sint32) – X Coord in pixel space

  • aPixelY (sint32) – Y Coord in pixel space

  • aWorldBounds (GM_Rectangle_t) – World bounds to convert from or None for last drawn

  • aPixelRect (GM_PixelRect_t) – Pixel bounds to convert from or None for last drawn

Returns

Error Code

Return type

GM_Error_t32

Returns

X Coord in current projection

Return type

float

Returns

Y Coord in current projection

Return type

float