3D Tranformations. CS 4620 Lecture 6. Cornell CS4620 Fall 2013 Lecture 6. 2013 Steve Marschner (with previous instructors James/Bala)

Similar documents
Essential Mathematics for Computer Graphics fast

CIS 536/636 Introduction to Computer Graphics. Kansas State University. CIS 536/636 Introduction to Computer Graphics

Metrics on SO(3) and Inverse Kinematics

Understanding Rotations

Lecture 7. Matthew T. Mason. Mechanics of Manipulation. Lecture 7. Representing Rotation. Kinematic representation: goals, overview

Introduction to Computer Graphics Marie-Paule Cani & Estelle Duveau

Rotation Matrices and Homogeneous Transformations

Computer Animation. Lecture 2. Basics of Character Animation

Origins of the Unusual Space Shuttle Quaternion Definition

Kinematical Animation

B4 Computational Geometry

Recall that two vectors in are perpendicular or orthogonal provided that their dot

Content. Chapter 4 Functions Basic concepts on real functions 62. Credits 11

Interactive Computer Graphics

Mechanics lecture 7 Moment of a force, torque, equilibrium of a body

Two hours UNIVERSITY OF MANCHESTER SCHOOL OF COMPUTER SCIENCE. M.Sc. in Advanced Computer Science. Friday 18 th January 2008.

Lecture L3 - Vectors, Matrices and Coordinate Transformations

Advanced Computer Graphics (2IV40) ~ 3D Transformations. Types (geometric) Types (algebraic) 3D Transformations. y + c 1. x = a 1.

Solving Simultaneous Equations and Matrices

Recall the basic property of the transpose (for any A): v A t Aw = v w, v, w R n.

An inertial haptic interface for robotic applications

521493S Computer Graphics. Exercise 2 & course schedule change

Animations in Creo 3.0

3 Orthogonal Vectors and Matrices

CS 4204 Computer Graphics

Kinematics of Robots. Alba Perez Gracia

Geometric Transformations

2. Dynamics, Control and Trajectory Following

Fundamentals of Computer Animation

KINEMATICS OF PARTICLES RELATIVE MOTION WITH RESPECT TO TRANSLATING AXES

α = u v. In other words, Orthogonal Projection

Chapter 17. Orthogonal Matrices and Symmetries of Space

Chapter 6. Orthogonality

Mathematics Course 111: Algebra I Part IV: Vector Spaces

5. Orthogonal matrices

animation animation shape specification as a function of time

Magnetometer Realignment: Theory and Implementation

Geometric Camera Parameters

CMSC 425: Lecture 13 Animation for Games: Basics Tuesday, Mar 26, 2013

TWO-DIMENSIONAL TRANSFORMATION

3. Let A and B be two n n orthogonal matrices. Then prove that AB and BA are both orthogonal matrices. Prove a similar result for unitary matrices.

State of Stress at Point

Animation (-4, -2, 0 ) + (( 2, 6, -4 ) - (-4, -2, 0 ))*.75 = (-4, -2, 0 ) + ( 6, 8, -4)*.75 = (.5, 4, -3 ).

CHAPTER FIVE. 5. Equations of Lines in R 3

[1] Diagonal factorization

2D Geometric Transformations

Affine Transformations

Lecture 2: Homogeneous Coordinates, Lines and Conics

Adding vectors We can do arithmetic with vectors. We ll start with vector addition and related operations. Suppose you have two vectors

MATH 304 Linear Algebra Lecture 18: Rank and nullity of a matrix.

Lectures notes on orthogonal matrices (with exercises) Linear Algebra II - Spring 2004 by D. Klain

DERIVATIVES AS MATRICES; CHAIN RULE

Section 12.6: Directional Derivatives and the Gradient Vector

Chapter 10 Rotational Motion. Copyright 2009 Pearson Education, Inc.

Physics 235 Chapter 1. Chapter 1 Matrices, Vectors, and Vector Calculus

CS 534: Computer Vision 3D Model-based recognition

w = COI EYE view direction vector u = w ( 010,, ) cross product with y-axis v = w u up vector

Unified Lecture # 4 Vectors

Lecture 5: Singular Value Decomposition SVD (1)

Lecture 1: Systems of Linear Equations

Chapter. 4 Mechanism Design and Analysis

x1 x 2 x 3 y 1 y 2 y 3 x 1 y 2 x 2 y 1 0.

December 4, 2013 MATH 171 BASIC LINEAR ALGEBRA B. KITCHENS

Basic Principles of Inertial Navigation. Seminar on inertial navigation systems Tampere University of Technology

Vector Notation: AB represents the vector from point A to point B on a graph. The vector can be computed by B A.

Chapter 2 - Kinematics

Lecture Notes. Fundamentals of Computer Graphics. Prof. Michael Langer School of Computer Science McGill University

Linear algebra and the geometry of quadratic equations. Similarity transformations and orthogonal matrices

2-View Geometry. Mark Fiala Ryerson University

Vector Math Computer Graphics Scott D. Anderson

Time Domain and Frequency Domain Techniques For Multi Shaker Time Waveform Replication

Lecture 3: Coordinate Systems and Transformations

Calculation of Azimuth, Elevation and Polarization for non-horizontal aligned Antennas

CS3220 Lecture Notes: QR factorization and orthogonal transformations

Subspace Analysis and Optimization for AAM Based Face Alignment

Geometry: Unit 1 Vocabulary TERM DEFINITION GEOMETRIC FIGURE. Cannot be defined by using other figures.

2D Geometrical Transformations. Foley & Van Dam, Chapter 5

Elasticity Theory Basics

v w is orthogonal to both v and w. the three vectors v, w and v w form a right-handed set of vectors.

Basic CAD/CAM. CHAPTER 5: Geometric Transformation

Summary: Transformations. Lecture 14 Parameter Estimation Readings T&V Sec Parameter Estimation: Fitting Geometric Models

The Singular Value Decomposition in Symmetric (Löwdin) Orthogonalization and Data Compression

Math for Game Programmers: Dual Numbers. Gino van den Bergen

Tutorial for Assignment #2 Gantry Crane Analysis By ANSYS (Mechanical APDL) V.13.0

NEW YORK STATE TEACHER CERTIFICATION EXAMINATIONS

Section 1.1. Introduction to R n

Geometry of Vectors. 1 Cartesian Coordinates. Carlo Tomasi

Given a point cloud, polygon, or sampled parametric curve, we can use transformations for several purposes:

MA 323 Geometric Modelling Course Notes: Day 02 Model Construction Problem

Thnkwell s Homeschool Precalculus Course Lesson Plan: 36 weeks

Orthogonal Projections

animation shape specification as a function of time

Lecture L6 - Intrinsic Coordinates

is in plane V. However, it may be more convenient to introduce a plane coordinate system in V.

Cross product and determinants (Sect. 12.4) Two main ways to introduce the cross product

Linear Programming. March 14, 2014

Equations Involving Lines and Planes Standard equations for lines in space

Transcription:

3D Tranformations CS 4620 Lecture 6 1

Translation 2

Translation 2

Translation 2

Translation 2

Scaling 3

Scaling 3

Scaling 3

Scaling 3

Rotation about z axis 4

Rotation about z axis 4

Rotation about x axis 5

Rotation about x axis 5

Rotation about y axis 6

Rotation about y axis 6

General Rotation Matrices A rotation in 2D is around a point A rotation in 3D is around an axis so 3D rotation is w.r.t a line, not just a point there are many more 3D rotations than 2D a 3D space around a given point, not just 1D 2D 3D 7

Properties of Rotation Matrices Columns of R are mutually orthonormal: RR T =R T R=I Right-handed coordinate systems: det(r)=1 8

Specifying rotations In 2D, a rotation just has an angle In 3D, specifying a rotation is more complex basic rotation about origin: unit vector (axis) and angle convention: positive rotation is CCW when vector is pointing at you Many ways to specify rotation Indirectly through frame transformations Directly through Euler angles: 3 angles about 3 axes (Axis, angle) rotation Quaternions 9

Euler angles An object can be oriented arbitrarily Euler angles: stack up three coord axis rotations ZYX case: Rz(thetaz)*Ry(thetay)*Rx(thetax) heading, attitude, bank (NASA standard airplane coordinates) pitch, yaw, roll 10

Roll, yaw, Pitch 11

3D rotations NASA standard Euler angles: stack up three coord axis rotations ZYX case: Rz(thetaz)*Ry(thetay)*Rx(thetax) 12

Specifying rotations: Euler rotations Euler angles 13

Gimbal Lock 14

Euler angles Gimbal lock removes one degree of freedom worth a look: http://www.youtube.com/watch?v=zc8b2jo7mno (also http://www.youtube.com/watch?v=rrucboljdt4) 15

Matrices for axis-angle rotations Showed matrices for coordinate axis rotations but what if we want rotation about some random axis? Compute by composing elementary transforms transform rotation axis to align with x axis apply rotation inverse transform back into position Just as in 2D this can be interpreted as a similarity transform 16

Building general rotations Using elementary transforms you need three translate axis to pass through origin rotate about y to get into x-y plane rotate about z to align with x axis Alternative: construct frame and change coordinates choose p, u, v, w to be orthonormal frame with p and u matching the rotation axis apply similarity transform T = F R x (θ ) F 1 17

Orthonormal frames in 3D Useful tools for constructing transformations Recall rigid motions affine transforms with pure rotation columns (and rows) form right handed ONB that is, an orthonormal basis 18

Building 3D frames Given a vector a and a secondary vector b The u axis should be parallel to a; the u v plane should contain b u = u / u w = u x b; w = w / w v = w x u Given just a vector a The u axis should be parallel to a; don t care about orientation about that axis Same process but choose arbitrary b first Good choice is not near a: e.g. set smallest entry to 1 19

Building general rotations Alternative: construct frame and change coordinates choose p, u, v, w to be orthonormal frame with p and u matching the rotation axis apply similarity transform T = F R x (θ ) F 1 interpretation: move to x axis, rotate, move back interpretation: rewrite u-axis rotation in new coordinates (each is equally valid) (note above is linear transform; add affine coordinate) 20

Building general rotations Alternative: construct frame and change coordinates choose p, u, v, w to be orthonormal frame with p and u matching the rotation axis apply similarity transform T = F R x (θ ) F 1 interpretation: move to x axis, rotate, move back interpretation: rewrite u-axis rotation in new coordinates (each is equally valid) Sleeker alternative: Rodrigues formula 21

Specifying Rotations Many ways to specify rotation Indirectly through frame transformations Directly through Euler angles: 3 angles about 3 axes (Axis, angle) rotation: based on Euler s theorem Quaternions 22

Derivation of General Rotation Matrix Axis angle rotation 23

Axis-angle ONB 24

Axis-angle rotation 25

26

Rotation Matrix for Axis-Angle 27

Transforming normal vectors Transforming surface normals differences of points (and therefore tangents) transform OK normals do not --> use inverse transpose matrix 28

Transforming normal vectors Transforming surface normals differences of points (and therefore tangents) transform OK normals do not --> use inverse transpose matrix 28

Building transforms from points 2D affine transformation has 6 degrees of freedom (DOFs) this is the number of knobs we have to set to define one So, 6 constraints suffice to define the transformation handy kind of constraint: point p maps to point q (2 constraints at once) three point constraints add up to constrain all 6 DOFs (i.e. can map any triangle to any other triangle) 3D affine transformation has 12 degrees of freedom count them from the matrix entries we re allowed to change So, 12 constraints suffice to define the transformation in 3D, this is 4 point constraints (i.e. can map any tetrahedron to any other tetrahedron) 29