Lecture 19 PPT
Lecture 19 PPT
Graphics
Lecture 19
PROJECTIONS
I
Taqdees A. Siddiqi
[email protected]
Reflection
A reflection can be
performed relative to a
selected reflection axis or
with respect to a selected
reflection plane.
In general, three-dimensional
reflection matrices are set up
similarly to those for two
dimensions. Reflections relative
to a given axis are equivalent to
180 degree rotations.
Reflection of points
relative to the X axis
1 0 0 0
0 1
0 0
0 0 1 0
0 0 0 1
Reflection of points
relative to the Y axis
1 0 0 0
0
1 0 0
0 0 1 0
0 0 0 1
Reflection of points
relative to the xy
plane
1 0 0 0
0 1 0 0
0 0 1 0
0 0 0 1
Shears
• Shearing transformations
can be used to modify object
shapes
• As an example of three-
dimensional shearing, the
following transformation
produces a z-axis shear:
1 0 a 0
0 1 b 0
0 0 1 0
0 0 0 1
Y-axis shear
1 a 0 0
0 1 0
0
0 c 1 0
0 0 0 1
X-axis shear
1 0 0 0
b
1 0 0
c 0 1 0
0 0 0 1
How can we display 3D
point on 2D Screen?
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 or view
plane, which constitutes the
display surface
What is mapping ?
The mapping is determined
by a projection line called
the projector that passes
through P and intersects
the view plane
Methods of Projection
1.Parallel Projection
2.Perspective Projection
• These methods are
used to solve the basic
problems of pictorial
representations
• We can construct
different projections
according to the view
that is desired
Parallel Projection
Parallel Projection
In parallel projection, image
points are found as the
intersection of the view plane
with a projector drawn from the
object point and having a fixed
direction. The direction of
projection is the prescribed
direction for all projections
Parallel projection methods
are used by drafters and
engineers to create
working drawings of an
object which preserve its
scale and shape
Mathematical
Description of a
Parallel Projection
Projection rays (projectors)
emanate from a point called
Center of Projection (COP) and
intersect Projection Plane (PP).
The COP for parallel projectors
is at infinity. The length of a
line on the projection plane is
the same as the "true Length"
There are two different
types of parallel
projections
1.Orthographic
2.Oblique
1) Orthographic
Projection
If the direction of
projection is
perpendicular to the
projection plane then it is
an orthographic
projection.
Axonometric
Orthographic
Projection
Orthographic projections that
show more than one side of
an object are called
axonometric orthographic
projections.
Here are three orthographic views of
an object.
There are three axonometric
projections:
1. Isometric
2. Dimetric
3. Trimetric
1. Isometric
The projection plane intersects
each coordinate axis in the
model coordinate system at an
equal distance or the direction
of projection makes equal
angles with all of the three
principal axes
Isometric Projection for the cube
2. Dimetric
The direction of projection
makes equal angles with
exactly two of the principal
axes
3. Trimetric
The direction of projection
makes unequal angles with
the three principal axes
2) Oblique
Projection
If the direction of projection
is not perpendicular to the
projection plane then it is
an oblique projection
The projectors are not
perpendicular to the
projection plane but
are parallel from the
object to the
projection plane
Transformation
equations for an
orthographic parallel
projection
• If the view plane is placed at
position Zvp along the Z axis.
Then any point (x,y,z) in
viewing coordinates is
transformed to projection
coordinates as:
• Xp = x
• Yp = y
• Where the original Z-
coordinate value is
preserved for the depth
information needed in depth
cueing and visible-surface
determination procedures.
• Point (x,y,z) is projected to
position(Xp,Yp) on the view
plane
• Orthographic projection
coordinates on the plane are
(x,y)
• The oblique projection line
from (x,y,z) to (Xp,Yp) makes
an angle ‘α’ with the line on
the projection plane that joins
(Xp,Yp) and (x, y).
• This line, of length L, is at an
angle Ф with the horizontal
direction in the projection
plane.
• We can express the
projection coordinates in
terms of x, y, L, and Ф as
• cos(Ф) = Xp – x / L
• sin(Ф) = Yp – y / L
• Xp = x + L cos(Ф)
• Yp = y + L sin(Ф)
• Length L depends on the
angle ‘α’ and the z coordinate
of the point to be projected:
• tan (α) = z / L
Thus,
• L = z * 1/ tan (α)
• L = z * L1
• Where L1 is the inverse of
tan(α), which is also the
value of L when z = 1
• we can then write
the oblique
projection equations
as:
• Xp = x + z ( L1 cos (Ф) )
• Yp = y + z ( L1 sin (Ф) )
The transformation
matrix for parallel
projection
• The transformation matrix
for producing any parallel
projection onto the xy
plane can be written as:
• Now if α = 90° (projection
line is perpendicular to
Projection Plane) then
• tan (α) = infinity => L1 = 0,
so we have an
orthographic projection
Two special cases of
oblique projection:
1. Cavalier
2. Cabinet
1) Cavalier
• α = 45°
• tan (α) = 1 => L1 = 1
• This is a Cavalier
projection such that all
lines perpendicular to the
projection plane are
projected with no change
in length.
2) Cabinet
• tan (Alpha) = 2
• Alpha= 63.40°, L1 = 1 / 2
• Lines which are perpendicular
to the projection plane are
projected at 1 / 2 length. This
is a Cabinet projection
Computer
Graphics
Lecture 19