Point#
Waypoints#
- class Waypoint#
Represents a waypoint using latitude, longitude, and optionally, elevation.
- latitude#
Latitude in [-90, 90]
- Type
float
- longitude#
Longitude in [-180, 180]
- Type
float
- elevation#
Elevation in metres above datum (~=sea level)
- Type
int
- time#
An optional time for the point
- Type
Optional[datetime]
- name#
An optional name for the point
- Type
Optional[str]
- description#
An optional description for the point
- Type
Optional[str]
- set(lat: float, lon: float)#
Set the waypoint
- Parameters
lat (float) – Latitude
long – Longitude
Routepoints#
- class Routepoint(Waypoint)#
Represents a routepoint using latitude, longitude, and optionally, elevation. Structurally identical to Waypoint.
- latitude#
Latitude in [-90, 90]
- Type
float
- longitude#
Longitude in [-180, 180]
- Type
float
- elevation#
Elevation in metres above datum (~=sea level)
- Type
int
- time#
An optional time for the point
- Type
Optional[datetime]
- name#
An optional name for the point
- Type
Optional[str]
- description#
An optional description for the point
- Type
Optional[str]
- set(lat: float, lon: float, elev: int)#
Set the routepoint
- Parameters
lat (int) – Latitude
long – Longitude
elev – Elevation
- compare_m(waypoint: Waypoint)#
Get the distance between two routepoints in metres using the haversine formula [3]
- Parameters
waypoint (Waypoint, Waypoint, or Routepoint) – The routepoint to compare this routepoint to
- Returns
The distance in metres
- Return type
float