While Catmull Rom splines have the nice property of going through the control points and are "continuous enough" for most applications, they sometimes behave unpredictably. Namely, the points of highest curvature on the resulting curve are not always where the control points lie.
A solution for this is to use what is called Centripetal Parameterization which focuses more sampled points on the highest areas of curvature (the term derives from the way a car would slow down when navigating sharp turns, unless driven by this guy).
The general idea is:
t i+1 = t i + |P i +1 - P i] ^ a // Where (0<= a <=1) (0 is Uniform,.5 is Centripetal and 1 is Chordal).
Note: This is a different type of parameterization than Chord length reparameterization (see attached slide showing adjusting the number of points between spans without altering the curve itself). Centripetal alters the trajectory of the curve, similar to the way a Kochanek Bartels spline applies Tension, but unique.
There are many articles on this subject. Two of the best I found are Parameterization and Applications of Catmull-Rom Curvesand the original E T Y Lee article Choosing nodes in parametric curve interpolation, but they don't seem to explain in layman terms how to go about modifying an existing CR algorithm to make the required changes (ideally there would be an adjustable alpha to blend from Uniform (a=0) to Centripetal (a=.5) to Chordal (a=1.0), but I'm not sure if that refers to blending the results of two functions or if the alpha value really plugs in (it is raised to the power of a so it's square root for Centripetal).
Does anyone have the actual CR algorithm that implements Centripetal Parameterization? How different from the original CR algorithm is it and how much does it cost?
With KB splines it's only a few lines difference, but not something you could improvise without a math Ph. D.
Thanks in advance!
Edited by Catmull Dog, 03 August 2012 - 06:48 AM.