linearly v0.32.0 • Docs
linearly v0.32.0 / quat / axisAngle
Function: axisAngle()
axisAngle(
q
):object
Gets the rotation axis and angle for a given quaternion. If a quaternion is created with fromAxisAngle, this method will return the same values as providied in the original parameter list OR functionally equivalent values. Example: The quaternion formed by axis [0, 0, 1] and angle -90 is the same as the quaternion formed by [0, 0, 1] and 270. This method favors the latter.
Parameters
• q: quat
Quaternion to be decomposed
Returns
object
axis
axis:
vec3
deg
deg:
number