GeodesicRuler

Constructors

Link copied to clipboard
constructor()

Functions

Link copied to clipboard
open override fun along(line: LineString, dist: Double): LngLatAlt

Returns the point at a specified distance along the line.

Link copied to clipboard
open override fun bearing(a: LngLatAlt, b: LngLatAlt): Double
Link copied to clipboard
open override fun destination(p: LngLatAlt, dist: Double, bearing: Double): LngLatAlt

Returns a new point given distance and bearing from the starting point.

Link copied to clipboard
open override fun distance(a: LngLatAlt, b: LngLatAlt): Double
Link copied to clipboard

Returns an object of the form {point, index, t}, where point is closest point on the line from the given point, index is the start index of the segment with the closest point, and t is a parameter from 0 to 1 that indicates where the closest point is on that segment.

Link copied to clipboard

Returns the distance from a point p to a line segment a to b.