Professional Documents
Culture Documents
TRANSFORMATIO
N OF POINTS &
. I N
K LINES
T U N OT E S
Presented by,
VINEETH.V
Asst. Professor
CCET
Downloaded from Ktunotes.in
CAD- SYLABUS
MODULE-2
S . I N
T U N OTE
K
E S . I N
U N OT
Basic Geometric transformations are:
K T
3. Translation/ Move
4. Scaling
5. Rotation
6. Mirroring/ Reflection/ Flip
7. Shearing
line
(x1,y1
)
Basic 2D Geometric
transformations are:
E S . I N
1. 2D Translation/
N OMove
T
K T U
2. 2D Scaling
3. 2D Rotation
4. 2D Mirroring/ Reflection/ Flip
5. 2D Shearing
(x,y)
S . I N
T U N OTE
K
S . I N
T U N OTE Sx
y
K
Sy
x f , yf
x
x s x 0 0 x N
y 0 S . I x x.s x
sy 0
. y
N OT E
K T U y y.s y
1 0 0 1 1
[P’] =[S] .
[P]
S . I N
y
T U N OTE y x, y
K
x, y
yr
x xr , yr x
xr
S . I N
T U N OTE
K . [P]
[P’] = [R(θ)]
ie…
x’ = xCosθ – ySinθ
y’ = xSinθ + yCosθ
Where, R(θ) = Rotation transformation
operator
Downloaded from Ktunotes.in
4. 2D REFLECTION/
FLIP/MIRRORING
S . I N
T U N OTE
K
S . I N
T U N OTE
K
x cos sin 0 x
y sin cos 0 y , P R P
2D
S . I N
Rotation
1
T U N 0 OTE0 1 1
K
x S x 0 0 x
y 0 S y 0 y , P S S , S P
2D
Scaling x y
1 0 0 1 1
April 2010 31
Downloaded from Ktunotes.in
S . I N
T U N OTE
K
line
(x1,y1,Z1
)
Basic 3D Geometric
transformations are:
E S . I N
1. 3D Translation/
N OMove
T
K T U
2. 3D Scaling
3. 3D Rotation
4. 3D Mirroring/ Reflection/ Flip
5. 3D Shearing
S . I N
z z t z
T U N OTE
K x, y, z
x 1 0 0 t x x
x, y , z y
0 1 0 t y y
z 0 0 1 t z z
z x
1 0 0 0 1 1
April 2010 36
Downloaded from Ktunotes.in
S . I N
T U N OTE
K
y y S y
z x S z
z x S z
. I N x
T U N OTE
Kmoves it from
Enlarging object also
origin
x Sx 0 0 0 x
y 0 Sy 0 0 y
P S P
z 0 0 Sz 0 z
1 0 0 0 1 1
April 2010 38
Downloaded from Ktunotes.in
Scaling
g size of object in x,y,z direction as scaling vector sx,sy,sz respectively
x’=sxx
y’=syy
z’=szz
S . I N
p’=Sp
T U N OTE
K
sx 0 0 0
0 sy 0 0
S = S(sx, sy, sz) =
0 0 sz 0
0 0 0 1
Angel: Interactive Computer
39 Graphics 3E © Addison-Wesley
Downloaded from Ktunotes.in2002
3. 3D Rotation
• ROTATION at x,y,z direction at rotating angle
about a fixed pivot point.
• Need to specify which axis the rotation is about.
Rotation about z-axis
S . I N
T U
N
cos
OTE sin 0 0
K
sin cos 0 0
R z ( )
0 0 1 0
0 0 0 1
02/10/09 Lecture 4 40
Downloaded from Ktunotes.in
Rotating About the x-
axis Rx()
x O 1 TE
0 S . I N
0 0 x
K T
U N
y 0 cos θ sin θ 0 y
z
0 sin θ cos θ 0 z
1 0 0 0 1 1
02/10/09 Lecture 4 41
Downloaded from Ktunotes.in
S . I N
T U N OTE
K
x cos S . I
θTE0 sin θ
N 0 x
KT UN O
y 0 1 0 0 y
z sin θ 0 cos θ 0
z
1 0 0 0 1 1
02/10/09 Lecture 4 43
Downloaded from Ktunotes.in
S . I N
T U N OTE
K
S . I N
x N cos
O Tθ E sin θ 0 0 x
K TU
y sin θ cos θ 0 0 y
z 0 0 1 0 z
1 0 0 0 1 1
02/10/09 Lecture 4 45
Downloaded from Ktunotes.in
Rotation in 3D
• For rotation about the x and y axes:
1 0 0 0 E S . I N
cos 0 sin 0
0 cos U N OT
sin 0
K T 0 1 0 0
R x ( ) , R y ( )
0 sin cos 0 sin 0 cos 0
0 0 0 1 0 0 0 1
02/10/09 Lecture 4 46
Downloaded from Ktunotes.in
Rotating About An Arbitrary
Point
• What happens when you apply a
rotation transformation to an object
that is not at the origin?
• Solution: S . I N
T U NOTE
– TranslateKthe center of rotation to the
origin
– Rotate the object
– Translate back to the original location
x x
S . I N
y
T U N OTE y
K
x x
cos 0 sin 0
0 1 0 0
R = Ry() =
- sin 0 cos 0
0 0 0 1
Angel: Interactive Computer
49 Graphics 3E © Addison-Wesley
Downloaded from Ktunotes.in
2002
4. 3D Reflection
• Mirroring of object along x, y or z axis
sx = -1 sy = 1 original
S . I N
T U N OTE
K
sx = -1 sy = -1 sx = 1 sy = -1
S . I N
T U N OTE
K
2. Concatenation method
S . I N
T U N OTE
K
S . I N
T U N OTE
K
S . I N
T U N OTE
K
S . I N
T U N OTE
K
S . I N
T U N OTE
K
S . I N
T U N OTE
K
S . I N
T U N OTE
K
S . I N
T U N OTE
K