Skip to content

GeoCoordinate beta

A geographic coordinate. Construct one for a point of interest, or receive a live fix from environment.location.current() (which additionally populates horizontalAccuracy and timestamp).

Static Methods

_fromFix()

javascript
GeoCoordinate._fromFix(): void

Build a GeoCoordinate from a native fix dictionary.

Returns: void

Instance Methods

distanceTo()

javascript
distanceTo(other: GeoCoordinate): number

Great-circle distance to another coordinate, in metres (haversine, 6371 km).

Parameters:

Returns: number

bearingTo()

javascript
bearingTo(other: GeoCoordinate): number

Initial great-circle bearing to another coordinate, in degrees (0–360, from north).

Parameters:

Returns: number