Graphics Reference
In-Depth Information
that starts at
T
(
P
)=
101
T
when
t
=
0 and arrives at
T
(
Q
)=
513
T
when
t
=
1, and whose equation is
(
t
)=
101
+
t
412
The function
T
transforms this to the line
(10.122)
=
T
(
P
)+
t
(
T
(
Q
)
−
T
(
P
))
.
(10.123)
w
Figure 10.27 shows the line in 3-space, after transformation by
T
M
; the point spac-
ing remains constant.
y
We know that this is the parametric equation of the line, because
every
lin-
ear transformation transforms parametric lines to parametric lines. But when we
apply
H
, something interesting happens. Because the function
H
is
not linear,
the parametric line is
not
transformed to a parametric line. The point
x
(
t
)=
Figure 10.27: After transforma-
tion by T
M
, the points are still
equispaced.
1
+
4
tt
1
+
2
t
T
is sent to
⎡
⎤
(
1
+
4
t
)
/
(
1
+
2
t
)
⎣
⎦
m
(
t
)=
t
/
(
1
+
2
t
)
1
(10.124)
⎡
⎤
⎡
⎤
1
0
1
2
1
0
t
1
+
2
t
⎣
⎦
+
⎣
⎦
=
(10.125)
Equation 10.125 has
almost
the form of a parametric line, but the coefficient
of the direction vector, which is proportional to
S
(
Q
)
y
−
S
(
P
)
, has the form
at
+
b
ct
+
d
,
(10.126)
which is called a
fractional linear transformation
of
t
. This nonstandard form
is of serious importance in practice: It tells us that if we interpolate a value at
the midpoint
M
of
P
and
Q
, for instance, from the values at
P
and
Q
, and then
transform all three points by
S
, then
S
(
M
)
will generally
not
be at the midpoint
of
S
(
P
)
and
S
(
Q
)
, so the interpolated value will not be the correct one to use if
we need post-transformation interpolation. Figure 10.28 shows how the equally
spaced points in the domain have become unevenly spaced after the projective
transformation.
x
Figure 10.28: After homogeniza-
tion, the points are no longer
equispaced.
In other words, transformation by
S
and interpolation are not commuting
operations. When we apply a transformation that includes the homogenization
operation
H
, we cannot assume that interpolation will give the same results
pre- and post-transformation. Fortunately, there's a solution to this problem (see
Section 15.6.4).
Inline Exercise 10.28:
(a) Show that if
n
and
f
are distinct nonzero numbers,
the transformation defined by the matrix
⎡
⎤
f
fn
0
f
−
f
01 0
10 0
n
n
−
⎣
⎦
,
N
=
(10.127)
when followed by homogenization, sends the line
x
=
0 to infinity, the line
x
=
n
to
x
=
0, and the line
x
=
f
to
x
=
1.
(b) Figure out how to modify the matrix to send
x
=
f
to
x
=
−
1 instead.