Game Development Reference
In-Depth Information
velocity) corresponds to an infinite acceleration, and this can create many
problems. If the path is used to control a physical object, such as a robot
or cutting tool, then we are asking for the motors driving the object to do
something that is physically impossible. Even if the animation is taking
place entirely inside of the virtual world of a computer, when such paths
are observed by humans, they are usually perceived as “jerky.” Thus it's
usually desirable to avoid (or at least control) velocity discontinuities. In
contrast, a sudden change in acceleration does not create such a jarring
sensation and for most purposes is perfectly acceptable.
Any individual polynomial curve segment by itself has C continuity,
since we can take the derivative of a polynomial as many times as we want
and we always get a real-valued, continuous function. (Eventually, the
derivatives become the constant zero function.) This is why the question
of continuity didn't arise earlier in the chapter—the only places we have to
worry about continuity are at the knots.
One last comment regarding higher derivatives. When we say that a
curve is C n continuous, this implies continuity for all lower derivatives as
well. For example, if the acceleration is continuous, then the velocity and
position must also be continuous. A discontinuity in a function means that
the function's derivative is undefined where the discontinuity occurs.
Now that we've discussed parametric continuity informally, let's define
the criteria mathematically for Hermite and Bezier curves. To do so, we
make use of some observations concerning the derivatives of Bezier curves
from Section 13.4.3; our findings from that section are summarized here.
The nth derivative at an endpoint of a Bezier curve segment is com-
pletely determined by the endpoint and the nearest n control points.
The velocity at an endpoint is proportional to the vector between
the endpoint and the adjacent control point (Equations (13.30) and
(13.31)).
The acceleration at an endpoint is proportional to the difference of the
delta vectors along the nearest two segments of the control polygon
(Equations (13.36) and (13.37)).
Let's start with C 0 , which is a no-brainer due to our choice of notation.
In our scheme, the ending point of one segment is the same as the starting
point of the next segment by definition. Moving on to C 1 continuity, we've
said that it occurs when the tangents are equal at a key. This translates
directly to Hermite form as
C 1 continuity condition
for Hermite splines
v i i = v ou i ,
Search WWH ::




Custom Search