mat4
module reference
mat4
module reference
Operators for generating 4x4 Matrices.
index
- The identity Matrix.
- Create a 3d rotation matrix from an axis and angle
- Create a 3d scale matrix.
- Create a 3d translation matrix.
- Create a 3d rotation matrix from euler angles.
details
- The identity Matrix.
- Create a 3d rotation matrix from an axis and angle
(mat4/translate axis angle)
This is a pure op.
axis
is a num[3] array representing a unit vector. - Create a 3d scale matrix.
(mat4/scale scale)
(mat4/scale x y z)
This is a pure op.
scale
can be a single number for uniform scaling, or an array of three numbers that will be used likex
,y
andz
. - Create a 3d translation matrix.
(mat4/translate vec)
(mat4/translate x y z)
This is a pure op.
vec
is a num[3] array. - Create a 3d rotation matrix from euler angles.
(yaw-pitch-roll vec3)
(yaw-pitch-roll y p r)
This is a pure op.