angus.wood Posted November 21, 2014 Posted November 21, 2014 This may be off-topic, but is there a method to calculate the coordinates on a spline for a given distance down that spline? I am thinking of describing the movement of a series of objects as splines but I can't seem to figure out a method of getting the coordinates to move the objects to when all I know is the spline and the distance down the spline.
angus.wood Posted November 21, 2014 Author Posted November 21, 2014 Figured it out. The trick is http://en.wikipedia.org/wiki/De_Casteljau%27s_algorithm Treat the spline as having length 0..1 and subdivide it in steps until a single value is present. And the last two terms that you subdivide give you the tangent to the spline so we can know which direction to point things in.
Recommended Posts