-Transforms

-Transforms - Transformations Transformations Bedich Bene,...

Info iconThis preview shows pages 1–3. Sign up to view the full content.

View Full Document Right Arrow Icon
Transformations Bed ř ich Beneš, Ph.D. Purdue University Department of Computer Graphics © Bedrich Benes Transformations transformations are essential closely related to Cg programs (vp) the following should be a review of well-known things (is it?) © Bedrich Benes Homogenous coordinates We use homogenous coordinates in 3D A=[x,y,z,w] The relation between homogenous and Cartesian coordinates is [x,y,z]=[x/w,y/w,z/w] for w=0 the [x,y,z,w] corresponds to a vector (x,y,z) © Bedrich Benes Homogenous coordinates Advantages of using homog. coords: Linear transformations (scale, shear, translate, rotate) can be represented by matrices 4x4 Projective transformation can be represented by matrices 4x4
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Transformations Having matrix A of type 4x4 and a vertex v=[x,y,z,w] The vertex transformation is represented by the matrix multiplication v’= A v to transform a vertex only the matrix must be specified © Bedrich Benes Transformations Example: A corresponds to the translation by the vector (X T ,Y T ,Z T ) A = 1 0 0 X T 0 1 0 Y T 0 0 1 Z T 0 0 0 1 © Bedrich Benes Transformations One of the first things ever performed by hardware is matrix-to-vector multiplication Every vertex must pass a various stages of transformations
Background image of page 2
Image of page 3
This is the end of the preview. Sign up to access the rest of the document.

Page1 / 7

-Transforms - Transformations Transformations Bedich Bene,...

This preview shows document pages 1 - 3. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online