1 Plane Geometric Projections
1.1 Introduction
For visualizing a scene it is required a projection from three dimensional space
to 2D space (a plane). In this section we will consider plane projections: The
parallel projections and the perspective projections.
In what follows, we are going to represent the coordinates of a point p ∈ <3
through a column vector:
x
p = y . (1)
z
Thus, a 3 × 3 matrix A defines a linear transformation T given by:
T :<3 → <3 ; (2)
x a b c x
T (p) = A y = d e f y . (3)
z g i j z
Geometrically, we can say that this operation transforms the initial coordi-
nates x, y and z to the new coordinates
x∗ = ax + by + cz, (4)
y∗ = dx + ey + f z.
z∗ = gx + iy + jz. (5)
From the computer graphics viewpoint, the first requirement for matrix A
is that it should be non-singular, that means:
det (A) 6= 0.
In homogeneous coordinates, we can write a general transformation as:
x a b c m x
y d e f n y
T z = g i
, (6)
j q z
1 0 0 0 1 1
where the parameters m,n, q are the translation factors and the elements a, b, c, d, e, f, g, i, j
take care of the rotations, reflections, scalings, shearing as well as compositions
of these transformations.
1
1.2 Orthographic Projections
Orthographic projections are projections onto one of the coordinate planes z =
0, y = 0 or x = 0. The corresponding matrices are:
1) Projection onto z = 0
1 0 0 0
0 1 0 0
Pz =
0 0 0 0
(7)
0 0 0 1
2) Projection onto y = 0
1 0 0 0
0 0 0 0
Py =
0
(8)
0 1 0
0 0 0 1
3) Projection onto x = 0
0 0 0 0
0 1 0 0
Px =
0
(9)
0 1 0
0 0 0 1
1.3 Axonometric Projections
An axonometric projection is constructed by manipulating the objects, using
rotations and translations, such that at least three adjacent faces becomes vis-
ible. The result is then projected using one of the orthographic projections,
given in expressions (1), (2), and (4). Usually, it is used the projection onto the
plane z = 0.
Question: Consider an unitary cube in the first octant with edges paral-
lel to the coordinate axes and the Pz projection (expression (1)). Obtain an
axonometric projection that allows the top of the cube to be visualized.
1.4 Oblique Projections
In contrast to the orthographic and axonometric projections for which the pro-
jectors are perpendicular to the plane of projection, an oblique projection is
obtained by using parallel projectors that intersect the projection plane at an
oblique angle.
To obtain its general form, let us consider that the projector rays are parallel
to the vector:
2
a
v = b , (10)
c
where c 6= 0. Also, consider that the projection plane is the z = 0 one. So, given
a point (x, y, z) ∈ <3 , the projector that contains this point is given by;
x a
r (t) = y + t b . (11)
z c
This ray intersects the z = 0 plane at a point defined by:
z
z + tc = 0 ⇒ t = − . (12)
c
Therefore, the <3 is projected according to:
x x a
z
P y = y − b ⇒ (13)
c
z z c
1 0 − ac
x x
P y = 0 1 − cb y . (14)
z 0 0 0 z
Question: Obtain the matrices and the projector direction (vector v) for
cavalier and cabinet projections (page 152-153). Apply these transformations
over the unitary cube and show the result.
1.5 Perspective Projections
In contrast to the parallel projections, where the projectors are parallel, in
perspective projections there is a center of projection at a finite distance from
the projection plane (if the center of projection is located at the infinite then
we have a parallel projection). The Figure 1 pictures such a setup. We observe
a projection center located at the point (0, 0, zc ) and the projection plane is the
z = 0 one (as usual). The problem is to compute the coordinates x∗ , y ∗ of the
projected point (z ∗ is zero).
The geometry of the perspective projection in Figure 1 gives the solution for
this problem. The coordinates of the projected point are obtained using similar
triangles:
x∗ x
= , (15)
zc zc − z
3
Figure 1: ‘Perspective projection.
y∗ y
q =q , (16)
2 2 2 2
(x∗ ) + (zc ) (x) + (zc − z)
ore
x
x∗ = , (17)
1 − zzc
y
y∗ = , (18)
1 − zzc
This result is very useful to understand the geometric meaning of the per-
spective transformations, defined next.
2 Perspective Transformations
Perspective transformations are defined in the homogeneous coordinates by the
following matrix:
1 0 0 0
0 1 0 0
T = 0 0 1 0 .
(19)
p q r 1
4
Let us start with the case p = q = 0 and r 6= 0. So, given a 3D point with
homogeneous coordinates (x, y, z, 1) , it will be transformed as:
x 1 0 0 0 x x
y 0 1 0 0 y y
T z = 0 0 1 0 z =
. (20)
z
1 p q r 1 1 rz + 1
Therefore, returning to the Cartesian coordinates:
x
x∗ = , (21)
rz + 1
y
y∗ = ,
rz + 1
z
z∗ = .
rz + 1
We observe that, if we set r = −1/zc and project this result on the z = 0
plane, we obtain the perspective projection defined by expressions (17)-(18).
Besides we observe that if we take the limit for z → ∞ in expressions (21) we
get the point (0, 0, 1/r) . This point is called vanishing point. Let us consider
the Figure 2 (pg. 161 of the book). We can show that lines becomes lines
by perspective transformations. Therefore, the segment AB is transformed in
another segment. The segment AB is parallel to the z axis. Let C be the point
that is obtained through the orthographic projection of AB onto the xy plane.
This point remains unchanged under the perspective transformation defined by
expressions (21) (if z = 0 we observe that x∗ = x, y ∗ = y, z ∗ = 0).
However, if we take point B to the infinite we know that the transformed
point will get the vanishing point. Therefore, the semi-line that passes through
the segment AB is transformed onto the segment from the point C to the van-
ishing point. If we translate the segment AB we get a similar result. Therefore,
parallel lines appear to ”converge” and ”vanish”.
In a general case, we can have three vanishing points (p 6= 0, q 6= 0, r 6= 0).
For two vanishing points we must have only one of these parameters null.
5
Figure 2: ‘Perspective projection.