Home > @magiclane/maps-sdk > Coordinates
Coordinates class
Coordinates class
Signature:
export declare class Coordinates Constructors
|
Constructor |
Modifiers |
Description |
|---|---|---|
|
Create a coordinates object from latitude, longitude and altitude. |
Properties
|
Property |
Modifiers |
Type |
Description |
|---|---|---|---|
|
number |
(Optional) Altitude in meters. It can be negative. | ||
|
|
Create a new coordinates object with the same properties as the original. | ||
|
number |
(Optional) Horizontal accuracy of the location in meters. | ||
|
|
boolean |
Checks if the coordinates are valid | |
|
number |
Latitude in degrees. Valid values -90.0 .. +90.00. It is positive towards the north pole. Negative values are towards the south pole. At the Equator the value is 0. | ||
|
number |
Longitude in degrees. Valid values -180.0 .. +180.00. It is positive towards the east. Negative values are towards the west. At the Greenwich meridian the value is 0. | ||
|
number |
(Optional) Parent scene object to which coordinates belongs. Scene object id. | ||
|
number |
(Optional) Vertical accuracy of the location in meters. |
Methods
|
Method |
Modifiers |
Description |
|---|---|---|
|
Calculates the azimuth (bearing) from this coordinate to target. The azimuth is computed according to the ellipsoid model of WGS84 and returned in degrees. If the points are effectively identical or invalid, the method returns 0.0. | ||
|
copyWithMetersOffset({ metersLatitude, metersLongitude, }, input) |
Creates a new coordinates object with the given meters offset | |
|
Calculate the distance in meters between two WGS84 coordinates. | ||
|
| ||
|
|
Create a coordinates object from latitude, longitude and optional altitude. | |