Graphics Reference
In-Depth Information
CTM
Homo-
genize
Homo-
genize
CMTM
CMTM
M per
M per
M pp
M pp
M view
M view
Standard perspective view
volume coordinates
Object
coordinates
World
coordinates
Clip
coordinates
Normalized
device coordinates
Window
coordinates
Eye
coordinates
Projection
matrix K
Homo-
genize
Proo ection
matrix K
Projection
matrix K
Homo-
genize
Homo-
genize
CMTM
CMTM
N
N
M view
M view
CMTM
N
M view
Model view matrix
Model view projection matrix
Figure 13.19: OpenGL transformations compared to our transformations.
OpenGL defines another matrix—the projection matrix—that performs the
transformation to the pre-homogenization standard parallel view volume. If we
call this K , then the correspondence with the matrices we've defined is
KN = M pp M per .
(13.21)
A comparison of the OpenGL sequence of transformations and ours is shown
in Figure 13.19.
y 5 1/2
Inline Exercise 13.7: Let's return to the two-robots-talking example. Assume
that the first robot's right hand is modeled as a unit cube (
1
1
2
x , y , z
2 ),
2 face being attached to the wrist and its y = 2 face being the
one that's on top when the arms are held in front of the robot (see Figure 13.20),
and that the CMTM for this cube is the matrix H . Now suppose that the hand
is actually a camera whose eye position is at the center of the z = 2 face (in
modeling coordinates), shown as a red dot in the figure. The camera has a 90
field of view, both vertical and horizontal, a near-plane distance of 0. 5, and a
far-plane distance of 10. Describe how to find M per for this camera so that you
can show what the first robot “sees” with its hand camera. Your answer should
involve H .
1
with its z =
Figure 13.20: The robot hand's
sides.
P 1
13.8 Orthographic Cameras
P 2
While perspective projections are familiar to us from ordinary photographs, many
images are created using parallel projections or orthographic projections. In
these projections, we project from the world to the film plane not using a collec-
tion of lines that all meet at the eyepoint, but instead using a collection of parallel
lines. Imagine a perspective camera with a “film plane” at a fixed location in space,
but whose eyepoint moves farther and farther from the film plane, resulting in the
lines of projection becoming increasingly parallel (Figure 13.21); we can thus
P 3
Figure 13.21: Perspective cam-
eras becoming more and more
parallel.
 
 
 
Search WWH ::




Custom Search