|
|
Mike Raiford wrote:
> The article speaks of derivatives, so calculus must be involved. I'm
> gathering that the formulae in the algorithm were probably found by
> applying calculus to a 3rd order polynomial.
>
> http://en.wikipedia.org/wiki/Cubic_spline
Or they were derived by calculating which coefficients will yield
continuity in the first derivative. And maybe the second.
I am presently note-scribbling for a scene-building feature for my
modeler, and I want something that is simple and C2 continuous when the
user specifies continuity at a point. I've decided to use the limit
curves of a subdivided border (end points stay still, new mid points are
the average of the start and end of the edge, and new interior points
are calculated on a 1-6-1 mask). The result is a cubic spline with C0,
C1, and C2 continuity. It does not necessarily pass through the control
points, but I have a work-around for that.
C2 continuity is important in animation; if the two spline ends meet in
the middle of a curve, and the object moving along the curve is tilted
to show its acceleration, then any discontinuity at the join will result
in the sudden change in the tilt of the object. This is usually undesired.
Regards,
John
Post a reply to this message
|
|