Function Curve2D.getClosestPoint

Returns the closest point (in curve's local space) to to_point. to_point must be in this curve's local space.

Vector2 getClosestPoint (
  const(Vector2) to_point
) nothrow @nogc const;