Skip to content

eulerToRotationMatrix

eulerToRotationMatrix(yaw, pitch, roll?): [Vec3, Vec3, Vec3]

Defined in: src/components/editor/ViewportGizmo/gizmoMath.ts:33

Build a 3×3 rotation matrix from Euler angles (YXZ intrinsic order). Matches Three.js default Euler order.

Parameters

yaw

number

Y-axis rotation in degrees

pitch

number

X-axis rotation in degrees

roll?

number = 0

Z-axis rotation in degrees

Returns

[Vec3, Vec3, Vec3]

[right, up, forward] basis vectors (columns of rotation matrix)