Matrix4x4 (Type m00, Type m01, Type m02, Type m03, Type m10, Type m11, Type m12, Type m13, Type m20, Type m21, Type m22, Type m23, Type m30, Type m31, Type m32, Type m33)
template<typename U , STK::enable_if_safe_cast_t< U, Type > = true>
Euler transform. This transform constructs a matrix to orient an object in a certain direction. This matrix consists of three rotations about the three coordinate axis. The transformation is given by the following equation
where denotes a rotation matrix and (roll, pitch, heading), are the amounts of rotation about their respective axis given in degrees.
Warning
Note that certain combinations of rotations may lead to a "gimbal lock" (loss of one degree of freedom). To avoid this, use quaternions instead.
Create a camera matrix. This method creates a transformation matrix which transforms objects relative to a camera direction (pos), a camera direction (ctr) and an up vector (up).
Rotate a degrees about the x-axis. A positive angle causes a clockwise rotation about the axis (seen from the origin), and a negative angle causes a counter- clockwise rotation.
Rotate a degrees about the y-axis. A positive angle causes a clockwise rotation about the axis (seen from the origin), and a negative angle causes a counter- clockwise rotation.
Rotate a degrees about the z-axis. A positive angle causes a clockwise rotation about the axis (seen from the origin), and a negative angle causes a counter- clockwise rotation.
Transpose the rotation matrix, invert the translation vector. To use this function you have to be very sure that the transform only contains translation and rotation parts.