Graphics Reference
In-Depth Information
Figure 1.3.
The window-to-device
pipeline.
representation
of 3d world
objects
transform
into camera
coordinates
clip
against
view volume
Æ
Æ
Æ
transform
to
viewport
project
to
view plane
Transform to
physical device
coordinates
Æ
Æ
Æ
Figure 1.4.
The basic 3d graphics pipeline.
The two-dimensional graphics pipeline is similar but much simpler. The window-
to-device pipeline shown in Figure 1.3 stays the same, but Figures 1.2 and 1.4 get
replaced by Figures 1.5 and 1.6, respectively. We have a two-dimensional world coor-
dinate system and a window whose edges are parallel to the coordinate axes. In the
case of the three-dimensional graphics pipeline, one usually assumes that the window
is of a fixed size centered on the z-axis of the camera coordinate system. This is ade-
quate to achieve most views of the world. To move the viewpoint and change the view
direction we simply change the camera coordinate system. Zooming in and out is
accomplished by moving the view plane further from or closer to the viewpoint. In
the two-dimensional graphics case, on the other hand, one must allow the window to
move and change in size. We have to be able to move the window to see different parts
of the two-dimensional world and we must be able to shrink or expand the size of the
window to zoom.
One word of caution is in order. The distinction between “window” and “view-
port” is often blurred and, sometimes, what should be called a viewport is called a
window. The terms used are not as important as the conceptual difference. One spec-
ifies what one sees in user coordinates and the other specifies where one sees it. The
window, as defined above, refers to the former and the viewport, to the latter.
Search WWH ::




Custom Search