- with 3 axes, z points towards us
- Translation:
→ add a vector to a point
- Scaling
→ expand or contract along each axis
→ can be expressed in matrix form
→ P' = [[sx,0,0][0,sy,0][0,0,sz]][Px,Py,Px]
→ variation of the identity matrix
- Rotation
→ now we have 3 axes and can rotate around any of them
→ rotation about z axis in 3d leaves all points with the same z
→ equivalent to rotation in 2D in planes of constant z
⇒ x' = xcostheta - ysintheta
⇒ y' = xsintheta + ycostheta
⇒ z' = z
→ rotation matrix around the x axis:
⇒ R = Rx(theta) = [[100][
→ around y axes:
⇒ Ry(theta) = [[cos,0,sin][0,1,0][-sin,0,cos]]
- Inverse operations are basically the same as in 2D
→ translation:
⇒ T(-vx,-vy,-vz)
→ Rotation

→ scaling
⇒ S(1/sx,1/sy,1/sz)

- we want all of our transformations to be matrix multiplication, for speed and simplicity of hardware
- augment our points and vectors
→ vector = 0, point = 1
→ [vx,vy,vz,0] , [Px,Py,Pz,1]
→ P' = [[1,0,0,vx][0,1,0,vy][0,0,1,vz][0,0,0,1]] [px,py,pz,1]
→ Adjust scaling matrix:
⇒ [[sx 0 0 0][0 sy 0 0][0 0 sz 0][0 0 0 1]] [px py pz 1]
→ adjust roation matrix:
⇒ [[cos -sin 0 0][sin cos 0 0][0 0 1 0][0 0 0 1]] [px pyp pz 1] (z)


Concatenate multiple transformations togther:
Break up the operation:
- move object to origin
- rotate
- move object back to its original position
- M = T^-1(R(T P))

Homework
- construct the homogenous matrices needed to rotate a 3d point around a pivot point (3, 4 ,5)
→ try the rotation 45 degrees z
→ -90 degrees around x

Index