Computer Graphics CC416 Week 15 3D Graphics.

Slides:



Advertisements
Similar presentations
3D Transformations Assist. Prof. Dr. Ahmet Sayar
Advertisements

Computer Graphics: 3D Transformations
COMPUTER GRAPHICS 2D TRANSFORMATIONS.
Geometric Transformations
Three Dimensional Modeling Transformations
CMPE 466 COMPUTER GRAPHICS
Transformations II Week 2, Wed Jan 17
CMPE 466 COMPUTER GRAPHICS
1 CSCE 441 Computer Graphics: 2D Transformations Jinxiang Chai.
Computer Graphics University of Palestine Dr. Sana’a Wafa Al-Sayegh
Computer Graphics with OpenGL 3e
2D Transformations Unit - 3. Why Transformations? In graphics, once we have an object described, transformations are used to move that object, scale it.
3D Graphics Goal: To produce 2D images of a mathematically described 3D environment Issues: –Describing the environment: Modeling (mostly later) –Computing.
CS 450: Computer Graphics 2D TRANSFORMATIONS
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.
Mathematical Fundamentals
5.2 Three-Dimensional Geometric and Modeling Transformations 2D3D Consideration for the z coordinate.
Geometric Transformation. So far…. We have been discussing the basic elements of geometric programming. We have discussed points, vectors and their operations.
Transformation of Graphics
2D Transformation of Graphics
CSE 681 Review: Transformations. CSE 681 Transformations Modeling transformations build complex models by positioning (transforming) simple components.
Transformations Jehee Lee Seoul National University.
Geometric Transformations
CS 376 Introduction to Computer Graphics 02 / 16 / 2007 Instructor: Michael Eckmann.
Computer Graphics, KKU. Lecture 51 Transformations Given two frames in an affine space of dimension n, we can find a ( n+1 ) x ( n +1) matrix that.
Jinxiang Chai CSCE441: Computer Graphics 3D Transformations 0.
Computer Graphics 2D Transformations. 2 of 74 Contents In today’s lecture we’ll cover the following: –Why transformations –Transformations Translation.
16/5/ :47 UML Computer Graphics Conceptual Model Application Model Application Program Graphics System Output Devices Input Devices API Function.
Computer Graphics 3D Transformations. Translation.
Two-Dimensional Geometric Transformations ch5. 참조 Subjects : Basic Transformations Homogeneous Coordinates Composite Transformations Other Transformations.
Geometric Transformations
Transformations CS 445/645 Introduction to Computer Graphics David Luebke, Spring 2003.
12/24/2015 A.Aruna/Assistant professor/IT/SNSCE 1.
3D Transformation A 3D point (x,y,z) – x,y, and z coordinates
Geometric Transformations UBI 516 Advanced Computer Graphics Aydın Öztürk
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.
3-D Geometric Transformations
Lecture 5: Introduction to 3D
Learning Objectives Affine transformations Affine transformations Translation Translation Rotation Rotation Scaling Scaling Reflection Reflection Shear.
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.
CS 325 Introduction to Computer Graphics 02 / 19 / 2010 Instructor: Michael Eckmann.
Geometric Transformations Ceng 477 Introduction to Computer Graphics Computer Engineering METU.
3D Geometry and Transformations
Computer Graphics Lecture 19 PROJECTIONS I Taqdees A. Siddiqi
Instructor: Dr. Shereen Aly Taie Basic Two-Dimensional Geometric Transformation 5.2 Matrix Representations and Homogeneous Coordinates 5.3 Inverse.
Homogeneous Coordinates They work, but where do they come from? Jonathan Senning
Transformations University of British Columbia CPSC 314 Computer Graphics Jan-Apr 2016 Tamara Munzner.
Objectives Introduce standard transformations Introduce standard transformations Derive homogeneous coordinate transformation matrices Derive homogeneous.
Forward Projection Pipeline and Transformations CENG 477 Introduction to Computer Graphics.
Chapter 11 Three-Dimensional Geometric and Modeling Transformations
Math Fundamentals Maths revisit.
Geometric Transformations
3D Geometric Transformation
3. Transformation
Geometric Transformations Hearn & Baker Chapter 5
2D Transformations By: KanwarjeetSingh
Computer Graphics Transformations.
3D Transformation.
Computer Graphics Lecture 18 3-D Transformations-II Taqdees A
Computer Graphics 3D Transformations
Computer Graphics Transformations.
Line and Character Attributes 2-D Transformation
Chapter IV Spaces and Transforms
Geometric Transformations for Computer Graphics
(c) University of Wisconsin, CS559
Geometric Objects and Transformations (II)
CSCE441: Computer Graphics 2D/3D Transformations
Transformations.
Translation in Homogeneous Coordinates
Presentation transcript:

Computer Graphics CC416 Week 15 3D Graphics

3D Transformations

Three Dimensional Modeling Transformations Methods for object modeling transformation in three dimensions are extended from two dimensional methods by including consideration for the z coordinate.

Three Dimensional Modeling Transformations Generalize from 2D by including z coordinate Straightforward for translation and scale, rotation more difficult Homogeneous coordinates: 4 components Transformation matrices: 4×4 elements

3D Point We will consider points as column vectors. Thus, a typical point with coordinates (x, y, z) is represented as:

3D Point Homogenous Coordinate A 3D point P is represented in homogeneous coordinates by a 4-dim. Vect:

3D Point Homogenous Coordinate We don't lose anything The main advantage: it is easier to compose translation and rotation Everything is matrix multiplication

Right Hand coordinate system: Left Hand coordinate system: 3D Coordinate Systems Right Hand coordinate system: Left Hand coordinate system:

3D Transformation In homogeneous coordinates, 3D transformations are represented by 4×4 matrixes:

3D Translation

3D Translation P is translated to P' by:

3D Translation An object is translated in 3D dimensional by transforming each of the defining points of the objects .

3D Translation Inverse Translation: An Object represented as a set of polygon surfaces, is translated by translate each vertex of each surface and redraw the polygon facets in the new position. Inverse Translation:

3D Scaling

3D Scaling About origin: Changes the size of the object and repositions the object relative to the coordinate origin.

3D Scaling About any fixed point:

3D Reflections

About an axis: equivalent to 180˚rotation about that axis 3D Reflections About an axis: equivalent to 180˚rotation about that axis

3D Reflections About a plane: A reflection through the xy plane: A reflections through the xz and the yz planes are defined similarly.

3D Shearing

3D Shearing Modify object shapes Useful for perspective projections: E.g. draw a cube (3D) on a screen (2D) Alter the values for x and y by an amount proportional to the distance from zref

3D Shearing

Composite 3D Transformations

Composite 3D Transformations Same way as in two dimensions: Multiply matrices Rightmost term in matrix product is the first transformation to be applied

3D Rotation

3D Rotation In general, rotations are specified by a rotation axis and an angle. In two-dimensions there is only one choice of a rotation axis that leaves points in the plane.

3D Rotation The easiest rotation axes are those that parallel to the coordinate axis. Positive rotation angles produce counterclockwise rotations about a coordinate axix, if we are looking along the positive half of the axis toward the coordinate origin.

Coordinate Axis Rotations

Coordinate Axis Rotations Z-axis rotation: For z axis same as 2D rotation:

Coordinate Axis Rotations Obtain rotations around other axes through cyclic permutation of coordinate parameters:

Coordinate Axis Rotations X-axis rotation:

Coordinate Axis Rotations Y-axis rotation:

General Three Dimensional Rotations

General Three Dimensional Rotations Rotation axis parallel with coordinate axis (Example x axis):

General Three Dimensional Rotations An arbitrary axis (with the rotation axis projected onto the Z axis):

General Three Dimensional Rotations A rotation matrix for any axis that does not coincide with a coordinate axis can be set up as a composite transformation involving combination of translations and the coordinate-axes rotations: Translate the object so that the rotation axis passes through the coordinate origin Rotate the object so that the axis rotation coincides with one of the coordinate axes Perform the specified rotation about that coordinate axis Apply inverse rotation axis back to its original orientation Apply the inverse translation to bring the rotation axis back to its original position

Transformations Between Coordinate Systems

Transformations Between Coordinate Systems Translate such that the origins overlap Rotate such that the axes overlap