40/45

Affine Transforms and 4D

Preliminary note

  • - We use a lot affine transformations to place shapes in 3D space

    • Translation, Rotation, Scaling

  • - In CG vectors are often 4D, and matrices are \(4\times 4\).

⇒ Reason: Affine transforms can be expressed linearly (with matrices) in 4D

\[ p= \left( \begin{array}{r} x \\ y \\ z \\ 1 \end{array} \right) \;\;\;\;\;\;\; \mathrm{M}= \left( \begin{array}{rrr} m_{00} & m_{01} & m_{02} & t_x \\ m_{10} & m_{11} & m_{12} & t_y \\ m_{20} & m_{21} & m_{22} & t_z \\ 0 & 0 & 0 & 1 \end{array} \right) \]