distanceToLine

open fun distanceToLine(    p: LatLng,     start: LatLng,     end: LatLng): Double

Computes the distance on the sphere between the point p and the line segment start to end.

Return

the distance in meters (assuming spherical earth)

Parameters

p

the point to be measured

start

the beginning of the line segment

end

the end of the line segment