Quaternion Class
Module: Math
Quaternion class
Constructor
Quaternion
()
Item Index
Methods
- add
- divide
- getMatrix Returns the quaternion matrix
- getQuaternionFromAxisAngle
- getQuaternionFromAxisAngle
- getQuaternionFromEulerAnglesRad
- getQuaternionFromEulerAnglesRad
- getQuaternionFromMatrix
- getQuaternionFromSpherical
- getRotationTo
- inverse Returns inverted quaternion
- magnitude Returns the length of quaternion
- magnitudeSquared Returns the squared length of quaternion
- multiply
- negative Returns negative quaternion
- rotateVector
- subtract
Methods
getQuaternionFromAxisAngle
(
Quaternion
-
v
Parameters:
-
v
VectorCreate quaternion from axis angle in degrees
Returns:
getQuaternionFromAxisAngle
(
Quaternion
-
v
Parameters:
-
v
VectorCreate quaternion from axis angle in radians
Returns:
getQuaternionFromEulerAnglesRad
(
Quaternion
-
x
-
y
-
z
Parameters:
-
x
Float -
y
Float -
z
FloatCreate quaternion from rotation XYZ in Degrees
Returns:
getQuaternionFromEulerAnglesRad
(
Quaternion
-
x
-
y
-
z
Parameters:
-
x
Float -
y
Float -
z
FloatCreate quaternion from rotation XYZ in Radians
Returns:
getQuaternionFromMatrix
(
Quaternion
-
m
Parameters:
-
m
MatrixCreate quaternion from Matrix
Returns:
getQuaternionFromSpherical
(
Quaternion
-
latitude
-
longtitude
-
angle
Parameters:
-
latitude
Float -
longtitude
Float -
angle
FloatCreate quaternion from spherical coordinates
Returns:
magnitude
Returns the length of quaternion
()
Float
Returns:
Float:
magnitudeSquared
Returns the squared length of quaternion
()
Float
Returns:
Float: