Skip to content

format

typescript
Quaternion.Angle(lhs, rhs)

class: Quaternion

description

Returns the angle between two rotations, lhs and rhs.

parameter

param_nametypedescription
lhsQuaternionThe first rotation.
rhsQuaternionThe second rotation.

return

typedescription
numberThe angle between the two rotations.

code example

typescript
function QuaternionTest (){
    let identity = Quaternion.identity;
    let quat_axis = Quaternion.AngleAxis(60, new Vector3(0,1,0));
    let rotate_angle = Quaternion.Angle(identity, quat_axis);
}