closestPointTo

open fun closestPointTo(point: P): P

Finds the point of the segment which is closest to the provided point.