VirtualPixelCoordinate

A VirtualPixelCoordinate object contains the x and y coordinates of a pixel in the virtual pixel space of the entire map image.

Note: Do not confuse coordinates in the virtual pixel space of the entire map image with normal screen pixel coordinates. Normal screen pixel coordinates always start with (0, 0) at the top left corner of the screen, regardless of what section of the entire map image is currently displayed in the screen. In contrast, the virtual pixel space of the map image is constant at any particular zoom level, regardless of what part of the map is currently displayed in the screen. So, for example, if a map image is set to zoom level 3, the map image is composed of 4 tiles across and 4 tiles down. If each tile has dimensions of 512 by 256 pixels, then the dimensions of the entire map image are 2048 by 1024 pixels. This is referred to as the virtual pixel space of the map image, because only a subsection of the entire image may be displayed in the screen at any one time.

When a VirtualPixelCoordinate object is returned in a JSON object, the VirtualPixelCoordinate object is always located in a JSON field named virtualPixelCoord.

Fields

A VirtualPixelCoordinate object contains the following fields:

Field Name Type Description
virtualX Integer The x coordinate of the virtual pixel. The x coordinate numbering starts at the left edge of the left-most tile of the map image, at number 0.
virtualY Integer The y coordinate of the virtual pixel. The y coordinate numbering starts at the top edge of the top-most tile of the map image, at number 0.

Example

{
    "virtualX": 256,
    "virtualY": 300
}