Multiplication M1 v1 = v2 4 0 3 -2 4.-2 + 0.2 + 3.4 4 1 -1 7 2 = 1.-2 + -1.2 + 7.4 = 24 -3 3 2 4 -3.-2 + 3.2 + 2.4 20 M1 M2 = M3 4 0 3 -2 3 1 4 12 25 1.

Slides:



Advertisements
Similar presentations
Computer Graphics: 2D Transformations
Advertisements

1GR2-00 GR2 Advanced Computer Graphics AGR Lecture 2 Basic Modelling.
Computer Graphics 2D & 3D Transformation.
COMPUTER GRAPHICS 2D TRANSFORMATIONS.
Gursharan Singh Tatla TRANSFORMATIONS Gursharan Singh Tatla Gursharan Singh Tatla.
Geometric Transformations
2D TRANSFORMATIONS.
1 Geometrical Transformation 2 Outline General Transform 3D Objects Quaternion & 3D Track Ball.
Linear Algebra and SVD (Some slides adapted from Octavia Camps)
CS 4731: Computer Graphics Lecture 7: Introduction to Transforms, 2D transforms Emmanuel Agu.
Elementary 3D Transformations - a "Graphics Engine" Transformation procedures Transformations of coordinate systems Translation Scaling Rotation.
Graphics-1 Gentle Introduction to Computer Graphics (2) Based on: –David Brogan’s “Introduction to Computer Graphics” Course Slides, University of Virginia.
1 CSCE 441 Computer Graphics: 2D Transformations Jinxiang Chai.
2.1 si SI31 Advanced Computer Graphics AGR Lecture 2 Basic Modelling.
Computer Graphics CSC 630 Lecture 2- Linear Algebra.
©College of Computer and Information Science, Northeastern UniversityJune 26, CS U540 Computer Graphics Prof. Harriet Fell Spring 2009 Lecture 11.
Course Website: Computer Graphics 3: 2D Transformations.
2D Transformations x y x y x y. 2D Transformation Given a 2D object, transformation is to change the object’s Position (translation) Size (scaling) Orientation.
2D Transformations Unit - 3. Why Transformations? In graphics, once we have an object described, transformations are used to move that object, scale it.
3D Geometric Transformation Point in 3D space –Position (x, y, z) –Color (r, g, b) –Normal (Nx, Ny, Nz) Homogenous Coordinates –Position (x,y,z,w) –Usually.
UNIT - 5 3D transformation and viewing. 3D Point  We will consider points as column vectors. Thus, a typical point with coordinates (x, y, z) is represented.
3D Transformation. In 3D, we have x, y, and z. We will continue use column vectors:. Homogenous systems:. 3D Transformation glVertex3f(x, y,z);
5.2 Three-Dimensional Geometric and Modeling Transformations 2D3D Consideration for the z coordinate.
2D Transformations.
Lecture Notes: Computer Graphics.
2D Geometric Transformations
 2D Transformations 2D Transformations  Translation Translation  Rotation Rotation  Scaling Scaling.
CSE 681 Review: Transformations. CSE 681 Transformations Modeling transformations build complex models by positioning (transforming) simple components.
CS 376 Introduction to Computer Graphics 02 / 16 / 2007 Instructor: Michael Eckmann.
Computer Graphics 2D Transformations. 2 of 74 Contents In today’s lecture we’ll cover the following: –Why transformations –Transformations Translation.
1 Computer Graphics Week9 -3D Geometric Transformation.
16/5/ :47 UML Computer Graphics Conceptual Model Application Model Application Program Graphics System Output Devices Input Devices API Function.
2D Transformation. Transformation changes an object’s: – Position(Translation) – Size(Scaling) – Orientation(Rotation) – Shape(Deformation) Transformation.
3D Transformations. Translation x’ = x + tx y’ = y + ty z’ = z + tz P = P’ = T = P’ = T. P tx ty tz xyz1xyz1 x’ y’ z’ 1 x y.
Multimedia Programming 07: Image Warping Keyframe Animation Departments of Digital Contents Sang Il Park.
2D Geometric Transformation Translation A translation is applied to an object by repositioning it along a straight-line path from one coordinate location.
January 19, y X Z Translations Objects are usually defined relative to their own coordinate system. We can translate points in space to new positions.
CS552: Computer Graphics Lecture 4: 2D Graphics. Recap 2D Graphics Coordinate systems 2D Transformations o Translation o Scaling o Rotation Combining.
II-1 Transformations Transformations are needed to: –Position objects defined relative to the origin –Build scenes based on hierarchies –Project objects.
Learning Objectives Affine transformations Affine transformations Translation Translation Rotation Rotation Scaling Scaling Reflection Reflection Shear.
1 By Dr. HANY ELSALAMONY.  We have seen how to create models in the 3D world. We discussed transforms in lecture 3, and we have used some transformations.
Homogeneous Coordinates and Matrix Representations Cartesian coordinate (x, y, z) Homogeneous coordinate (x h, y h, z h, h) Usually h = 1. But there are.
III- 1 III 3D Transformation Homogeneous Coordinates The three dimensional point (x, y, z) is represented by the homogeneous coordinate (x, y, z, 1) In.
Jinxiang Chai CSCE441: Computer Graphics 3D Transformations 0.
1 Teaching Innovation - Entrepreneurial - Global The Centre for Technology enabled Teaching & Learning, N Y S S, India DTEL DTEL (Department for Technology.
CS 325 Introduction to Computer Graphics 02 / 19 / 2010 Instructor: Michael Eckmann.
Geometric Transformations Ceng 477 Introduction to Computer Graphics Computer Engineering METU.
Computer Graphic 2 D Transformation.
CSCE 441 Computer Graphics: 2D Transformations
Modeling Transformation
1 U08181 Computer Graphics Clipping Transformations –Transformations and matrices –Homogeneous matrices –Transformations in SVG.
Robotic Arms and Matrices By Chris Wong and Chris Marino.
Forward Projection Pipeline and Transformations CENG 477 Introduction to Computer Graphics.
2D Geometry - points and polygons
CPT450 – Computer Graphics
Modeling Transformations
2D Transformations By: KanwarjeetSingh
2D Geometric Transformations
Review: Transformations
3D Transformation.
3D Geometric Transformations
Introduction to Computer Graphics CS 445 / 645
Review: Transformations
2D Transformations y y x x y x.
Computer Graphics Transformations
Three-Dimensional Graphics
Transformations in 3 Dimensions CS /28/2018 Dr. Mark L. Hornick
Three-Dimensional Graphics
TWO DIMENSIONAL TRANSFORMATION
Rigid Body Transformations
Presentation transcript:

Multiplication M1 v1 = v = = M1 M2 = M = v3 M2 = v =

Gauss-Jordan x + y + -z = 7 -x + 2y + -z = -5 -y + 2z = –1 x y = z x + y + -z = 7 3y + -2z = 2 -y + 2z = –1 x y = z x =.. y =.. z = x 3/4 1/2 1/ y = 1/2 1 1/ z 1/4 1/2 3/4 8

Projection x y z Line: lineVec == supportVecLine + a * directionVecLine Plane: planeVec == supVecPlane + b * dirVec1Plane + c * dirVec2Plane Intersection: lineVec == planeVec ==> supportVecLine + a * directionVecLine == supVecPlane + b * dirVec1Plane + c * dirVec2Plane In figure: eyeVec + a * (starVec – eyeVec) == b* (0 1 0) + c* (0 0 1) (3 equations, 3 unknowns)

Rotation around origin a b r cos a cos b r cos b r sin b a r cos a sin b r sin a cos b x r cos a Rotation Rb in x y plane: y r sin a x’ r cos a cos b - r sin a sin b x cos b - y sin b cos b -sin b x y’ r cos a sin b + r sin a cos b x sin b + y cos b sin b cos b y r x’ y’ xyxy r sin a r cos a r sin a sin b = = = = Generalized in 3 planes: Rxu = 0 cos u -sin u 0 sin u cos u cos v 0 sin v Ryv = sin v 0 cos v cos w –sin w 0 x Rzw = sin w cos w 0 y z Multiply matrices to compose: vRotated = (Rzw Ryv Rxu) vOriginal

Scaling with respect to origin x’ Sx 0 0 x y’ = 0 Sy 0 y z’ 0 0 Sz z

Translation x’ Tx x y’ Ty y z’ Tz z = x’ x Tx y’ y + Ty z’ z Tz = As addition: As multiplication (homogenisation, needed for composition):

Composition Principle To compose transformations: - Homogenize transformation matrices and vectors - Multiply matrices to get composite matrix - Multiply composite matrix by vector to apply all transformations at once Example Rotation around an arbitrary point with homogenized matrices: -Translation to origin: Mt -Rotation around origin: Mr -Translation back: inverse of Mt is Mti -Composed transformation matrix: Mc = Mti Mr Mt -To transform any vector: v’ = Mc v Homogenization makes it possible to compose an arbitrary number of transformations into one transformation matrix. This saves lots of time if there are many vectors to transform, which is typically the case.