Quaternion Class
Methods
-
a -
b
Calculates the dot product of two quat's
Parameters:
-
aQuatthe first operand
-
bQuatthe second operand
Returns:
dot product of a and b
-
a
Creates a new quat initialized with values from an existing quaternion
Parameters:
-
aQuatquaternion to clone
Returns:
a new quaternion
-
out -
a
Copy the values from one quat to another
Parameters:
-
outQuatthe receiving quaternion
-
aQuatthe source quaternion
Returns:
out
-
out -
x -
y -
z -
w
Set the components of a quat to the given values
Parameters:
Returns:
out
-
out -
a -
b
Adds two quat's
Parameters:
-
outQuatthe receiving quaternion
-
aQuatthe first operand
-
bQuatthe second operand
Returns:
out
Alias for {@link quat.multiply}
-
out -
a -
b
Scales a quat by a scalar number
Parameters:
-
outQuatthe receiving vector
-
aQuatthe vector to scale
-
bNumberamount to scale the vector by
Returns:
out
-
x -
y -
z -
w
Creates a new quat initialized with the given values
Returns:
a new quaternion
-
out -
a -
b -
t
Performs a linear interpolation between two quat's
Parameters:
-
outQuatthe receiving quaternion
-
aQuatthe first operand
-
bQuatthe second operand
-
tNumberinterpolation amount between the two inputs
Returns:
out
-
a
Calculates the length of a quat
Parameters:
-
aQuatvector to calculate length of
Returns:
length of a
Alias for {@link quat.length}
-
a
Calculates the squared length of a quat
Parameters:
-
aQuatvector to calculate squared length of
Returns:
squared length of a
Alias for {@link quat.squaredLength}
-
out -
a
Normalize a quat
Parameters:
-
outQuatthe receiving quaternion
-
aQuatquaternion to normalize
Returns:
out
-
out -
m
Creates a quaternion from the given 3x3 rotation matrix.
NOTE: The resultant quaternion is not normalized, so you should be sure to renormalize the quaternion yourself where necessary.
Parameters:
-
outQuatthe receiving quaternion
-
mMat3rotation matrix
Returns:
out
