Download presentation
Presentation is loading. Please wait.
Published byThomas Burns Modified over 9 years ago
1
Computer Animation Rick Parent Computer Animation Algorithms and Techniques Technical Background
2
Computer Animation Rick Parent Spaces and Transformations Left-handed v. right handed Homogeneous coordinates: 4x4 transformation matrix (TM) Concatenating TMs Basic transformations (TMs) Display pipeline
3
Computer Animation Rick Parent Display Pipeline Object Space Data World Space Data Eye Space Data Image Space Data Display Space Data Object space to world space (TM) World space to eye space (TM) Perspective (TM) Clipping Perspective Divide Image space to display space (TM)
4
Computer Animation Rick Parent Representing an orientation Example: fixed angles - rotate around global axes X Y Z Orientation:
5
Computer Animation Rick Parent Working with fixed angles and Rotation Matrices (RMs) Extracing fixed angles from an orientation Extracing fixed angles from a RM Making a RM from fixed angles Orthonormalizing a RM Making a RM from transformed unit coordinate system (TUCS) X Y Z X Y Z
6
Computer Animation Rick Parent Transformations in pipeline object -> world: often rigid transforms world -> eye: rigid transforms perspective matrix: uses 4 th component of homo. coords perspective divide image -> screen: 2D map to screen coordinates Clipping: procedure that considers view frustum
7
Computer Animation Rick Parent Error considerations Accumulated round-off error - transform data: transform world data by delta RM update RM by delta RM; apply to object data update angle; form RM; apply to object data orthonormalization rotation matrix: orthogonal, unit-length columns iterate update by taking cross product of 2 vectors scale to unit length considerations of scale miles-to-inches can exeed single precision arithmetic
8
Computer Animation Rick Parent Orientation Representation Rotation matrix Fixed angles: rotate about global coordinate system Euler angles: rotate about local coordinate system Axis-angle: arbitrary axis and angle Quaternions: mathematically handy axis-angle 4-tuple Exponential map: 3-tuple version of quaternions
9
Computer Animation Rick Parent Transformation Matrix
10
Computer Animation Rick Parent Transformation Matrix
11
Computer Animation Rick Parent Rotation Matrices
12
Computer Animation Rick Parent Fixed Angles Fixed order: e.g., x, y, z; also could be x, y, x Global axes X Y Z
13
Computer Animation Rick Parent Gimbal Lock X Y Z Fixed angle: e.g., x, y, z X Y Z
14
Computer Animation Rick Parent Gimbal Lock Fixed order of rotations: x, y, z X Y Z What do these epsilon rotations do?
15
Computer Animation Rick Parent Gimbal Lock X Y Z X Y Z Interpolating FA representations does not produce intuitive rotation because of gimbal lock
16
Computer Animation Rick Parent Euler Angles Prescribed order: e.g., x, y, z or x, y, x Rotate around (rotated) local axes X Y Z Note: fixed angles are same as Euler angles in reverse order and vice versa
17
Computer Animation Rick Parent Axis-Angle Rotate about given axis Euler’s Rotation Theorem OpenGL Fairly easy to interpolate between orientations Difficult to concatenate rotations X Y Z A Q
18
Computer Animation Rick Parent Axis-angle to rotation matrix X Y Z A Q Concantenate the following: Rotate A around z to x-z plane Rotate A’ around y to x-axis Rotate theta around x Undo rotation around y-axis Undo rotation around z-axis
19
Computer Animation Rick Parent Axis-angle to rotation matrix X Y Z A Q P P’
20
Computer Animation Rick Parent Quaternion Same as axis-angle, but different form Still rotate about given axis Mathematically convenient form X Y Z Note: in this form v is a scaled version of the given axis of rotation, A A Q
21
Computer Animation Rick Parent Quaternion Arithmetic Addition Multiplication Length Inner Product
22
Computer Animation Rick Parent Quaternion Arithmetic Inverse Unit quaternion
23
Computer Animation Rick Parent Quaternion Represention Vector Transform
24
Computer Animation Rick Parent Quaternion Geometric Operations
25
Computer Animation Rick Parent Unit Quaternion Conversions Axis-Angle
26
Computer Animation Rick Parent Quaternions Avoid gimbal lock Easy to rotate a point Easy to convert to a rotation matrix Easy to concatenate – quaternion multiply Easy to interpolate – interpolate 4-tuples How about smoothly (in both space and time) interpolate?
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.