Previous Next


                                              330
CHAPTER 4                                                                              Graphics



those of the two intermediate control points by p10 … p13 and p20 … p23 . Equiva-
lently, the patch can be considered to be traced by a cubic Bézier curve moving
from the left edge to the right, with its control points following the trajectories
defined by the rows of the coordinate array instead of the columns.

The Coons patch (type 6) is actually a special case of the tensor-product patch
(type 7) in which the four internal control points (p11 , p12 , p21 , p22 ) are implicitly
defined by the boundary curves. The values of the internal control points are giv-
en by these equations:
p 11 = 1 ⁄ 9 ×
       [ – 4 × p 00 + 6 × ( p 01 + p 10 ) – 2 × ( p 03 + p 30 ) + 3 × ( p 31 + p 13 ) – 1 × p 33 ]
p 12 = 1 ⁄ 9 ×
       [ – 4 × p 03 + 6 × ( p 02 + p 13 ) – 2 × ( p 00 + p 33 ) + 3 × ( p 32 + p 10 ) – 1 × p 30 ]
p 21 = 1 ⁄ 9 ×
       [ – 4 × p 30 + 6 × ( p 31 + p 20 ) – 2 × ( p 33 + p 00 ) + 3 × ( p 01 + p 23 ) – 1 × p 03 ]
p 22 = 1 ⁄ 9 ×
       [ – 4 × p 33 + 6 × ( p 32 + p 23 ) – 2 × ( p 30 + p 03 ) + 3 × ( p 02 + p 20 ) – 1 × p 00 ]

In the more general tensor-product patch, the values of these four points are un-
restricted.

The coordinates of the control points in a tensor-product patch are actually spec-
ified in the shading’s data stream in the following order:

   4     5      6      7
   3    14     15      8
   2    13     16      9
   1    12     11     10

All control point coordinates are expressed in the shading’s target coordinate
space. These are followed by the color values for the four corners of the patch, in
the same order as the corners themselves. If the patch’s edge flag f is 0, all 16
control points and four corner colors must be explicitly specified in the data
stream. If f is 1, 2, or 3, the control points and colors for the patch’s shared edge
are implicitly understood to be the same as those along the specified edge of the
previous patch and are not repeated in the data stream. Table 4.36 summarizes
the data values for various values of the edge flag f, expressed in terms of the row
and column indices used in Figure 4.24 above. See “Type 4 Shadings (Free-Form

Previous Next