SlideShare a Scribd company logo
1 of 42
Introduction of Transformations
Translation
• It is the straight line movement of an object
from one position to another is called
Translation. Here the object is positioned from
one coordinate location to another.
Types of Transformations
• Translation
• Scaling
• Rotating
• Reflection
• Shearing
Translation
• Translation of point:
• To translate a point from coordinate position
(x, y) to another (x1 y1), we add algebraically
the translation distances Tx and Ty to original
coordinate.
• x1=x+Tx y1=y+Ty
• The translation pair (Tx,Ty) is called as shift
vector.
Translation
• Translation is a movement of objects without
deformation. Every position or point is
translated by the same amount. When the
straight line is translated, then it will be drawn
using endpoints.
• For translating polygon, each vertex of the
polygon is converted to a new position.
Translation
• X' = Dx + X Y' = Dy + Y or P' = T + P where P' =
(X', Y'), T = (Dx, Dy ), P = (X, Y) Here, P(X, Y) is
the original point. T(Dx, Dy) is the translation
factor, i.e. the amount by which the point will
be translated. P'(X’, Y’) is the coordinates of
point P after translation.
Translation
Translation
Translation
• The translation can be represented by a column
vector as
• The top number represents the right and left
movement. A positive number means moving to
the right and a negative number means moving
to the left.
• The bottom number represents up and down
movement. A positive number means moving up
and a negative number means moving down.
• '
Translation
Translation
• The triangle P is mapped onto the triangle Q
by the translation [4,-1]
Translation
• Input : P[] = {5, 6}, T = {1, 1}
• Output : P'[] = {6, 7} =X+TX=5+1=6=Y+TY=6+1
• Input : P[] = {8, 6}, T = {-1, -1}
• Output : P'[] = 8-1=6-1{7, 5}
Translation
P1=(x1,y1)=(3,3)
T=(5,2)
P2=(x2,y2)=(8,5)
We see that
x2=x1+5
y2=y1+2
This means that translation is defined by adding an offset in the x
and y direction: tx and ty:
x2=x1+tx
y2=y1+ty
• From the above figure, you can write that −
• X’ = X + tx
• Y’ = Y + ty
• The pair (tx, ty) is called the translation vector or
shift vector. The above equations can also be
represented using the column vectors.
• P=[X][Y]P=[X][Y]
• p' = [X′][Y′][X′][Y′]
• T = [tx][ty][tx][ty]
• We can write it as −
• P’ = P + T
Rotation
Rotation
• Matrix for rotation is a clockwise direction.
• Matrix for rotation is an anticlockwise
direction.
Rotation
• n rotation, we rotate the object at particular
angle θ theta theta from its origin. From the
following figure, we can see that the point
PX,YX,Y is located at angle φ from the
horizontal X coordinate with distance r from
the origin.
• Let us suppose you want to rotate it at the
angle θ. After rotating it to a new location, you
will get a new point P’ X′,Y′X′,Y′.
Rotation
• Using standard trigonometric the original
coordinate of point PX,YX,Y can be
represented as −
• X=rcosϕ......(1)
• Y=rsinϕ......(2)
•
Rotation
• ame way we can represent the point P’ X′,Y′ as
−
• x′=rcos(ϕ+θ)=rcosϕcosθ−rsinϕsinθ.......(3)
• y′=rsin(ϕ+θ)=rcosϕsinθ+rsinϕcosθ.......
Rotation
• Substituting
equation 1 & 2 in 3 & 4 respectively, we will
get
• x′=xcosθ−ysinθ
• y′=xsinθ+ycosθ
•
Rotation
• Representing the above equation in matrix
form,
• [X′Y′]=[XY][cosθ−sinθsinθcosθ]
• P’ = P . R
Rotation
• Where R is the rotation matrix
• R=[cosθ sinθ
• −sinθ cosθ]
• onsider a point object O has to be rotated from
one angle to another in a 2D plane.
•
• Let-
• Initial coordinates of the object O = (Xold, Yold)
• Initial angle of the object O with respect to origin
= Φ
• Rotation angle = θ
• New coordinates of the object O after rotation =
(Xnew, Ynew)
• his rotation is achieved by using the following
rotation equations-
• Xnew = Xold x cosθ – Yold x sinθ
• Ynew = Xold x sinθ + Yold x cos
• Example: The point (x, y) is to be rotated
• The (xc yc) is a point about which
counterclockwise rotation is done
• Step2: Rotation of (x, y) about the origin
•
• Step3: Translation of center of rotation back
to its original position
Introduction of Transformations (1).pptx
Introduction of Transformations (1).pptx

More Related Content

Similar to Introduction of Transformations (1).pptx

Computer Graphic - Transformations in 2D
Computer Graphic - Transformations in 2DComputer Graphic - Transformations in 2D
Computer Graphic - Transformations in 2D2013901097
 
2 d translation
2 d translation2 d translation
2 d translationMani Kanth
 
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
 
2 d geometric transformations
2 d geometric transformations2 d geometric transformations
2 d geometric transformationsMohd Arif
 
seminar on 2D transformation
seminar on 2D transformationseminar on 2D transformation
seminar on 2D transformation9784
 
Two dimensionaltransformations
Two dimensionaltransformationsTwo dimensionaltransformations
Two dimensionaltransformationsNareek
 
2 d transformation
2 d transformation2 d transformation
2 d transformationAnkit Garg
 
Bla b__________________la -2&3d -DD .ppt
Bla b__________________la -2&3d -DD .pptBla b__________________la -2&3d -DD .ppt
Bla b__________________la -2&3d -DD .pptkdemersal
 
Computer Graphics transformations
Computer Graphics transformationsComputer Graphics transformations
Computer Graphics transformationsswatihans
 
Two dimentional transform
Two dimentional transformTwo dimentional transform
Two dimentional transformPatel Punit
 
2hjsakhvchcvj hSKchvsABJChjSVCHjhvcvdxz.pptx
2hjsakhvchcvj hSKchvsABJChjSVCHjhvcvdxz.pptx2hjsakhvchcvj hSKchvsABJChjSVCHjhvcvdxz.pptx
2hjsakhvchcvj hSKchvsABJChjSVCHjhvcvdxz.pptxHarikumar Rajasekar
 
Angle and Slope, Isometri
Angle and Slope, IsometriAngle and Slope, Isometri
Angle and Slope, IsometriSri Handayani
 
Cg 3 d translation
 Cg   3 d translation Cg   3 d translation
Cg 3 d translationMeenakshiK19
 
2D- Transformation
2D- Transformation2D- Transformation
2D- Transformationnehrurevathy
 
2D Transformation in Computer Graphics
2D Transformation in Computer Graphics2D Transformation in Computer Graphics
2D Transformation in Computer GraphicsA. S. M. Shafi
 

Similar to Introduction of Transformations (1).pptx (20)

Computer Graphics - transformations in 2d
Computer Graphics - transformations in 2dComputer Graphics - transformations in 2d
Computer Graphics - transformations in 2d
 
Computer Graphic - Transformations in 2D
Computer Graphic - Transformations in 2DComputer Graphic - Transformations in 2D
Computer Graphic - Transformations in 2D
 
2 d translation
2 d translation2 d translation
2 d translation
 
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)
 
2D Transformation.pdf
2D Transformation.pdf2D Transformation.pdf
2D Transformation.pdf
 
2 d geometric transformations
2 d geometric transformations2 d geometric transformations
2 d geometric transformations
 
seminar on 2D transformation
seminar on 2D transformationseminar on 2D transformation
seminar on 2D transformation
 
Two dimensionaltransformations
Two dimensionaltransformationsTwo dimensionaltransformations
Two dimensionaltransformations
 
2-D Transformations.pdf
2-D Transformations.pdf2-D Transformations.pdf
2-D Transformations.pdf
 
2 d transformation
2 d transformation2 d transformation
2 d transformation
 
2 d transformations
2 d transformations2 d transformations
2 d transformations
 
Bla b__________________la -2&3d -DD .ppt
Bla b__________________la -2&3d -DD .pptBla b__________________la -2&3d -DD .ppt
Bla b__________________la -2&3d -DD .ppt
 
Quadratic equation.pptx
Quadratic equation.pptxQuadratic equation.pptx
Quadratic equation.pptx
 
Computer Graphics transformations
Computer Graphics transformationsComputer Graphics transformations
Computer Graphics transformations
 
Two dimentional transform
Two dimentional transformTwo dimentional transform
Two dimentional transform
 
2hjsakhvchcvj hSKchvsABJChjSVCHjhvcvdxz.pptx
2hjsakhvchcvj hSKchvsABJChjSVCHjhvcvdxz.pptx2hjsakhvchcvj hSKchvsABJChjSVCHjhvcvdxz.pptx
2hjsakhvchcvj hSKchvsABJChjSVCHjhvcvdxz.pptx
 
Angle and Slope, Isometri
Angle and Slope, IsometriAngle and Slope, Isometri
Angle and Slope, Isometri
 
Cg 3 d translation
 Cg   3 d translation Cg   3 d translation
Cg 3 d translation
 
2D- Transformation
2D- Transformation2D- Transformation
2D- Transformation
 
2D Transformation in Computer Graphics
2D Transformation in Computer Graphics2D Transformation in Computer Graphics
2D Transformation in Computer Graphics
 

Recently uploaded

Mixin Classes in Odoo 17 How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17  How to Extend Models Using Mixin ClassesMixin Classes in Odoo 17  How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17 How to Extend Models Using Mixin ClassesCeline George
 
Introduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsIntroduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsTechSoup
 
ICT role in 21st century education and it's challenges.
ICT role in 21st century education and it's challenges.ICT role in 21st century education and it's challenges.
ICT role in 21st century education and it's challenges.MaryamAhmad92
 
ComPTIA Overview | Comptia Security+ Book SY0-701
ComPTIA Overview | Comptia Security+ Book SY0-701ComPTIA Overview | Comptia Security+ Book SY0-701
ComPTIA Overview | Comptia Security+ Book SY0-701bronxfugly43
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdfQucHHunhnh
 
Holdier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfHoldier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfagholdier
 
How to Create and Manage Wizard in Odoo 17
How to Create and Manage Wizard in Odoo 17How to Create and Manage Wizard in Odoo 17
How to Create and Manage Wizard in Odoo 17Celine George
 
General Principles of Intellectual Property: Concepts of Intellectual Proper...
General Principles of Intellectual Property: Concepts of Intellectual  Proper...General Principles of Intellectual Property: Concepts of Intellectual  Proper...
General Principles of Intellectual Property: Concepts of Intellectual Proper...Poonam Aher Patil
 
Unit-V; Pricing (Pharma Marketing Management).pptx
Unit-V; Pricing (Pharma Marketing Management).pptxUnit-V; Pricing (Pharma Marketing Management).pptx
Unit-V; Pricing (Pharma Marketing Management).pptxVishalSingh1417
 
SOC 101 Demonstration of Learning Presentation
SOC 101 Demonstration of Learning PresentationSOC 101 Demonstration of Learning Presentation
SOC 101 Demonstration of Learning Presentationcamerronhm
 
How to Give a Domain for a Field in Odoo 17
How to Give a Domain for a Field in Odoo 17How to Give a Domain for a Field in Odoo 17
How to Give a Domain for a Field in Odoo 17Celine George
 
Food safety_Challenges food safety laboratories_.pdf
Food safety_Challenges food safety laboratories_.pdfFood safety_Challenges food safety laboratories_.pdf
Food safety_Challenges food safety laboratories_.pdfSherif Taha
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfciinovamais
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introductionMaksud Ahmed
 
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptxMaritesTamaniVerdade
 
Magic bus Group work1and 2 (Team 3).pptx
Magic bus Group work1and 2 (Team 3).pptxMagic bus Group work1and 2 (Team 3).pptx
Magic bus Group work1and 2 (Team 3).pptxdhanalakshmis0310
 
How to Manage Global Discount in Odoo 17 POS
How to Manage Global Discount in Odoo 17 POSHow to Manage Global Discount in Odoo 17 POS
How to Manage Global Discount in Odoo 17 POSCeline George
 
Understanding Accommodations and Modifications
Understanding  Accommodations and ModificationsUnderstanding  Accommodations and Modifications
Understanding Accommodations and ModificationsMJDuyan
 
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...ZurliaSoop
 

Recently uploaded (20)

Mixin Classes in Odoo 17 How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17  How to Extend Models Using Mixin ClassesMixin Classes in Odoo 17  How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17 How to Extend Models Using Mixin Classes
 
Introduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsIntroduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The Basics
 
ICT role in 21st century education and it's challenges.
ICT role in 21st century education and it's challenges.ICT role in 21st century education and it's challenges.
ICT role in 21st century education and it's challenges.
 
ComPTIA Overview | Comptia Security+ Book SY0-701
ComPTIA Overview | Comptia Security+ Book SY0-701ComPTIA Overview | Comptia Security+ Book SY0-701
ComPTIA Overview | Comptia Security+ Book SY0-701
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
 
Holdier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfHoldier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdf
 
How to Create and Manage Wizard in Odoo 17
How to Create and Manage Wizard in Odoo 17How to Create and Manage Wizard in Odoo 17
How to Create and Manage Wizard in Odoo 17
 
General Principles of Intellectual Property: Concepts of Intellectual Proper...
General Principles of Intellectual Property: Concepts of Intellectual  Proper...General Principles of Intellectual Property: Concepts of Intellectual  Proper...
General Principles of Intellectual Property: Concepts of Intellectual Proper...
 
Unit-V; Pricing (Pharma Marketing Management).pptx
Unit-V; Pricing (Pharma Marketing Management).pptxUnit-V; Pricing (Pharma Marketing Management).pptx
Unit-V; Pricing (Pharma Marketing Management).pptx
 
SOC 101 Demonstration of Learning Presentation
SOC 101 Demonstration of Learning PresentationSOC 101 Demonstration of Learning Presentation
SOC 101 Demonstration of Learning Presentation
 
How to Give a Domain for a Field in Odoo 17
How to Give a Domain for a Field in Odoo 17How to Give a Domain for a Field in Odoo 17
How to Give a Domain for a Field in Odoo 17
 
Food safety_Challenges food safety laboratories_.pdf
Food safety_Challenges food safety laboratories_.pdfFood safety_Challenges food safety laboratories_.pdf
Food safety_Challenges food safety laboratories_.pdf
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdf
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introduction
 
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
 
Magic bus Group work1and 2 (Team 3).pptx
Magic bus Group work1and 2 (Team 3).pptxMagic bus Group work1and 2 (Team 3).pptx
Magic bus Group work1and 2 (Team 3).pptx
 
How to Manage Global Discount in Odoo 17 POS
How to Manage Global Discount in Odoo 17 POSHow to Manage Global Discount in Odoo 17 POS
How to Manage Global Discount in Odoo 17 POS
 
Asian American Pacific Islander Month DDSD 2024.pptx
Asian American Pacific Islander Month DDSD 2024.pptxAsian American Pacific Islander Month DDSD 2024.pptx
Asian American Pacific Islander Month DDSD 2024.pptx
 
Understanding Accommodations and Modifications
Understanding  Accommodations and ModificationsUnderstanding  Accommodations and Modifications
Understanding Accommodations and Modifications
 
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
Jual Obat Aborsi Hongkong ( Asli No.1 ) 085657271886 Obat Penggugur Kandungan...
 

Introduction of Transformations (1).pptx

  • 2.
  • 3. Translation • It is the straight line movement of an object from one position to another is called Translation. Here the object is positioned from one coordinate location to another.
  • 4. Types of Transformations • Translation • Scaling • Rotating • Reflection • Shearing
  • 5. Translation • Translation of point: • To translate a point from coordinate position (x, y) to another (x1 y1), we add algebraically the translation distances Tx and Ty to original coordinate. • x1=x+Tx y1=y+Ty • The translation pair (Tx,Ty) is called as shift vector.
  • 6. Translation • Translation is a movement of objects without deformation. Every position or point is translated by the same amount. When the straight line is translated, then it will be drawn using endpoints. • For translating polygon, each vertex of the polygon is converted to a new position.
  • 7.
  • 9. • X' = Dx + X Y' = Dy + Y or P' = T + P where P' = (X', Y'), T = (Dx, Dy ), P = (X, Y) Here, P(X, Y) is the original point. T(Dx, Dy) is the translation factor, i.e. the amount by which the point will be translated. P'(X’, Y’) is the coordinates of point P after translation.
  • 10.
  • 13. Translation • The translation can be represented by a column vector as • The top number represents the right and left movement. A positive number means moving to the right and a negative number means moving to the left. • The bottom number represents up and down movement. A positive number means moving up and a negative number means moving down. • '
  • 15. Translation • The triangle P is mapped onto the triangle Q by the translation [4,-1]
  • 16.
  • 17. Translation • Input : P[] = {5, 6}, T = {1, 1} • Output : P'[] = {6, 7} =X+TX=5+1=6=Y+TY=6+1 • Input : P[] = {8, 6}, T = {-1, -1} • Output : P'[] = 8-1=6-1{7, 5}
  • 18. Translation P1=(x1,y1)=(3,3) T=(5,2) P2=(x2,y2)=(8,5) We see that x2=x1+5 y2=y1+2 This means that translation is defined by adding an offset in the x and y direction: tx and ty: x2=x1+tx y2=y1+ty
  • 19.
  • 20. • From the above figure, you can write that − • X’ = X + tx • Y’ = Y + ty • The pair (tx, ty) is called the translation vector or shift vector. The above equations can also be represented using the column vectors. • P=[X][Y]P=[X][Y] • p' = [X′][Y′][X′][Y′] • T = [tx][ty][tx][ty] • We can write it as − • P’ = P + T
  • 21.
  • 22.
  • 24.
  • 25. Rotation • Matrix for rotation is a clockwise direction. • Matrix for rotation is an anticlockwise direction.
  • 26. Rotation • n rotation, we rotate the object at particular angle θ theta theta from its origin. From the following figure, we can see that the point PX,YX,Y is located at angle φ from the horizontal X coordinate with distance r from the origin. • Let us suppose you want to rotate it at the angle θ. After rotating it to a new location, you will get a new point P’ X′,Y′X′,Y′.
  • 27. Rotation • Using standard trigonometric the original coordinate of point PX,YX,Y can be represented as − • X=rcosϕ......(1) • Y=rsinϕ......(2) •
  • 28. Rotation • ame way we can represent the point P’ X′,Y′ as − • x′=rcos(ϕ+θ)=rcosϕcosθ−rsinϕsinθ.......(3) • y′=rsin(ϕ+θ)=rcosϕsinθ+rsinϕcosθ.......
  • 29. Rotation • Substituting equation 1 & 2 in 3 & 4 respectively, we will get • x′=xcosθ−ysinθ • y′=xsinθ+ycosθ •
  • 30. Rotation • Representing the above equation in matrix form, • [X′Y′]=[XY][cosθ−sinθsinθcosθ] • P’ = P . R
  • 31. Rotation • Where R is the rotation matrix • R=[cosθ sinθ • −sinθ cosθ]
  • 32. • onsider a point object O has to be rotated from one angle to another in a 2D plane. • • Let- • Initial coordinates of the object O = (Xold, Yold) • Initial angle of the object O with respect to origin = Φ • Rotation angle = θ • New coordinates of the object O after rotation = (Xnew, Ynew)
  • 33. • his rotation is achieved by using the following rotation equations- • Xnew = Xold x cosθ – Yold x sinθ • Ynew = Xold x sinθ + Yold x cos
  • 34.
  • 35.
  • 36. • Example: The point (x, y) is to be rotated • The (xc yc) is a point about which counterclockwise rotation is done
  • 37.
  • 38. • Step2: Rotation of (x, y) about the origin •
  • 39.
  • 40. • Step3: Translation of center of rotation back to its original position