Graphics Programs Reference
In-Depth Information
The parametric equation of the straight segment connecting P 3 to P 4 is (see Equa-
tion (Ans.7))
L 2 ( w )= w ( P 4 P 3 )+ P 3 = w (1 / 5 ,
9 / 10) + (0 , 1 / 2)
for
0
w
1 ,
and the parametric equation of the straight segment connecting P 1 to P 2 is
L 1 ( u )= u ( P 2 P 1 )+ P 1 = u (0 ,
4 / 3) + (1 , 3 / 2)
for
0
u
1 ,
the point is that although the original segments P 1 P 2 and P 3 P 4 are parallel, the two
projected segments are not parallel. They meet at point L 1 (33 / 8) = L 2 (5) = (1 ,
4).
Another way to prove that the two projected line segments converge is to show that
they are not parallel by computing and comparing their directions (or slopes). It's easy
to see that P 2
P 1 =(0 ,
4 / 3) but P 4
P 3 =(1 / 5 ,
9 / 10). Line segment L 1 moves
straight down, whereas L 2 hasaslopeof(
9 / 10) / (1 / 5) =
4 . 5.
Exercise 3.7: Select two line segments that are perpendicular to the line of sight of
the viewer, and show that their projections on the xy plane are parallel.
1 , 0 , 1), P 2 =(0 , 1 , 2), and
P 3 =(1 , 1 , 3) and compute the Bezier curve P ( t ) defined by them
Projecting curves . We select the three points P 1 =(
t ) 2 (
t )(0 , 1 , 2) + t 2 (1 , 1 , 3) .
P ( t )=(1
1 , 0 , 1) + 2 t (1
The midpoint of this curve is
P (0 . 5) = (
1 / 4 , 0 , 1 / 4) + (0 , 1 / 2 , 1) + (1 / 4 , 1 / 4 , 3 / 4) = (0 , 3 / 4 , 2) .
We now project the three original points and obtain
P 1 =
(1 / 1) + 1 , 0 =(
P 2 = 0 ,
=(0 , 1 / 3) ,
1
1
(2 / 1) + 1
1 / 2 , 0) ,
P 3 = 1
=(1 / 4 , 1 / 4) .
1
(3 / 1) + 1
(3 / 1) + 1 ,
The Bezier curve defined by these points is
P ( t )=(1
t ) 2 (
t )(0 , 1 / 3) + t 2 (1 / 4 , 1 / 4) .
1 / 2 , 0) + 2 t (1
The point of this example is that the projection of P (0 . 5), which is (0 , 1 / 4), is not
located on P ( t ). This illustrates the nonlinear nature of the Bezier curve (as well as
most other curves).
Search WWH ::




Custom Search