flo_curves
flo_curves copied to clipboard
[Feature request] Can there be functions to calculate point to curve distance?
I have a feature request, if would be great if there are functions to calculate point to curve distance.
Thanks!
I've added nearest_t(), nearest_point() and distance_to() functions to do this in the v0.7 branch. These all find the closest point using a Newton-Raphson search.
Note that t_for_point() and curve_intersects_ray() are other ways to find nearby points on the curve that can be used to compute distances from v0.6: they won't find the strictly closest point, but their behaviour is easier to predict for interactive applications.