All the routines in this section construct a 4 by 4 homogeneous transformation matrix representing the required transform. These matrices may be concatenated to achieve more complex transforms using the matrix multiplication operator *. For example, the expression
m = trans( vector( -1, 0, 0 ) ) * rotx( 45 ) * trans( vector( 1, 0, 0 ) );
constructs a transform to rotate an object around the X = 1 line, 45 degrees.
A matrix representing the inverse transformation can be computed as:
InvM = m ^ -1
See also overloading of the - operator.