3D Viewing
3D Viewing
COMPUTER GRAPHICS 1
Three Dimensional
Viewing
3D Viewing
The steps for computer generation of a
view of a three dimensional scene are
somewhat analogous to the processes
involved in taking a photograph.
Camera Analogy
1. Viewing position
2. Camera orientation
3. Size of clipping window
Orientation
Window (aperture)
of the camera
Position
Viewing Pipeline
The general processing steps for modeling and
converting a world coordinate description of a scene to
device coordinates:
Viewing Pipeline
1. Construct the shape of individual objects in a scene
within modeling coordinate, and place the objects into
appropriate positions within the scene (world
coordinate).
Viewing Pipeline
Before object description can be projected to the view
plane, they must be transferred to viewing coordinates.
World coordinate positions are converted to viewing
coordinates.
Viewing Coordinates
Viewing coordinates
system described 3D
objects with respect to a
viewer.
A Viewing (Projector)
plane is set up
perpendicular to zv and
aligned with (xv,yv).
Camera Analogy
Specifying the Viewing Coordinate
System (View Reference Point)
We first pick a world coordinate position called view
reference point (origin of our viewing coordinate system).
P0 is a point where a camera is located.
The view reference point is often chosen to be close to or on
the surface of some object, or at the center of a group of
objects. y
w
z w
P 0
xw
Position
Look
Look Vector
and Up Vectors
the direction the camera is pointing
three degrees of freedom; can be any vector in 3-
space
Up Vector
determines how the camera is rotated around the
Look vector
for example, whether you’re holding the camera
horizontally or vertically (or in between)
projection of Up vector must be in the plane
perpendicular to the look vector (this allows Up
Projection
vector toof
beup
vector
Up vector
specified at anLook
arbitrary
vector angle to its
Look vector)
Position
Transformation from World to
Viewing Coordinates
Transformation sequence from world to viewing
coordinates:
M W C ,VC
R R R T
z y z
Viewing Pipeline
3. Convert the viewing coordinate description of the
scene to coordinate positions on the projection plane.
Viewing Pipeline
4. Positions on the projection plane, will then mapped to
the Normalized coordinate and output device.
Obtain a Series of View
To obtain a series of view of a scene, we can
keep the view reference point fixed and
change the direction of N.
Simulate Camera Motion
To simulate camera motion through a scene, we
can keep N fixed and move the view reference
point around.
Projection
Viewing Pipeline
Convert the viewing coordinate description of the scene to
coordinate positions on the projection plane.
Viewing 3D objects on a 2D display requires a mapping
from 3D to 2D.
Projection
Projection can be defined as a mapping of point
P(x,y,z) onto its image P ( x , y , z ) in the projection
plane.
The mapping is determined by a projector that
passes through P and intersects the view plane ( P ).
Projection
Projectors are lines from center (reference) of
projection through each point in the object.
The result of projecting an object is dependent
on the spatial relationship among the projectors
and the view plane.
Projection
x p x, yp y
1 0 0 0
0 1 0 0
M
0 0 0 0
Orthographic Parallel
0 0 0 1
Oblique
Parallel Projection
Oblique Parallel Projection
Projection are not perpendicular to the viewing
plane.
Angles and lengths are preserved for faces parallel
the plane of projection.
Preserves 3D nature of an object.
Oblique
Parallel Projection
Transformation
Oblique Parallel Projection
Transformation
Convert the viewing coordinate description of the
scene to coordinate positions on the Oblique parallel
projection plane.
Oblique Parallel Projection
Point (x,y,z) is projected to position (x ,y ) on the view plane.
p p
x p x, yp y
L
1 0 0 0
0 1 0 0
M
0 0 0 0
Orthographic Parallel
0 0 0 1
Oblique Parallel Projection
Angles, distances, and parallel
lines in the plane are projected
accurately.
Cavalier Projection
Cavalier Projection:
30
and 45
tan 1
45
Lines perpendicular to the viewing plane project at ½ of their
length.
A more realistic view than the cavalier projection.
Can display a combination of front, and side, and top views.
Cavalier & Cabinet Projection
Cavalier Cabinet
Perspective Projection
Perspective Projection
Perspective Projection
In a perspective projection, the center of projection is
at a finite distance from the viewing plane.
Produces realistic views but does not preserve
relative proportion of objects
The size of a projection object is inversely
proportional to its distance from the viewing plane.
Perspective Projection
Parallel lines that are not parallel to the viewing
plane, converge to a vanishing point.
A vanishing point is the projection of a point at
infinity.
Vanishing Points
Each set of projected parallel lines will have a
separate vanishing points.
There are infinity many general vanishing points.
Perspective Projection
The vanishing point for any set of lines that are parallel to
one of the principal axes of an object is referred to as a
principal vanishing point.
We control the number of principal vanishing points (one,
two, or three) with the orientation of the projection plane.
Perspective Projection
The number of principal vanishing
points in a projection is determined by
the number of principal axes
intersecting the view plane.
Perspective Projection