Computer Aided Engineering Design

(backadmin) #1

52 COMPUTER AIDED ENGINEERING DESIGN


Example 2.10. A unit cube is placed in the first octant, as shown in Figure 2.23, such that its edges
are parallel to the axes and one of the vertices is shifted from (0, 0, 0) to (1, 1, 1). Determine the
perspective projection of the cube on the x-y plane as seen by the observer at z = – 10.
The coordinates of the corners of the unit cube, with one corner at (0, 0, 0), are easily obtainable.
However, its perspective image on the x-y plane will be a unit square with one of the vertices at the
origin. After shifting the (0, 0, 0) vertex of the cube to (1, 1, 1) with the translation matrix T, we get
the new coordinates as


′ ′ ′ ′ ′ ′ ′ ′


⎢ ⎢ ⎢ ⎢ ⎢ ⎢ ⎢ ⎢



⎥ ⎥ ⎥ ⎥ ⎥ ⎥ ⎥ ⎥












⎢ ⎢ ⎢ ⎢ ⎢ ⎢ ⎢ ⎢



⎥ ⎥ ⎥ ⎥ ⎥ ⎥ ⎥ ⎥

A B C D E F G H
T

=

1001
0101
0011
0001

1011
1111
0111
0011
1001
1101
0101
0001

TTT

=

2121
2221
1221
1121
2111
2211
1211
1111



⎢ ⎢ ⎢ ⎢ ⎢ ⎢ ⎢ ⎢



⎥ ⎥ ⎥ ⎥ ⎥ ⎥ ⎥ ⎥

Using the perspective transformation matrix with w = 10, or 1/w = 0.1, the perspective projections of
the vertices A′B′C′D′E′F′G′H′ of the cube can be computed as


A B C D E F G H

w

A B C D E F G H
* T T
* * * * * * *

=

10 0 0
01 0 0
00 0 0
001 1

=

1000
01 0 0
00



⎢ ⎢ ⎢ ⎢ ⎢ ⎢ ⎢ ⎢



⎥ ⎥ ⎥ ⎥ ⎥ ⎥ ⎥ ⎥












′ ′ ′ ′ ′ ′ ′ ′


⎢ ⎢ ⎢ ⎢ ⎢ ⎢ ⎢ ⎢



⎥ ⎥ ⎥ ⎥ ⎥ ⎥ ⎥ ⎥

110
0 0 0.1 1

=

2121
2221
1221
1121
2111
2211
1211
1111













⎢ ⎢ ⎢ ⎢ ⎢ ⎢ ⎢ ⎢



⎥ ⎥ ⎥ ⎥ ⎥ ⎥ ⎥ ⎥

T

P 1

P 2

Ez

(^00)
5
10
x
2
y
P 1 P 2
10
5
0
–5
4
z
Figure 2.22 Perspective image of a line on the x-y
plane in example 2.9
Figure 2.23 Perspective image of a cube in example
2.10 on the x-y plane
x
y
z
To the view
point
The perspective image PP 1 2 of P 1 P 2 as seen from Ez is obtained by substituting u = 0 and u = 1. The
resulting coordinates are P 1 = (8/7 8/7 0) and P 2 = (4 1 0) as shown in Figure 2.22.

Free download pdf