Documentation / @ripl/3d / mat4Compose
Function: mat4Compose() ​
mat4Compose(
translation,rotation,scale):Matrix4
Defined in: 3d/src/math/matrix.ts:342
Composes a transform from translation, per-axis rotation and scale, applied in that order.
Matches the order Shape3D builds its model matrix in, so a composed matrix and an element's own transform agree.
Parameters ​
| Parameter | Type | Description |
|---|---|---|
translation | Vector3 | Translation applied last. |
rotation | Vector3 | Rotation around the X, Y and Z axes, in radians. |
scale | Vector3 | Per-axis scale applied first. |
Returns ​
The composed matrix.