pixelRelativeToLeftUpper method

Mappoint pixelRelativeToLeftUpper(
  1. ILatLong latLong,
  2. Mappoint leftUpper
)

Calculates the absolute pixel position for a tile and tile size relative to origin

@param latLong the geographic position. @param tile tile @return the relative pixel position to the origin values (e.g. for a tile)

Implementation

Mappoint pixelRelativeToLeftUpper(ILatLong latLong, Mappoint leftUpper) {
  Mappoint mappoint = latLonToPixel(latLong);
  return mappoint.offset(-leftUpper.x, -leftUpper.y);
}