Class: LonLat

og/LonLat~LonLat

new LonLat(lon, lat, height)

Represents a geographical point with a certain latitude, longitude and height.
Name Type Description
lon number optional Longitude.
lat number optional Latitude.
height number optional Height over the surface.

Members

heightnumber

Height.

latnumber

Latitude.

lonnumber

Longitude.

Methods

staticmodule:og/LonLat~LonLat.createFromArray(arr){og.LonLat}

Creates an object by coordinate array.
Name Type Description
arr Array.<number, number, number> Coordiante array, where first is longitude, second is latitude and third is a height.
Returns:
Type Description
og.LonLat -

staticmodule:og/LonLat~LonLat.forwardMercator(lon, lat, height){og.LonLat}

Converts degrees to mercator coordinates.
Name Type Description
lon number Degrees longitude.
lat number Degrees latitude.
height number optional Height.
Returns:
Type Description
og.LonLat -

staticmodule:og/LonLat~LonLat.inverseMercator(x, y, height){og.LonLat}

Converts mercator to degrees coordinates.
Name Type Description
x number Mercator longitude.
y number Mercator latitude.
height number optional Height.
Returns:
Type Description
og.LonLat -

staticmodule:og/LonLat~LonLat.join()

Creates coordinates array.

clone(){og.LonLat}

Clone the coordiante.
Returns:
Type Description
og.LonLat -

copy(lonLat){og.LonLat}

Copy coordinates.
Name Type Description
lonLat og.LonLat optional Coordinates to copy.
Returns:
Type Description
og.LonLat -

equal(b){boolean}

Compares coordinates.
Name Type Description
b og.LonLat Coordinate to compare with.
Returns:
Type Description
boolean -

forwardMercator(){og.LonLat}

Converts to mercator coordinates.
Returns:
Type Description
og.LonLat -

inverseMercator(){og.LonLat}

Converts from mercator coordinates.
Returns:
Type Description
og.LonLat -

set(lon, lat, height){og.LonLat}

Sets coordinates.
Name Type Description
lon number optional Longitude.
lat number optional Latitude.
height number optional Height.
Returns:
Type Description
og.LonLat -