Mat4:rotate
Rotates the matrix using a quaternion or an angle/axis rotation.
m = Mat4:rotate(q)
Arguments
Name | Type | Description |
q | Quat | The rotation to apply to the matrix.
|
Returns
Name | Type | Description |
m | Mat4 | The original matrix.
|
m = Mat4:rotate(angle, ax, ay, az)
Arguments
Name | Type | Default | Description |
angle | number | | The angle component of the angle/axis rotation (radians).
|
ax | number | 0 | The x component of the axis of rotation.
|
ay | number | 1 | The y component of the axis of rotation.
|
az | number | 0 | The z component of the axis of rotation.
|
Returns
Name | Type | Description |
m | Mat4 | The original matrix.
|
See also
mat4:translate
mat4:scale
mat4:identity
Mat4