Hello guys,
I am trying to deconstruct what’s under common how tools work. I was wondering how to compute the shortest distance between a curve and an arbitrary point in python without using any libraries.
Anyone could help me on this ?
Thanks
Hello guys,
I am trying to deconstruct what’s under common how tools work. I was wondering how to compute the shortest distance between a curve and an arbitrary point in python without using any libraries.
Anyone could help me on this ?
Thanks
Hi undoredo,
Is this what you are looking for:
https://developer.rhino3d.com/api/RhinoCommon/html/M_Rhino_Geometry_Curve_ClosestPoint.htm
succ, closest_t = crv.ClosestPoint(pt)
closest_pt = crv.PointAt(closest_t)
this might have your (partial) answer, but really, for most problems you can just google them and work on understanding the mathematics behind them and transfer them to code.