Graphics Reference
In-Depth Information
As expected, when we increase the camera y -position, we begin to see more of
the squares. However, as we continue to increase the camera y -position, we notice
that the squares begin to disappear from the top region of the application window.
Recall that the visible volume is defined with respect to the camera position. In
this tutorial, by default, the visible volume has the near plane located at 18 units
and the far plane located at 36 units from the camera position. As we move the
camera position, the visible volume, being 18 units in front of the camera, is
also moving away from the squares. As the camera and the visible volume move
sufficiently far away, the squares are clipped by the far plane. We can verify this
by increasing the far plane value to see the squares appearing again. We can also
verify the near plane clipping by adjust the near plane slider bar. As we increase
the near plane slider bar value, we see the front edge of the squares being cut away
and disappear from the image.
The “Width” and “Height” slider bars control the width and height of the near
and far plane (and thus the image plane). Notice that if the
width
height ratio is different
from the aspect ratio of the application window, the squares will appear to be
squashed or stretched.
From this tutorial, we verify the rectangular visible volume. We also see that
images generated by orthographic projection do not seem natural and do not re-
semble our expectations of objects in 3D space. However, we also see the strength
of size preservation. Notice that we can use a ruler and measure the relative
edges of the two squares.
For example, the front edge of the large square (8
units) is 1
6 times longer than that of the small square (5 units). In typical non-
engineering/non-scientific computer graphics application, we seldom work with
orthographic projection. In the rest of this topic, we will only work with perspec-
tive projection .
.
14.2.2
Perspective Projection: A Viewing Frustum
Field of view (FOV). In prac-
tice, depending on the graph-
ics API, field of view may ei-
ther refer to the vertical angle
that subtends the height of the
image plane or the horizontal
angle that subtends the width
of the image plane. For exam-
ple, D3D defines the field-of-
view angle to be the vertical
angle.
Figure 14.10 shows a viewing frustum , an alternative way of specifying a visi-
ble volume. As we can see, a viewing frustum is a cut-off pyramid where the
apex is the camera position, with the view vector piercing from the camera posi-
tion through the center of the pyramid. As in the case of the rectangular visible
volume, the near plane and far plane are n and f units away from the camera,
respectively, and are perpendicular to the view vector. The near plane cuts away
the top portion of the pyramid. Once again, it is convenient to consider this plane
being the image plane. The field of view (FOV) is the vertical angle that subtends
the height of the near (image) plane from the camera position. As illustrated in
Figure 14.10, this angle defines the angular height of the view frustum. The an-
Search WWH ::




Custom Search