Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Functions

  • Returns the unsigned area of a closed path, in the range [0, 2×pi×radius²]. The computed area uses the same units as the radius. The radiusOfSphere defaults to the Earth's radius in meters, in which case the area is in square meters. Passing a Circle requires the radius to be set to a non-negative value. Additionally, the Circle must not cover more than 100% of the sphere. And when passing a LatLngBounds, the southern LatLng cannot be more north than the northern LatLng.

    Parameters

    Returns number

  • Returns the distance, in meters, between two LatLngs. You can optionally specify a custom radius. The radius defaults to the radius of the Earth.

    Parameters

    Returns number

  • Returns the heading from one LatLng to another LatLng. Headings are expressed in degrees clockwise from North within the range [-180,180).

    Parameters

    Returns number

  • Returns the LatLng resulting from moving a distance from an origin in the specified heading (expressed in degrees clockwise from north).

    Parameters

    Returns LatLng

  • Returns the location of origin when provided with a LatLng destination, meters travelled and original heading. Headings are expressed in degrees clockwise from North. This function returns null when no solution is available.

    Parameters

    Returns LatLng | null

  • Returns the signed area of a closed path, where counterclockwise is positive, in the range [-2×pi×radius², 2×pi×radius²]. The computed area uses the same units as the radius. The radius defaults to the Earth's radius in meters, in which case the area is in square meters.

    The area is computed using the parallel transport method; the parallel transport around a closed path on the unit sphere twists by an angle that is equal to the area enclosed by the path. This is simpler and more accurate and robust than triangulation using Girard, l'Huilier, or Eriksson on each triangle. In particular, since it doesn't triangulate, it suffers no instability except in the unavoidable case when an edge (not a diagonal) of the polygon spans 180 degrees.

    Parameters

    Returns number

Generated using TypeDoc