0% found this document useful (0 votes)
69 views

3D Transformations: Design By: Prof. Deepti Palia (AP) Prof. Rajanpreet Kaur (AP) Chandigarh University-Gharuan

This document discusses 3D transformations including translation, rotation, scaling, reflection, and shearing. Translation moves an object by adding offsets to x, y, and z coordinates. Rotation rotates an object around the x, y, and z axes using rotation matrices. Scaling enlarges or shrinks an object using scaling factors along each axis. Reflection mirrors an object across the xy, yz, or xz planes. Shearing skews an object by changing the value of one axis based on another. The document provides the mathematical formulas and matrices for performing each type of 3D transformation.

Uploaded by

Terim
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
69 views

3D Transformations: Design By: Prof. Deepti Palia (AP) Prof. Rajanpreet Kaur (AP) Chandigarh University-Gharuan

This document discusses 3D transformations including translation, rotation, scaling, reflection, and shearing. Translation moves an object by adding offsets to x, y, and z coordinates. Rotation rotates an object around the x, y, and z axes using rotation matrices. Scaling enlarges or shrinks an object using scaling factors along each axis. Reflection mirrors an object across the xy, yz, or xz planes. Shearing skews an object by changing the value of one axis based on another. The document provides the mathematical formulas and matrices for performing each type of 3D transformation.

Uploaded by

Terim
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 21

3D Transformations

Design By:
Prof. Deepti Palia(AP)
Prof. Rajanpreet Kaur(AP)
Chandigarh University-Gharuan

09-01-2019 1
3D Graphics
• 3D Transformations
• Generally, the extension from 2D to 3D is straightforward
• The Cartesian coordinates representation of point would be now (x, y,
z)

09-01-2019 2
Translation
The translation matrix in 3d has three translation factors( tx , ty , tz ). The
translation matrix is

1 0 0 tx 
0 1 0 
ty 
T= 
0 0 1 tz 
 
0 0 0 1

09-01-2019 3
Rotation
• The 2D z-axis rotation equations are easily extended to 3D.

• The 3D z-axis rotation matrix is expressed as

09-01-2019 4
Rotation
• The x-axis rotation equations are expressed as:

• The x-axis rotation matrix is expressed as

09-01-2019 5
Rotation
• The y-axis rotation matrix is expressed as

• The y-axis rotation equations are expressed as

09-01-2019 6
Scaling
• The expressions for scaling relative to the origin are

09-01-2019 7
Scaling Matrix
• The Scaling Matrix can be written as

09-01-2019 8
09-01-2019 9
Reflection
• A 3D reflection can be performed relative to a selected reflection axis or
with respect to a selected reflection plane.
• Three types of 3D reflection:
I. Reflection w.r.t xy plane
II. Reflection w.r.t yz plane
III. Reflection w.r.t xz plane

09-01-2019 10
Reflection
• The expressions for scaling relative to the origin are

09-01-2019 11
Reflection w.r.t XY plane
• In xy plane, only the value of z will change to negative.
• The matrix representation for reflection of points relative to the xy plane is

09-01-2019 12
Reflection w.r.t YZ plane
• In yz plane, only the value of x will change to negative.
• The matrix representation for reflection of points relative to the yz plane is

09-01-2019 13
Reflection w.r.t XZ plane
• In xz plane, only the value of y will change to negative.
• The matrix representation for reflection of points relative to the xz plane is

09-01-2019 14
Reflection
• A 3D reflection can be performed relative to a selected reflection axis or
with respect to a selected reflection plane.
• Three types of 3D reflection:
I. Reflection w.r.t xy plane
II. Reflection w.r.t yz plane
III. Reflection w.r.t xz plane

09-01-2019 15
Shearing
• A transformation that slants the shape of an object is called as shearing.
• Shearing can be performed in three ways:
I. Along z-axis
II. Along y-axis
III. Along x-axis

09-01-2019 16
Shearing along z-axis
• X and Y Will remain same, only the value of Z will change.
• Shearing along y-axis can be expressed as:

09-01-2019 17
Shearing along x-axis
• Y and Z Will remain same, only the value of X will change.
• Shearing along x-axis can be expressed as:

09-01-2019 18
Shearing along z-axis
• X and Y Will remain same, only the value of Z will change.
• Shearing along z-axis can be expressed as:

09-01-2019 19
Frequently Asked Questions

 How shearing along x-axis is different from shearing along y-axis. Give
some practical examples.
 Name few 2D primitives figures you know.
 Reflection can occur along axis as well as plane. Explain the difference
between these two cases.
 What are the possible values of an object along xy and yz plane?

09-01-2019 20
Bibliography

 Computer Graphics, 2nd Ed., Hern& Baker –PHI, New Delhi


 Graphics Programming with C ByYashwantKanetkar, BPB Publications,
New Delhi.
 Computer Graphics, Schaum’s Outline Series, MGH Publications.
 https://www.cs.mtsu.edu/~jhankins/files/4250/notes/WinToView/WinToVi
ewMap.html

09-01-2019 21

You might also like