Game Development Reference
In-Depth Information
which is a “regular” and independent curve satisfying the goals outlined at
the start of this section.
However, the ensuing algebra gruntwork produces a messy result with-
out revealing any insight. The main thing we wish to communicate here is
that subdivision of a curve in monomial form is a simple matter of reparam-
eterization, which can be accomplished algebraically. Furthermore, because
we can convert between monomial forms and other forms, we now have a
surefire method for subdividing any polynomial curve in any format.
But we need not be satisfied with this “brute force” approach; as it
turns out, in Bezier form, we can do better.
13.5.2
Subdividing Curves in B ezier Form
Subdivision of a Bezier curve can be done geometrically through a variant of
the de Casteljau algorithm. The full algorithm of extracting any subsection
for arbitrary endpoint parameters a and b is not immediately grasped, so
we follow Farin [20, Section 7.2ff] and start off with a simple case.
We begin by restricting ourselves to extracting only the “left side” of a
curve. In other words, we fix a = 0. Clearly, the first Bezier control point
on the smaller curve (at s = 0) is the same as the first control point on
the larger curve (at t = 0). Equally clear is that the endpoint at t = b
is obtainable by the basic de Casteljau algorithm from Section 13.4.1. An
example situation with b = 0.75 is illustrated in Figure 13.16.
Figure 13.16
Locating the interior
endpoint using the
de Casteljau
algorithm
We have the endpoints—now for those tricky interior points. Surpris-
ingly, if you look closely at Figure 13.16, you'll notice that we already
constructed them! As it turns out, each round of de Casteljau interpola-
tion produces one of our Bezier control points. Figure 13.17 makes this
clearer, showing the selected Bezier points and the control polygon.
Why does this work? Recall the relationship between the Bezier form
and the Hermite form from Section 13.4.3. The first interior control point
 
Search WWH ::




Custom Search