COMP30019 Graphics and Interaction Transformation geometry and - - PowerPoint PPT Presentation

comp30019 graphics and interaction transformation
SMART_READER_LITE
LIVE PREVIEW

COMP30019 Graphics and Interaction Transformation geometry and - - PowerPoint PPT Presentation

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations COMP30019 Graphics and Interaction Transformation geometry and homogeneous coordinates Adrian Pearce Department of Computing and


slide-1
SLIDE 1

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

COMP30019 Graphics and Interaction Transformation geometry and homogeneous coordinates

Adrian Pearce

Department of Computing and Information Systems University of Melbourne

The University of Melbourne

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-2
SLIDE 2

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Lecture outline

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-3
SLIDE 3

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Transformation geometry

How are geometric transformations represented conveniently and efficiently? Aim: understand two-dimensional (2D) transformations Reading:

◮ Akenine-Möller Section 4.1 Basic Transforms Section 4.2

Special Matrix Transforms and Operations

◮ Foley Sections 5.3 Homogeneous coordinates and matrix

representation of 2D transformations, 5.4 Composition of 2D transformations and 5.6 Efficiency.

◮ Angel Sections 3.2 Three-Dimensional Primatives; 3.3

Coordinate Systems and Frames; 3.7 Affine Transformations; 3.8 Translation, Rotation, and Scaling; 3.9 Trnasofmations in Homogenoeous Coordinates and 3.10 Concatenation of Transformations

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-4
SLIDE 4

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Review of two-dimensional (2D) geometry

Points are represented either in absolute position, relative to

  • rigin in Cartesian coordinates: (x, y) ∈ R2 or polar

coordinates: (ρ, θ). Vectors represent relative displacement, v = vx vy

  • and are

subject to vector addition, subtraction, scalar product (dot product) or norm (magnitude) operations.

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-5
SLIDE 5

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Curves can be modelled in either explicit functional form: y = F(x) or implicit equational form: G(x, y) = 0 or parametric form: x = x(t) y = y(t) e.g. some straight lines are:

◮ y = mx + b (explicit functional form) ◮ ax + by + c = 0 (implicit equational form) ◮ x cos θ + y sin θ = ρ (implicit equational form) ◮ x = x0 + x1p(t), y = y0 + y1p(t) (parametric form)

Special forms include a line through two points or line segments such as endpoints or parameter bounds.

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-6
SLIDE 6

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Geometric transformations

General geometric transformations concern object points rather than transformation of the entire coordinate frame, x′ = g(x, y), y′ = h(x, y). More specific geometric transformations involve

◮ translations, where x′ = x + xt, and y′ = y + yt and ◮ linear transformations v′ = Mv (where v′ is a vector and M

is a matrix) such as scaling, shear, rotation, reflection.

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-7
SLIDE 7

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Vector and matrix conventions

There are two conventions for vectors and matrices where vectors are written as columns: v = x y

  • Matrices multiply on the left:

Mv = a b c d x y

  • =

ax + by cx + dy

  • Adrian Pearce

University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-8
SLIDE 8

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

However, watch out for other forms where vectors are written as rows: v =

  • x

y

  • =

x y T Matrices multiply on the right: vM =

  • x

y a b c d

  • =

ax + cy bx + dy

  • Really, you should understand the concepts, and be able to

work with either notation.

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-9
SLIDE 9

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Translation

Translation is also known as shifting or displacement, where x′ = x + xt and y′ = y + yt. Translation in two-dimensional vector notation (by addition): x′ y′

  • =

x y

  • +

xt yt

  • Adrian Pearce

University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-10
SLIDE 10

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Rotation

Rotation of an object about the origin

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-11
SLIDE 11

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Rotation as a matrix operation (by multiplication): cos θ − sin θ sin θ cos θ x y

  • =

x cos θ − y sin θ x sin θ + y cos θ

  • Convenient, as can combine a number of geometric rotations

by multiplication, x′ y′

  • =

cos θ − sin θ sin θ cos θ x y

  • Unfortunately translation is different to rotation, therefore can’t

treat as multiplication (also true for scaling). This means translations and rotations cannot be combined easily.

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-12
SLIDE 12

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

How are rotation matrices derived?

Increasing x Increasing y x y x y , , ,

( )

¢ ¢

( ) ( )

  q f

Hint: Consider the point above with polar coordinates (ρ, θ) (Rowe Fig 2.1). If rotated by angle φ around the origin, its polar coordinates are (ρ, θ + φ), converting to Cartesian coordinates gives, ρ cos(θ + φ) ρ sin(θ + φ)

  • Adrian Pearce

University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-13
SLIDE 13

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

We can expand and re-arrange this in terms of the cosine and sine angle-addition formulas, and the Cartesian coordinates

  • f the original point

x = ρ cos φ y = ρ sin φ to obtain a matrix expression for a rotation by angle θ. x′ = ρ cos(φ + θ) = ρ cos φ cos θ − ρ sin φ sin θ y′ = ρ sin(φ + θ) = ρ cos φ sin θ + ρ sin φ cos θ x′ = ρ cos(φ + θ) =ρ cos φcos θ−ρ sin φsin θ y′ = ρ sin(φ + θ) =ρ cos φsin θ+ρ sin φcos θ x′ = xcos θ−ysin θ y′ = xsin θ+ycos θ

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-14
SLIDE 14

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Rigid body transformations

Rotation, translation, and reflection preserve distances (rigid motions). That is, if two points are a certain distance apart, they will still be the same distance apart after undergoing one of these transformations (or indeed any combination of them). Mathematically, they are the only transformations with this property of preserving distance.

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-15
SLIDE 15

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Reflection

Reflection in a line—gives mirror image Move point to position at equal distance on opposite side of the line. Reflection in the x-axis: x′ = x y′ = −y Reflection in the y-axis: x′ = −x y′ = y

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-16
SLIDE 16

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-17
SLIDE 17

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Reflection in the line y = x: x′ = y y′ = x All these can be expressed as matrix operations (details left to you). Reflections in an arbitrary line can be achieved by transforming line (by rotation and translation) to one of the coordinate axes, reflecting in that axis, and transforming back.

◮ Reflection reverses handedness—an object goes to its

mirror image.

◮ Rotation and translation preserve handedness—they

correspond to motions of rigid (solid) objects.

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-18
SLIDE 18

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Combination of transformations?

Unfortunately, translation is treated differently (via addition) from scaling and rotation (via multiplication). We would like to be able to treat all three transformations in a consistent way, so that they can be combine easily i.e. using the same GPU unit to simplify the pipeline

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-19
SLIDE 19

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Homogeneous coordinates

Homogeneous coordinates introduces a third dummy coordinate w, represented as (x, y, w). You imagine a third dimension z or (x/z, y/z), where a ray from the origin to point (x, y, z) in three-dimensions pierces the plane at z = 1.

◮ This paradoxically suggests that there is some ideal point

(x, y, 0).

◮ More importantly it allows for many different homogeneous

coordinate representations of the same point, e.g. (2, 3, 6) is the same as (4, 6, 12), etc.

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-20
SLIDE 20

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

In homogeneous coordinates this third dimension is often named w or (wx, wy, w) where w = 0. You homogenise by dividing by w to get (x, y, 1) (Foley Figure 5.07).

W X Y P W = 1 plane

This imaginary dimension can also be considered as (x/z, y/z) where a ray from the origin to point (x, y, z) in three-dimensions pierces the plane at z = 1.

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-21
SLIDE 21

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

In Figure 5.7 (Foley, page 171):

◮ Each point subsequently has many different homogeneous

coordinate representations, e.g. (2, 3, 6) is the same as (4, 6, 12), etc.

◮ Homogenise by dividing by w to get (x, y, 1).

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-22
SLIDE 22

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Translation in homogeneous coordinates:   1 xt 1 yt 1     wx wy w   =   w(x + xt) w(y + yt) w   The additional (redundant) dimension w allows translation to become linear and allows the translation to be written as a matrix product rather than a sum. Translation in homogeneous coordinates (with w = 1):   x′ y′ 1   =   1 xt 1 yt 1     x y 1   =   x + xt y + yt 1  

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-23
SLIDE 23

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Rotation in homogeneous coordinates

R =   cos θ − sin θ sin θ cos θ 1   inverse rotation, R-1 = RT, R =   cos θ sin θ − sin θ cos θ 1   How does one rotate about an arbitrary point?

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-24
SLIDE 24

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

In general, with these transforms (except translation of course), we get the 3-by-3 homogeneous version by putting the 2-by-2 matrix down in the upper-left 2-by-2 block of what is otherwise a 3-by-3 identity matrix.

◮ Inverse rotation is rotation by negative angle −θ. Since

cos(−θ) = cos(θ) and sin(−θ) = − sin(θ), the structure of the rotation matrix means that its inverse is its transpose. (Actually, this is a property common to all orthogonal matrices, of which rotation is a special case.)

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-25
SLIDE 25

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Non-rigid body transformations

Scaling is also known as dilatation, magnification or shrinking, where x′ = xsx and y′ = ysy. Scaling is an affine transformation (affine transformations preserve collinearity of lines, or curvature).

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-26
SLIDE 26

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Affine transformations

An affine transformation preserves

◮ collinearity between points (ie. three points which lie on a

line continue to be collinear after the transformation), and

◮ ratios of distances between any two points.

Therefore translation, rotation, scaling and shear are all affine transformations.

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-27
SLIDE 27

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Scaling as a matrix operation: x′ y′

  • =

xs ys x y

  • Scaling in homogeneous coordinates:

  x′ y′ 1   =   xs ys 1     x y 1   =   xsx ysy 1   This shows how scaling can be achieved as a matrix operation.

◮ If xs = ys, get isotropic scaling. ◮ Scaling is inverted by using reciprocals of scale factors,

1/xs and 1/ys.

◮ Using scale factors of 1 gives an identity transformation.

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-28
SLIDE 28

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Shear

Horizontal shear: x′ = x + xhy y′ = y Everything keeps its vertical position, but is dragged sideways in proportion to its vertical position. A square is dragged out into a parallelogram with the same height.

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-29
SLIDE 29

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Horizontal shear in homogeneous coordinates:   x′ y′ 1   =   1 xh 1 1     x y 1   =   (x + xh ∗ y) (y) 1  

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-30
SLIDE 30

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Vertical shear: x′ = x y′ = y + yhx Everything keeps its horizontal position, but is dragged up or down in proportion to its horizontal position. A square is dragged out into a parallelogram with the same width.

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-31
SLIDE 31

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Vertical shear in homogeneous coordinates:   x′ y′ 1   =   1 yh 1 1     x y 1   =   (x) (yh ∗ x + y) 1   Shears are elementary transforms

◮ many useful transforms can be made by appropriate

combinations of shears

◮ this can have theoretical and computational benefits ◮ for example, totations can be decomposed into shears and

used for producing fast method of rotating, without need for using trogonometric function calls

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-32
SLIDE 32

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Combining transformation matrices

Any transformation (or combination of transformations) can be expressed in homogeneous coordinates by means of the matrix equation:   x′ y′ 1   =   m00 m01 m02 m10 m11 m12 1     x y 1  

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-33
SLIDE 33

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Affine transformations in 2D

Any affine transformation (or combination of transformations) can be expressed in homogeneous coordinates by means of the matrix equation:   x′ y′ 1   =   m00 m01 m02 m10 m11 m12 1     x y 1  

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-34
SLIDE 34

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

  1 xt 1 yt 1   (translation)

  xs ys 1   (scaling)

  cos θ − sin θ sin θ cos θ 1]   (clockwise rotation by theta)

  cos θ sin θ − sin θ cos θ 1   (anti-clockwise rotation by theta)

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-35
SLIDE 35

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Example: rotation around an arbitrary 2D point

y x After translation

  • f P1 to origin

P1 y x Original house q y x After rotation y x After translation to original P1 P1

(Foley Figure 5.10)

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-36
SLIDE 36

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Rotating a point (x, y) about an arbitrary fixed point (rather than the origin), to obtain a new point (xr, yr).

  xr yr 1   =   1 cx 1 cy 1     cos θ − sin θ sin θ cos θ 1     1 −cx 1 −cy 1     x y 1   =   cos θ − sin θ cx(1 − cos θ) + cy sin θ sin θ cos θ cy(1 − cos θ) − cx sin θ 1     x y 1  

Homogeneous coordinates simplify process of combining transformation, similarly for scaling an object about an arbitrary point.

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-37
SLIDE 37

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Example: rotation, scaling and translation

P1 Original house Translate P1 to origin Scale Rotate Translate to final position P2 P2

T(x2, y2) · R(θ) · S(sx, sy) · T(−x1, −y1) (Foley Figure 5.11)

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-38
SLIDE 38

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Commutivity of transformation matrices

If M1 and M2 each represent a fundamental translation, scaling

  • r rotation, when is M1 · M2 = M2 · M1?

In general, for two matrices matrix multiplication is not commutative, that is M1 · M2 = M2 · M1 However, commutivity holds in the following special cases when M1 M2 Translate Translate Scale Scale Rotate Rotate Scale (with sx = sy) Rotate When sx = sy, termed isotropic scaling.

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-39
SLIDE 39

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Example: drawing circles and ellipses

If a point is rotated incrementally by some (small) angle δ, then the trajectory it traces out is a circle. If we draw (short) line segments connecting successive points, this leads to an important fast method for drawing circles or parts of circles—circular arcs (if δ is small enough). More specifically, if x0 = x0 y0

  • is our starting point on the circle,

then we compute the sequence xk+1 = Rδxk where Rδ is a rotation (note this draws a circle centred on the

  • rigin).

How would the circle-drawing methods be adapted to draw ellipses with arbitrary centres?

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-40
SLIDE 40

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

That is, we want a matrix E such that the sequence of points generated by xk+1 = Exk lies along the ellipse. However, Rδ only steps us along successive points that lie on a circle, incremented by angle δ. What about an ellipse? Our method for drawing circles should be able to be adapted for drawing ellipses quickly, using a combination of matrix transformations. Note that an ellipse at arbitrary orientation can be created by stretching and rotating a unit circle. Initially, let’s consider only ellipses centred at the origin.

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-41
SLIDE 41

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

We can obtain an ellipse by stretching and rotating the points of a unit circle. This can be achieved by

  • 1. multiplying by a scaling matrix to achieve the ellipsoid

shape S = sx sy

  • (note different scaling in x and y directions for ellipse),

followed by

  • 2. multiplying by a rotation Rθ to orient the point along the

path of the ellipse. thus SRθ

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-42
SLIDE 42

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

If we have a point on an ellipse, we can move it back to the corresponding point on the unit circle, by multiplying it by the inverse of these transforms (SRθ)-1. Once we get it on the unit circle, we can step it to the next point by multiplying by Rδ. Then we can get that point back on the ellipse by multiplying by (SRθ). Thus E = (SRθ)-1Rδ (SRθ) = Rθ-1S-1RδSRθ = R(−θ)S-1RδSRθ

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-43
SLIDE 43

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

◮ Note that, in general, scaling and rotation don’t commute,

so there’s no obvious way to simplify this formula further.

◮ The main computational property of this method is that E

can be computed just once, so that each point generated along the ellipse requires just a matrix multiply.

◮ Note that although can calculate sin(δ) and cos(δ) will

need to calculate coefficients containing sin(θ) and cos(θ) at each step, since the transformation of a point at each step through different angles of the ellipse changes.

◮ A nice property is that the steps are smaller where the

curvature of the ellipse is higher (at the ends), and bigger where the curvature of the ellipse is lower (along the sides). The method adapts to distribute the number of points used along the ellipse to represent it most accurately when straight line segments are drawn between points.

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates

slide-44
SLIDE 44

Introduction Vectors and matrices Translation Rotation Homogeneous coordinates Affine transformations

Summary

◮ Geometric transformations can be conveniently encoded

as operations in matrix algebra.

◮ Rigid body transformations (rotation, translation and

reflection) preserve distances and correspond to rigid motion that is typically modelled in computer graphics.

◮ However, translations and rotations cannot be conveniently

combined using only multiplication.

◮ Representing geometric transformations as matrices in

homogeneous coordinates allows the combination of multiple transformations using matrix multiplication.

◮ Translation, rotation and reflection are affine transformation

(they preserve distances between points).

◮ Scaling and shear are not affine and do not preserve

distances, however rotations can be decomposed into shears with computational benefits.

Adrian Pearce University of Melbourne COMP30019 Graphics and InteractionTransformation geometry and homogeneous coordinates