Search code examples
graphicsgeometrybeziersplinecurve

Closest point on a cubic Bezier curve?


How can I find the point B(t) along a cubic Bezier curve that is closest to an arbitrary point P in the plane?


Solution

  • After lots of searching I found a paper that discusses a method for finding the closest point on a Bezier curve to a given point:

    Improved Algebraic Algorithm On Point Projection For Bezier Curves, by Xiao-Diao Chen, Yin Zhou, Zhenyu Shu, Hua Su, and Jean-Claude Paul.

    Furthermore, I found Wikipedia and MathWorld's descriptions of Sturm sequences useful in understanding the first part of the algoritm, as the paper itself isn't very clear in its own description.