distanceToLineString

fun distanceToLineString(lineStringCoordinates: LineString, nearestPoint: LngLatAlt? = null): Double

Distance to a LineString from current location.

Return

The distance of the point to the LineString

Parameters

lineStringCoordinates

LineString that we are working out the distance from

nearestPoint

Point in the line nearest that had the shortest distance