SlideShare a Scribd company logo
1 of 38
Download to read offline
1
2-D
Transformations
Transformations
• The geometrical changes of an object from a current state to modified
state.
• To manipulate the initially created object and to display the modified
object without having to redraw it.
• Object Transformation
• Alter the coordinates descriptions of an object
• Translation, rotation, scaling etc.
2
2D Transformations
• Translation
• Rotation
• Scaling
• Mirror / Reflect
• Shearing /shear
3
• A translation moves all points in an
object along the same straight-line
path to new positions.
• The path is represented by a vector,
called the translation or shift vector.
p'x = tx + px
p'y = ty + py
tx
t
= 6
= 4
x’
y’
x
y
tx
ty
= +
Translation
4
[P'] = [ T] + [P]
P’
P
Rotation
5

P
P’
• A rotation repositions all points
in an object along a circular path
in the plane centered at the
pivot point.

P(x,y)

r

P’(x’, y’)
r
• x = r cos 
• y = r sin 
• x’ = r cos( + )
• x’ = r cos cos - r sin sin
• y’ = r sin( + )
• y’ = r cos sin + r sin cos
• From (A) & (B)
• x’ = xcos - ysin
• From (A) & (C)
• y’ = xsin + ycos
(A)
(B)
Rotation
6
(C)
[P'] = [T] [P]
x’
y’
x
y
=
cos -sin
sin cos
Scaling
• Scaling changes the size of an
object and involves two scale
factors, Sx and Sy for the X and Y
coordinates respectively.
• Scales are about the origin.
• x’ = sx * x
• y’ = sy * y
[P'] = [T] [P]
x’
y’
x
y
=
Sx 0
0 Sy
Image Reference:- CAD/CAM AND AUTOMATION By
Farazdak Haideri, Nirali Prakashan, Ninth Edition
7
Reflection
[P'] = [T] [P]
x’
y’
x
y
=
1 0
0 -1
@ Y-axis
x’
y’
x
y
=
-1 0
0 1
@ X-axis
[P'] = [T] [P]
x’ = x
y’ = -y
x’ = -x
y’ = y
8
Shear
• A type of transformation that distorts the shape of an object, such a that
a transformed shape appears as if, object were composed of internal
layers that had been caused to slide over each other.
9
Shear
10
Shear
•x’ = x + yshx
•y’ = y
[P'] = [T] [P]
x’
y’
x
y
=
1 Shx
Shy 1
•x’ = x
•y’ = y + xshy
x’
y’
x
y
=
1 Shx
0 1
x’
y’
x
y
=
1 0
Shy 1
11
2D Transformations
12
x’
y’
x
y
tx
ty
= +
x’
y’
x
y
=
cos -sin
sin cos
x’
y’
x
y
=
Sx 0
0 Sy
x’
y’
x
y
= 1 0
0 -1
x’
y’
x
y
=
-1 0
0 1
x’
y’
x
y
=
1 Shx
Shy 1
[P'] = [ T] + [P]
[P'] = [T] [P]
Homogeneous Coordinates and Homogeneous
Transformations
• All the transformations, except translation, are in the form of matrix
multiplication.
• “Translation” takes the form of vector addition.
• This makes it inconvenient to concatenate transformations involving
translation.
• It is therefore desirable to express all geometric transformations in the
form of matrix multiplication only.
13
Homogeneous Coordinates and Homogeneous
Transformations
• Many graphics applications involve sequence of geometric
transformations.
• Animations also require an object to be translated, rotated, scaled, etc.
at an each increment of a motion sequence.
• In design and picture construction applications different transformations
are used to fit the picture components into their proper positions.
14
Homogeneous Coordinates and Homogeneous
Transformations
• Representing points by their homogeneous coordinates, provides an
effective way to unify the description of geometric transformations
as matrix multiplication.
• Homogeneous coordinates have been used in computer graphics and
geometric modelling techniques.
• With the help of homogeneous coordinates, geometric
transformations are customarily embedded into graphics hardware to
speed their execution.
15
Homogeneous Coordinates and
Homogeneous Transformations
• In a 2D space, point P with Cartesian coordinates (X, Y), has
homogeneous coordinates (X*, Y* , h), where h is a scalar factor and
h≠0.
• P (X, Y)………………….. Cartesian coordinates
• P(X*, Y* , h)……………….. Homogeneous coordinates
16
Homogeneous Coordinates and Homogeneous
Transformations
• Cartesian and Homogeneous coordinates are related to each other by
following relation
𝑋 =
X∗
ℎ
, 𝑌 =
Y∗
ℎ
, Z =
𝑍∗
ℎ
• Above equations are based on the fact that, if the Cartesian coordinates
of a given point P are multiplied by scalar factor h, then P is scaled to a
new point P∗ and the coordinates of P and P∗ are related by above
equations.
17
Homogeneous Coordinates and Homogeneous
Transformations
• For the purpose of geometric transformations the scalar factor h is
taken to be Unity to avoid unnecessary divisions.
𝑃 𝑋, 𝑌 = 𝑃(𝑋, 𝑌, 1)
• By using homogeneous coordinates, all the 5 types of
transformations that is, translation, rotation, scaling, mirror (reflect)
and shear, can be represented as a product of “3 X 3” transformation
matrix and “3 x 1” column vector.
18
Homogeneous Coordinates and Homogeneous
Transformations
• The conversion of two dimensional co-ordinate pair (x, y), into a three
dimensional vector (x, y ,1), is known as Homogeneous
representation.
19
x’
y’
x
y
tx
ty
= +
x’
y’
x
y
=
cos -sin
sin cos
x’
y’
1
1 0 tx
0 1 ty
0 0 1
=
x
Y
1
x’
y’
1
cos -sin 0
sin cos 0
0 0 1
=
x
Y
1
Homogeneous Coordinates and Homogeneous
Transformations
20
1. Translation
2. Rotation
3*3 3*1
3*1
x’
y’
x
y
=
Sx 0
0 Sy
x’
y’
x
y
= 1 0
0 -1
x’
y’
x
y
=
-1 0
0 1
x’
y’
1
Sx 0 0
0 Sy 0
0 0 1
=
x
Y
1
x’
y’
1
1 0 0
0 -1 0
0 0 1
=
x
Y
1
x’
y’
1
-1 0 0
0 1 0
0 0 1
=
x
Y
1
3. Scaling
4. Mirror/ Reflection
Homogeneous Coordinates and Homogeneous
Transformations
21
x’
y’
x
y
=
1 Shx
Shy 1
x’
y’
1
1 Shx 0
Shy 1 0
0 0 1
=
x
Y
1
5. Shear
Homogeneous Coordinates and Homogeneous
Transformations
22
x’
y’
1
1 0 tx
0 1 ty
0 0 1
=
x
Y
1
x’
y’
1
cos -sin 0
sin cos 0
0 0 1
=
x
Y
1
x’
y’
1
Sx 0 0
0 Sy 0
0 0 1
=
x
Y
1
x’
y’
1
1 0 0
0 -1 0
0 0 1
=
x
Y
1
x’
y’
1
-1 0 0
0 1 0
0 0 1
=
x
Y
1
x’
y’
1
1 Shx 0
Shy 1 0
0 0 1
=
x
Y
1
Shearing /shear
Translation
Rotation
Scaling
X Mirror / Reflect Y Mirror / Reflect
23
Homogeneous Coordinates and Homogeneous
Transformations
• This 3D representation of a 2D space is called as homogeneous
coordinate system and transformation using homogeneous
coordinates are called as homogeneous transformations.
• Expressing positions in homogeneous coordinate system allow the
users to represent geometric transformations in the form of matrix
multiplication.
24
Composite Transformations /
Concatenations
25
[P'] = [Tn] [Tn-1] [Tn-2]…… [T3] [T2] [T1] [P]
[P'] = [T] [P]
[T1], [T2], [T3],…….., [Tn-2], [Tn-1],[Tn]
1. Point “A” (4,3) is rotated counterclockwise by 45°. Find the rotation
matrix and coordinates of the resultant point.
26
1. Point “A” (4,3) is rotated counterclockwise by 45°. Find the rotation matrix and
coordinates of the resultant point.
27
[A']
[T]Rotation
[A]
[T]
1. Point “A” (4,3) is rotated counterclockwise by 45°. Find the rotation
matrix and coordinates of the resultant point.
28
2. Translate a polygon PQR, P(2,5), Q(7,10) and R(10,2), by 3 units in X
direction and 4 units in Y direction. Identify the transformed coordinates.
29
2. Translate a polygon PQR, P(2,5), Q(7,10) and R(10,2), by 3 units in X
direction and 4 units in Y direction. Identify the transformed coordinates.
30
2. Translate a polygon PQR, P(2,5), Q(7,10) and R(10,2), by 3 units in X
direction and 4 units in Y direction. Identify the transformed coordinates.
31
2. Translate a polygon PQR, P(2,5), Q(7,10) and R(10,2), by 3 units in X
direction and 4 units in Y direction. Identify the transformed coordinates.
32
2. Translate a polygon PQR, P(2,5), Q(7,10) and R(10,2), by 3 units in X
direction and 4 units in Y direction. Identify the transformed coordinates.
33
2. Translate a polygon PQR, P(2,5), Q(7,10) and R(10,2), by 3 units in X
direction and 4 units in Y direction. Identify the transformed coordinates.
34
3. Polygon ABC, A (2,3), B( 0,10) and C(5,10), is moved in such a way that, new
coordinates of point A are (10,10). Find transformation matrix and the resultant
coordinates.
35
3. Polygon ABC, A (2,3), B( 0,10) and C(5,10), is moved in such a way that, new
coordinates of point A are (10,10). Find transformation matrix and the resultant
coordinates.
36
3. Polygon ABC, A (2,3), B( 0,10) and C(5,10), is moved in such a way that, new
coordinates of point A are (10,10). Find transformation matrix and the resultant
coordinates.
37
Thank You

More Related Content

What's hot

3 d geometric transformations
3 d geometric transformations3 d geometric transformations
3 d geometric transformationsMohd Arif
 
CE6451 - FLUID MECHANICS AND MACHINERY UNIT - IV NOTES
CE6451 - FLUID MECHANICS AND MACHINERY UNIT - IV NOTES  CE6451 - FLUID MECHANICS AND MACHINERY UNIT - IV NOTES
CE6451 - FLUID MECHANICS AND MACHINERY UNIT - IV NOTES ASHOK KUMAR RAJENDRAN
 
Bezier curve & B spline curve
Bezier curve  & B spline curveBezier curve  & B spline curve
Bezier curve & B spline curveArvind Kumar
 
Overview of 2D and 3D Transformation
Overview of 2D and 3D TransformationOverview of 2D and 3D Transformation
Overview of 2D and 3D TransformationDheeraj Sadawarte
 
Chapter 6 area & volume measurement, Digital Planimeter
Chapter 6 area & volume measurement, Digital PlanimeterChapter 6 area & volume measurement, Digital Planimeter
Chapter 6 area & volume measurement, Digital PlanimeterAbhay Abhale
 
Lesson 13-perspective-projection
Lesson 13-perspective-projectionLesson 13-perspective-projection
Lesson 13-perspective-projectioneglive
 
Presentation on bezier curve
Presentation on bezier curvePresentation on bezier curve
Presentation on bezier curveSatyendra Rajput
 
Gaussian quadratures
Gaussian quadraturesGaussian quadratures
Gaussian quadraturesTarun Gehlot
 
B. SC CSIT Computer Graphics Unit 2 By Tekendra Nath Yogi
B. SC CSIT Computer Graphics Unit 2 By Tekendra Nath YogiB. SC CSIT Computer Graphics Unit 2 By Tekendra Nath Yogi
B. SC CSIT Computer Graphics Unit 2 By Tekendra Nath YogiTekendra Nath Yogi
 
Grid generation and adaptive refinement
Grid generation and adaptive refinementGrid generation and adaptive refinement
Grid generation and adaptive refinementGoran Rakic
 

What's hot (20)

3 d geometric transformations
3 d geometric transformations3 d geometric transformations
3 d geometric transformations
 
CE6451 - FLUID MECHANICS AND MACHINERY UNIT - IV NOTES
CE6451 - FLUID MECHANICS AND MACHINERY UNIT - IV NOTES  CE6451 - FLUID MECHANICS AND MACHINERY UNIT - IV NOTES
CE6451 - FLUID MECHANICS AND MACHINERY UNIT - IV NOTES
 
Section of solids
Section of solidsSection of solids
Section of solids
 
Bezier curve & B spline curve
Bezier curve  & B spline curveBezier curve  & B spline curve
Bezier curve & B spline curve
 
Computer graphics
Computer graphicsComputer graphics
Computer graphics
 
Overview of 2D and 3D Transformation
Overview of 2D and 3D TransformationOverview of 2D and 3D Transformation
Overview of 2D and 3D Transformation
 
Unit ii projection of points
Unit  ii projection of pointsUnit  ii projection of points
Unit ii projection of points
 
Divided difference Matlab code
Divided difference Matlab codeDivided difference Matlab code
Divided difference Matlab code
 
Chapter 6 area & volume measurement, Digital Planimeter
Chapter 6 area & volume measurement, Digital PlanimeterChapter 6 area & volume measurement, Digital Planimeter
Chapter 6 area & volume measurement, Digital Planimeter
 
Lesson 13-perspective-projection
Lesson 13-perspective-projectionLesson 13-perspective-projection
Lesson 13-perspective-projection
 
Presentation on bezier curve
Presentation on bezier curvePresentation on bezier curve
Presentation on bezier curve
 
Curves and surfaces
Curves and surfacesCurves and surfaces
Curves and surfaces
 
Gaussian quadratures
Gaussian quadraturesGaussian quadratures
Gaussian quadratures
 
Projection of solids
Projection of solidsProjection of solids
Projection of solids
 
Projections of solids
Projections of solidsProjections of solids
Projections of solids
 
B. SC CSIT Computer Graphics Unit 2 By Tekendra Nath Yogi
B. SC CSIT Computer Graphics Unit 2 By Tekendra Nath YogiB. SC CSIT Computer Graphics Unit 2 By Tekendra Nath Yogi
B. SC CSIT Computer Graphics Unit 2 By Tekendra Nath Yogi
 
Windows and viewport
Windows and viewportWindows and viewport
Windows and viewport
 
Cycloidal curves
Cycloidal curvesCycloidal curves
Cycloidal curves
 
Spline representations
Spline representationsSpline representations
Spline representations
 
Grid generation and adaptive refinement
Grid generation and adaptive refinementGrid generation and adaptive refinement
Grid generation and adaptive refinement
 

Similar to 2D Transformation.pdf

2 d transformations by amit kumar (maimt)
2 d transformations by amit kumar (maimt)2 d transformations by amit kumar (maimt)
2 d transformations by amit kumar (maimt)Amit Kapoor
 
2D Translation.pdf
2D Translation.pdf2D Translation.pdf
2D Translation.pdfMehulMunshi3
 
2Dand3D transformationppt.pptx
2Dand3D transformationppt.pptx2Dand3D transformationppt.pptx
2Dand3D transformationppt.pptxRAMESHCHANDRANE
 
2 d geometric transformations
2 d geometric transformations2 d geometric transformations
2 d geometric transformationsMohd Arif
 
2D transformation (Computer Graphics)
2D transformation (Computer Graphics)2D transformation (Computer Graphics)
2D transformation (Computer Graphics)Timbal Mayank
 
Two dimensionaltransformations
Two dimensionaltransformationsTwo dimensionaltransformations
Two dimensionaltransformationsNareek
 
Two dimentional transform
Two dimentional transformTwo dimentional transform
Two dimentional transformPatel Punit
 
Computer graphics basic transformation
Computer graphics basic transformationComputer graphics basic transformation
Computer graphics basic transformationSelvakumar Gna
 
moule 3 ppt1 basic 2D transformations.pptx
moule 3 ppt1 basic 2D transformations.pptxmoule 3 ppt1 basic 2D transformations.pptx
moule 3 ppt1 basic 2D transformations.pptxRADHIKAB20
 
3D transformation in computer graphics
3D transformation in computer graphics3D transformation in computer graphics
3D transformation in computer graphicsSHIVANI SONI
 

Similar to 2D Transformation.pdf (20)

2 d transformations by amit kumar (maimt)
2 d transformations by amit kumar (maimt)2 d transformations by amit kumar (maimt)
2 d transformations by amit kumar (maimt)
 
06.Transformation.ppt
06.Transformation.ppt06.Transformation.ppt
06.Transformation.ppt
 
2D Translation.pdf
2D Translation.pdf2D Translation.pdf
2D Translation.pdf
 
2Dand3D transformationppt.pptx
2Dand3D transformationppt.pptx2Dand3D transformationppt.pptx
2Dand3D transformationppt.pptx
 
2 d geometric transformations
2 d geometric transformations2 d geometric transformations
2 d geometric transformations
 
2D-transformation-1.pdf
2D-transformation-1.pdf2D-transformation-1.pdf
2D-transformation-1.pdf
 
2D transformation (Computer Graphics)
2D transformation (Computer Graphics)2D transformation (Computer Graphics)
2D transformation (Computer Graphics)
 
Two dimensionaltransformations
Two dimensionaltransformationsTwo dimensionaltransformations
Two dimensionaltransformations
 
2d transformation
2d transformation2d transformation
2d transformation
 
Two dimentional transform
Two dimentional transformTwo dimentional transform
Two dimentional transform
 
Computer graphics presentation
Computer graphics presentationComputer graphics presentation
Computer graphics presentation
 
3D Transformation
3D Transformation3D Transformation
3D Transformation
 
Unit 3 notes
Unit 3 notesUnit 3 notes
Unit 3 notes
 
2D Transformation
2D Transformation2D Transformation
2D Transformation
 
2-D Transformations.pdf
2-D Transformations.pdf2-D Transformations.pdf
2-D Transformations.pdf
 
Computer graphics basic transformation
Computer graphics basic transformationComputer graphics basic transformation
Computer graphics basic transformation
 
moule 3 ppt1 basic 2D transformations.pptx
moule 3 ppt1 basic 2D transformations.pptxmoule 3 ppt1 basic 2D transformations.pptx
moule 3 ppt1 basic 2D transformations.pptx
 
transformation IT.ppt
transformation IT.ppttransformation IT.ppt
transformation IT.ppt
 
3D transformation in computer graphics
3D transformation in computer graphics3D transformation in computer graphics
3D transformation in computer graphics
 
2D transformations
2D transformations2D transformations
2D transformations
 

Recently uploaded

Study on Air-Water & Water-Water Heat Exchange in a Finned Tube Exchanger
Study on Air-Water & Water-Water Heat Exchange in a Finned Tube ExchangerStudy on Air-Water & Water-Water Heat Exchange in a Finned Tube Exchanger
Study on Air-Water & Water-Water Heat Exchange in a Finned Tube ExchangerAnamika Sarkar
 
Call Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call GirlsCall Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call Girlsssuser7cb4ff
 
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130Suhani Kapoor
 
HARMONY IN THE HUMAN BEING - Unit-II UHV-2
HARMONY IN THE HUMAN BEING - Unit-II UHV-2HARMONY IN THE HUMAN BEING - Unit-II UHV-2
HARMONY IN THE HUMAN BEING - Unit-II UHV-2RajaP95
 
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service NashikCollege Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service NashikCall Girls in Nagpur High Profile
 
Oxy acetylene welding presentation note.
Oxy acetylene welding presentation note.Oxy acetylene welding presentation note.
Oxy acetylene welding presentation note.eptoze12
 
Application of Residue Theorem to evaluate real integrations.pptx
Application of Residue Theorem to evaluate real integrations.pptxApplication of Residue Theorem to evaluate real integrations.pptx
Application of Residue Theorem to evaluate real integrations.pptx959SahilShah
 
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...ranjana rawat
 
microprocessor 8085 and its interfacing
microprocessor 8085  and its interfacingmicroprocessor 8085  and its interfacing
microprocessor 8085 and its interfacingjaychoudhary37
 
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...Soham Mondal
 
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...srsj9000
 
Current Transformer Drawing and GTP for MSETCL
Current Transformer Drawing and GTP for MSETCLCurrent Transformer Drawing and GTP for MSETCL
Current Transformer Drawing and GTP for MSETCLDeelipZope
 
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130Suhani Kapoor
 
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
Microscopic Analysis of Ceramic Materials.pptx
Microscopic Analysis of Ceramic Materials.pptxMicroscopic Analysis of Ceramic Materials.pptx
Microscopic Analysis of Ceramic Materials.pptxpurnimasatapathy1234
 
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort serviceGurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort servicejennyeacort
 
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escortsranjana rawat
 
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escortsranjana rawat
 
SPICE PARK APR2024 ( 6,793 SPICE Models )
SPICE PARK APR2024 ( 6,793 SPICE Models )SPICE PARK APR2024 ( 6,793 SPICE Models )
SPICE PARK APR2024 ( 6,793 SPICE Models )Tsuyoshi Horigome
 
power system scada applications and uses
power system scada applications and usespower system scada applications and uses
power system scada applications and usesDevarapalliHaritha
 

Recently uploaded (20)

Study on Air-Water & Water-Water Heat Exchange in a Finned Tube Exchanger
Study on Air-Water & Water-Water Heat Exchange in a Finned Tube ExchangerStudy on Air-Water & Water-Water Heat Exchange in a Finned Tube Exchanger
Study on Air-Water & Water-Water Heat Exchange in a Finned Tube Exchanger
 
Call Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call GirlsCall Girls Narol 7397865700 Independent Call Girls
Call Girls Narol 7397865700 Independent Call Girls
 
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130
VIP Call Girls Service Hitech City Hyderabad Call +91-8250192130
 
HARMONY IN THE HUMAN BEING - Unit-II UHV-2
HARMONY IN THE HUMAN BEING - Unit-II UHV-2HARMONY IN THE HUMAN BEING - Unit-II UHV-2
HARMONY IN THE HUMAN BEING - Unit-II UHV-2
 
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service NashikCollege Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
College Call Girls Nashik Nehal 7001305949 Independent Escort Service Nashik
 
Oxy acetylene welding presentation note.
Oxy acetylene welding presentation note.Oxy acetylene welding presentation note.
Oxy acetylene welding presentation note.
 
Application of Residue Theorem to evaluate real integrations.pptx
Application of Residue Theorem to evaluate real integrations.pptxApplication of Residue Theorem to evaluate real integrations.pptx
Application of Residue Theorem to evaluate real integrations.pptx
 
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANVI) Koregaon Park Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
 
microprocessor 8085 and its interfacing
microprocessor 8085  and its interfacingmicroprocessor 8085  and its interfacing
microprocessor 8085 and its interfacing
 
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
OSVC_Meta-Data based Simulation Automation to overcome Verification Challenge...
 
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...
Gfe Mayur Vihar Call Girls Service WhatsApp -> 9999965857 Available 24x7 ^ De...
 
Current Transformer Drawing and GTP for MSETCL
Current Transformer Drawing and GTP for MSETCLCurrent Transformer Drawing and GTP for MSETCL
Current Transformer Drawing and GTP for MSETCL
 
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130
VIP Call Girls Service Kondapur Hyderabad Call +91-8250192130
 
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
 
Microscopic Analysis of Ceramic Materials.pptx
Microscopic Analysis of Ceramic Materials.pptxMicroscopic Analysis of Ceramic Materials.pptx
Microscopic Analysis of Ceramic Materials.pptx
 
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort serviceGurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
Gurgaon ✡️9711147426✨Call In girls Gurgaon Sector 51 escort service
 
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
 
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts
(MEERA) Dapodi Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Escorts
 
SPICE PARK APR2024 ( 6,793 SPICE Models )
SPICE PARK APR2024 ( 6,793 SPICE Models )SPICE PARK APR2024 ( 6,793 SPICE Models )
SPICE PARK APR2024 ( 6,793 SPICE Models )
 
power system scada applications and uses
power system scada applications and usespower system scada applications and uses
power system scada applications and uses
 

2D Transformation.pdf

  • 2. Transformations • The geometrical changes of an object from a current state to modified state. • To manipulate the initially created object and to display the modified object without having to redraw it. • Object Transformation • Alter the coordinates descriptions of an object • Translation, rotation, scaling etc. 2
  • 3. 2D Transformations • Translation • Rotation • Scaling • Mirror / Reflect • Shearing /shear 3
  • 4. • A translation moves all points in an object along the same straight-line path to new positions. • The path is represented by a vector, called the translation or shift vector. p'x = tx + px p'y = ty + py tx t = 6 = 4 x’ y’ x y tx ty = + Translation 4 [P'] = [ T] + [P] P’ P
  • 5. Rotation 5  P P’ • A rotation repositions all points in an object along a circular path in the plane centered at the pivot point.
  • 6.  P(x,y)  r  P’(x’, y’) r • x = r cos  • y = r sin  • x’ = r cos( + ) • x’ = r cos cos - r sin sin • y’ = r sin( + ) • y’ = r cos sin + r sin cos • From (A) & (B) • x’ = xcos - ysin • From (A) & (C) • y’ = xsin + ycos (A) (B) Rotation 6 (C) [P'] = [T] [P] x’ y’ x y = cos -sin sin cos
  • 7. Scaling • Scaling changes the size of an object and involves two scale factors, Sx and Sy for the X and Y coordinates respectively. • Scales are about the origin. • x’ = sx * x • y’ = sy * y [P'] = [T] [P] x’ y’ x y = Sx 0 0 Sy Image Reference:- CAD/CAM AND AUTOMATION By Farazdak Haideri, Nirali Prakashan, Ninth Edition 7
  • 8. Reflection [P'] = [T] [P] x’ y’ x y = 1 0 0 -1 @ Y-axis x’ y’ x y = -1 0 0 1 @ X-axis [P'] = [T] [P] x’ = x y’ = -y x’ = -x y’ = y 8
  • 9. Shear • A type of transformation that distorts the shape of an object, such a that a transformed shape appears as if, object were composed of internal layers that had been caused to slide over each other. 9
  • 11. Shear •x’ = x + yshx •y’ = y [P'] = [T] [P] x’ y’ x y = 1 Shx Shy 1 •x’ = x •y’ = y + xshy x’ y’ x y = 1 Shx 0 1 x’ y’ x y = 1 0 Shy 1 11
  • 12. 2D Transformations 12 x’ y’ x y tx ty = + x’ y’ x y = cos -sin sin cos x’ y’ x y = Sx 0 0 Sy x’ y’ x y = 1 0 0 -1 x’ y’ x y = -1 0 0 1 x’ y’ x y = 1 Shx Shy 1 [P'] = [ T] + [P] [P'] = [T] [P]
  • 13. Homogeneous Coordinates and Homogeneous Transformations • All the transformations, except translation, are in the form of matrix multiplication. • “Translation” takes the form of vector addition. • This makes it inconvenient to concatenate transformations involving translation. • It is therefore desirable to express all geometric transformations in the form of matrix multiplication only. 13
  • 14. Homogeneous Coordinates and Homogeneous Transformations • Many graphics applications involve sequence of geometric transformations. • Animations also require an object to be translated, rotated, scaled, etc. at an each increment of a motion sequence. • In design and picture construction applications different transformations are used to fit the picture components into their proper positions. 14
  • 15. Homogeneous Coordinates and Homogeneous Transformations • Representing points by their homogeneous coordinates, provides an effective way to unify the description of geometric transformations as matrix multiplication. • Homogeneous coordinates have been used in computer graphics and geometric modelling techniques. • With the help of homogeneous coordinates, geometric transformations are customarily embedded into graphics hardware to speed their execution. 15
  • 16. Homogeneous Coordinates and Homogeneous Transformations • In a 2D space, point P with Cartesian coordinates (X, Y), has homogeneous coordinates (X*, Y* , h), where h is a scalar factor and h≠0. • P (X, Y)………………….. Cartesian coordinates • P(X*, Y* , h)……………….. Homogeneous coordinates 16
  • 17. Homogeneous Coordinates and Homogeneous Transformations • Cartesian and Homogeneous coordinates are related to each other by following relation 𝑋 = X∗ ℎ , 𝑌 = Y∗ ℎ , Z = 𝑍∗ ℎ • Above equations are based on the fact that, if the Cartesian coordinates of a given point P are multiplied by scalar factor h, then P is scaled to a new point P∗ and the coordinates of P and P∗ are related by above equations. 17
  • 18. Homogeneous Coordinates and Homogeneous Transformations • For the purpose of geometric transformations the scalar factor h is taken to be Unity to avoid unnecessary divisions. 𝑃 𝑋, 𝑌 = 𝑃(𝑋, 𝑌, 1) • By using homogeneous coordinates, all the 5 types of transformations that is, translation, rotation, scaling, mirror (reflect) and shear, can be represented as a product of “3 X 3” transformation matrix and “3 x 1” column vector. 18
  • 19. Homogeneous Coordinates and Homogeneous Transformations • The conversion of two dimensional co-ordinate pair (x, y), into a three dimensional vector (x, y ,1), is known as Homogeneous representation. 19
  • 20. x’ y’ x y tx ty = + x’ y’ x y = cos -sin sin cos x’ y’ 1 1 0 tx 0 1 ty 0 0 1 = x Y 1 x’ y’ 1 cos -sin 0 sin cos 0 0 0 1 = x Y 1 Homogeneous Coordinates and Homogeneous Transformations 20 1. Translation 2. Rotation 3*3 3*1 3*1
  • 21. x’ y’ x y = Sx 0 0 Sy x’ y’ x y = 1 0 0 -1 x’ y’ x y = -1 0 0 1 x’ y’ 1 Sx 0 0 0 Sy 0 0 0 1 = x Y 1 x’ y’ 1 1 0 0 0 -1 0 0 0 1 = x Y 1 x’ y’ 1 -1 0 0 0 1 0 0 0 1 = x Y 1 3. Scaling 4. Mirror/ Reflection Homogeneous Coordinates and Homogeneous Transformations 21
  • 22. x’ y’ x y = 1 Shx Shy 1 x’ y’ 1 1 Shx 0 Shy 1 0 0 0 1 = x Y 1 5. Shear Homogeneous Coordinates and Homogeneous Transformations 22
  • 23. x’ y’ 1 1 0 tx 0 1 ty 0 0 1 = x Y 1 x’ y’ 1 cos -sin 0 sin cos 0 0 0 1 = x Y 1 x’ y’ 1 Sx 0 0 0 Sy 0 0 0 1 = x Y 1 x’ y’ 1 1 0 0 0 -1 0 0 0 1 = x Y 1 x’ y’ 1 -1 0 0 0 1 0 0 0 1 = x Y 1 x’ y’ 1 1 Shx 0 Shy 1 0 0 0 1 = x Y 1 Shearing /shear Translation Rotation Scaling X Mirror / Reflect Y Mirror / Reflect 23
  • 24. Homogeneous Coordinates and Homogeneous Transformations • This 3D representation of a 2D space is called as homogeneous coordinate system and transformation using homogeneous coordinates are called as homogeneous transformations. • Expressing positions in homogeneous coordinate system allow the users to represent geometric transformations in the form of matrix multiplication. 24
  • 25. Composite Transformations / Concatenations 25 [P'] = [Tn] [Tn-1] [Tn-2]…… [T3] [T2] [T1] [P] [P'] = [T] [P] [T1], [T2], [T3],…….., [Tn-2], [Tn-1],[Tn]
  • 26. 1. Point “A” (4,3) is rotated counterclockwise by 45°. Find the rotation matrix and coordinates of the resultant point. 26
  • 27. 1. Point “A” (4,3) is rotated counterclockwise by 45°. Find the rotation matrix and coordinates of the resultant point. 27 [A'] [T]Rotation [A] [T]
  • 28. 1. Point “A” (4,3) is rotated counterclockwise by 45°. Find the rotation matrix and coordinates of the resultant point. 28
  • 29. 2. Translate a polygon PQR, P(2,5), Q(7,10) and R(10,2), by 3 units in X direction and 4 units in Y direction. Identify the transformed coordinates. 29
  • 30. 2. Translate a polygon PQR, P(2,5), Q(7,10) and R(10,2), by 3 units in X direction and 4 units in Y direction. Identify the transformed coordinates. 30
  • 31. 2. Translate a polygon PQR, P(2,5), Q(7,10) and R(10,2), by 3 units in X direction and 4 units in Y direction. Identify the transformed coordinates. 31
  • 32. 2. Translate a polygon PQR, P(2,5), Q(7,10) and R(10,2), by 3 units in X direction and 4 units in Y direction. Identify the transformed coordinates. 32
  • 33. 2. Translate a polygon PQR, P(2,5), Q(7,10) and R(10,2), by 3 units in X direction and 4 units in Y direction. Identify the transformed coordinates. 33
  • 34. 2. Translate a polygon PQR, P(2,5), Q(7,10) and R(10,2), by 3 units in X direction and 4 units in Y direction. Identify the transformed coordinates. 34
  • 35. 3. Polygon ABC, A (2,3), B( 0,10) and C(5,10), is moved in such a way that, new coordinates of point A are (10,10). Find transformation matrix and the resultant coordinates. 35
  • 36. 3. Polygon ABC, A (2,3), B( 0,10) and C(5,10), is moved in such a way that, new coordinates of point A are (10,10). Find transformation matrix and the resultant coordinates. 36
  • 37. 3. Polygon ABC, A (2,3), B( 0,10) and C(5,10), is moved in such a way that, new coordinates of point A are (10,10). Find transformation matrix and the resultant coordinates. 37