Spline Interpolation

Yet another method of interpolation is splines, of which B-splines, Cubic Hermite splines, and NURBS (non-uniform ration B-spline) are just a few of the options. In general, a spline is a smooth piecewise function interpolating between its control points, also called knots. In the case of NURBS, a spline is determined by weighting the control point values to the line, similar to calculating a line of best fit for a set of data. As you have undoubtedly noticed, this is more beneficial than harmful. While you may not have the exact same points plotted on the spline as defined by your control points, the interpolation between the points is more consistent. Polynomial interpolation, on the other hand, falls into the trap that is Runge’s phenomenon: using a high order polynomial to interpolate points and ending up with a wildly oscillating function.

Splines are widely used in graphics. They can be used to interpolate a surface as defined by a set of points. If you have never used a 3D modeling program, picture this: you have a box, and only by adding more points (and subsequent edges/surfaces) can you create a character. Even assuming you are the best mouse-artist in the world, its going to turn out “boxy”. NURBS will allow you to work with a smooth object, though still defined by the same “box points” and weights them based on their distance from the surface.

Splines are also used in the actual animation, making your “box” character move. For instance: to make a dog’s tail wag back and forth, you would key a frame with the tail pointing to the left, another frame with the tail pointed to the right, and if you are really daring, maybe a frame somewhere in the middle. But to simply watch those 3 keyframes would be boring and unrealistic, like watching a rod wave back and forth. In reality, the tip of the tail would be the last part of the tail to reach its destination. This time lag in different parts of the tail can be easily achieved by using… a spline!

Check out a cubic spline for yourself:

http://www.wam.umd.edu/~petersd/interp.html

http://en.wikipedia.org/wiki/Spline_interpolation

Posted in Topics: Uncategorized

Jump down to leave a comment.

Leave a Comment

You must be logged in to post a comment.



* You can follow any responses to this entry through the RSS 2.0 feed.