Matrix33
Overview
Matrix type representing a 3D rotation and/or scale operation, containing 3 rows and 3 columns.
Methods and Properties
rotationY
function Matrix33.rotationY(rotationAmount : Float) -> Matrix33
Constructs a 3x3 rotation matrix representing a rotation around the y-axis.
| Parameter |
Type |
Description |
| rotationAmount |
Float |
Amount to rotate the y-axis about, in radians. |
| Returns |
Description |
| Matrix33 |
The resulting rotation matrix. |
Example
local mat = Matrix33.rotationY(0.3)
fromQuaternion
function Matrix33.fromQuaternion(rotation : Quaternion) -> Matrix33
Constructs a 3x3 rotation matrix representing the provided quaternion.
| Parameter |
Type |
Description |
| rotation |
Quaternion |
Rotation to convert. |
| Returns |
Description |
| Matrix33 |
The provided rotation converted to a matrix. |
Example
local rotation = Quaternion.fromYawPitchRoll(0.3, 0.0, 2.0)
local mat = Matrix33.fromQuaternion(rotation)