#include <UT_Quaternion.h>
Public Member Functions | |
| UT_QuaternionT (T qx=0, T qy=0, T qz=0, T qw=0) | |
| UT_QuaternionT (T angle, const UT_Vector3T< T > &axis, int donormalize=1) | |
| UT_QuaternionT (const UT_QuaternionT< T > &q) | |
| UT_QuaternionT (const UT_Vector3T< T > &rot, const UT_XformOrder &order) | |
| template<typename S > | |
| UT_QuaternionT (const UT_QuaternionT< S > &v) | |
| template<typename S > | |
| UT_QuaternionT< T > & | operator= (const UT_QuaternionT< S > &v) |
| UT_QuaternionT< T > & | operator*= (const UT_QuaternionT< T > &q) |
| UT_QuaternionT< T > & | operator*= (T scalar) |
| UT_QuaternionT< T > & | operator/= (const UT_QuaternionT< T > &quat) |
| UT_QuaternionT< T > & | operator/= (T scalar) |
| UT_QuaternionT< T > & | operator+= (const UT_QuaternionT< T > &quat) |
| bool | operator== (const UT_QuaternionT< T > &quat) const |
| bool | operator!= (const UT_QuaternionT< T > &quat) const |
| T | operator() (int idx) const |
| T & | operator() (int idx) |
| T | operator[] (int idx) const |
| T & | operator[] (int idx) |
| bool | isEqual (const UT_QuaternionT< T > &quat, T tol=FP32_TOLERANCE) const |
| void | getRotationMatrix (UT_Matrix3 &mat) const |
| void | getRotationMatrix (UT_DMatrix3 &mat) const |
| void | getTransformMatrix (UT_Matrix4 &mat) const |
| void | getTransformMatrix (UT_DMatrix4 &mat) const |
| UT_QuaternionT< T > | interpolate (const UT_QuaternionT< T > &target, T t, T b=0.0f) const |
| void | assign (T qx, T qy, T qz, T qw) |
| void | identity () |
| void | conjugate () |
| void | negate () |
| T | normal () const |
| void | normalize () |
| T | length () const |
| void | invert () |
| void | updateFromVectors (const UT_Vector3T< T > &v1, const UT_Vector3T< T > &v2) |
| void | updateFromRotationMatrix (const UT_Matrix3 &) |
| void | updateFromRotationMatrix (const UT_DMatrix3 &) |
| void | updateFromAngleAxis (T angle, const UT_Vector3T< T > &axis, int normalize=1) |
| void | getAngleAxis (T &angle, UT_Vector3T< T > &axis) const |
| void | updateFromLogMap (const UT_Vector3T< T > &v) |
| void | getLogMap (UT_Vector3T< T > &v) const |
| void | updateFromEuler (const UT_Vector3T< T > &rot, const UT_XformOrder &order) |
| void | computeDerivative (const UT_Vector3T< T > &omega, UT_QuaternionT< T > &q_prime) |
| UT_Vector3T< T > | computeAngVel (const UT_QuaternionT< T > &dest, T time) const |
| void | integrate (const UT_Vector3T< T > &angvel, T timestep, bool accurate=true) |
| UT_Vector3T< T > | computeRotations (const UT_XformOrder &) const |
| UT_Vector3T< T > | rotate (const UT_Vector3T< T > &) const |
| UT_Vector3T< T > | rotateInverse (const UT_Vector3T< T > &) const |
| void | multAngle (T s) |
| T & | x () |
| T & | y () |
| T & | z () |
| T & | w () |
| T | x () const |
| T | y () const |
| T | z () const |
| T | w () const |
| void | save (ostream &os, int binary=0) const |
| bool | load (UT_IStream &is) |
| const T * | data (void) const |
| T * | data (void) |
| unsigned | hash () const |
| Compute a hash. | |
| bool | save (UT_JSONWriter &w) const |
| bool | save (UT_JSONValue &v) const |
| bool | load (UT_JSONParser &p) |
Protected Member Functions | |
| void | initialize (T qx=0, T qy=0, T qz=0, T qw=0) |
Friends | |
| ostream & | operator<< (ostream &os, const UT_QuaternionT< T > &v) |
Definition at line 37 of file UT_Quaternion.h.
| UT_QuaternionT< T >::UT_QuaternionT | ( | T | qx = 0, |
|
| T | qy = 0, |
|||
| T | qz = 0, |
|||
| T | qw = 0 | |||
| ) | [inline] |
Definition at line 40 of file UT_Quaternion.h.
| UT_QuaternionT< T >::UT_QuaternionT | ( | T | angle, | |
| const UT_Vector3T< T > & | axis, | |||
| int | donormalize = 1 | |||
| ) |
| UT_QuaternionT< T >::UT_QuaternionT | ( | const UT_QuaternionT< T > & | q | ) | [inline] |
Definition at line 49 of file UT_Quaternion.h.
| UT_QuaternionT< T >::UT_QuaternionT | ( | const UT_Vector3T< T > & | rot, | |
| const UT_XformOrder & | order | |||
| ) | [inline] |
Definition at line 56 of file UT_Quaternion.h.
| UT_QuaternionT< T >::UT_QuaternionT | ( | const UT_QuaternionT< S > & | v | ) | [inline] |
| void UT_QuaternionT< T >::assign | ( | T | qx, | |
| T | qy, | |||
| T | qz, | |||
| T | qw | |||
| ) | [inline] |
Definition at line 101 of file UT_Quaternion.h.
| UT_Vector3T<T> UT_QuaternionT< T >::computeAngVel | ( | const UT_QuaternionT< T > & | dest, | |
| T | time | |||
| ) | const |
| void UT_QuaternionT< T >::computeDerivative | ( | const UT_Vector3T< T > & | omega, | |
| UT_QuaternionT< T > & | q_prime | |||
| ) |
| UT_Vector3T<T> UT_QuaternionT< T >::computeRotations | ( | const UT_XformOrder & | ) | const |
| void UT_QuaternionT< T >::conjugate | ( | ) | [inline] |
Definition at line 112 of file UT_Quaternion.h.
| T* UT_QuaternionT< T >::data | ( | void | ) | [inline] |
Definition at line 239 of file UT_Quaternion.h.
| const T* UT_QuaternionT< T >::data | ( | void | ) | const [inline] |
Definition at line 238 of file UT_Quaternion.h.
| void UT_QuaternionT< T >::getAngleAxis | ( | T & | angle, | |
| UT_Vector3T< T > & | axis | |||
| ) | const |
| void UT_QuaternionT< T >::getLogMap | ( | UT_Vector3T< T > & | v | ) | const |
| void UT_QuaternionT< T >::getRotationMatrix | ( | UT_DMatrix3 & | mat | ) | const |
| void UT_QuaternionT< T >::getRotationMatrix | ( | UT_Matrix3 & | mat | ) | const |
| void UT_QuaternionT< T >::getTransformMatrix | ( | UT_DMatrix4 & | mat | ) | const |
| void UT_QuaternionT< T >::getTransformMatrix | ( | UT_Matrix4 & | mat | ) | const |
| unsigned UT_QuaternionT< T >::hash | ( | ) | const [inline] |
| void UT_QuaternionT< T >::identity | ( | ) | [inline] |
Definition at line 107 of file UT_Quaternion.h.
| void UT_QuaternionT< T >::initialize | ( | T | qx = 0, |
|
| T | qy = 0, |
|||
| T | qz = 0, |
|||
| T | qw = 0 | |||
| ) | [inline, protected] |
Definition at line 245 of file UT_Quaternion.h.
| void UT_QuaternionT< T >::integrate | ( | const UT_Vector3T< T > & | angvel, | |
| T | timestep, | |||
| bool | accurate = true | |||
| ) |
| UT_QuaternionT<T> UT_QuaternionT< T >::interpolate | ( | const UT_QuaternionT< T > & | target, | |
| T | t, | |||
| T | b = 0.0f | |||
| ) | const |
| void UT_QuaternionT< T >::invert | ( | void | ) | [inline] |
Definition at line 145 of file UT_Quaternion.h.
| bool UT_QuaternionT< T >::isEqual | ( | const UT_QuaternionT< T > & | quat, | |
| T | tol = FP32_TOLERANCE | |||
| ) | const |
| T UT_QuaternionT< T >::length | ( | ) | const [inline] |
Definition at line 141 of file UT_Quaternion.h.
| bool UT_QuaternionT< T >::load | ( | UT_JSONParser & | p | ) |
Methods to serialize to a JSON stream. The vector is stored as an array of 4 reals.
| bool UT_QuaternionT< T >::load | ( | UT_IStream & | is | ) |
| void UT_QuaternionT< T >::multAngle | ( | T | s | ) |
| void UT_QuaternionT< T >::negate | ( | void | ) | [inline] |
Definition at line 118 of file UT_Quaternion.h.
| T UT_QuaternionT< T >::normal | ( | void | ) | const [inline] |
Definition at line 125 of file UT_Quaternion.h.
| void UT_QuaternionT< T >::normalize | ( | ) | [inline] |
Definition at line 132 of file UT_Quaternion.h.
| bool UT_QuaternionT< T >::operator!= | ( | const UT_QuaternionT< T > & | quat | ) | const |
| T& UT_QuaternionT< T >::operator() | ( | int | idx | ) | [inline] |
Definition at line 79 of file UT_Quaternion.h.
| T UT_QuaternionT< T >::operator() | ( | int | idx | ) | const [inline] |
Definition at line 77 of file UT_Quaternion.h.
| UT_QuaternionT<T>& UT_QuaternionT< T >::operator*= | ( | T | scalar | ) |
| UT_QuaternionT<T>& UT_QuaternionT< T >::operator*= | ( | const UT_QuaternionT< T > & | q | ) |
| UT_QuaternionT<T>& UT_QuaternionT< T >::operator+= | ( | const UT_QuaternionT< T > & | quat | ) |
| UT_QuaternionT<T>& UT_QuaternionT< T >::operator/= | ( | T | scalar | ) |
| UT_QuaternionT<T>& UT_QuaternionT< T >::operator/= | ( | const UT_QuaternionT< T > & | quat | ) |
| UT_QuaternionT<T>& UT_QuaternionT< T >::operator= | ( | const UT_QuaternionT< S > & | v | ) | [inline] |
Definition at line 67 of file UT_Quaternion.h.
| bool UT_QuaternionT< T >::operator== | ( | const UT_QuaternionT< T > & | quat | ) | const |
| T& UT_QuaternionT< T >::operator[] | ( | int | idx | ) | [inline] |
Definition at line 83 of file UT_Quaternion.h.
| T UT_QuaternionT< T >::operator[] | ( | int | idx | ) | const [inline] |
Definition at line 81 of file UT_Quaternion.h.
| UT_Vector3T<T> UT_QuaternionT< T >::rotate | ( | const UT_Vector3T< T > & | ) | const |
Rotates a vector by this quaternion Requires that this is normalized.
| UT_Vector3T<T> UT_QuaternionT< T >::rotateInverse | ( | const UT_Vector3T< T > & | ) | const |
rotates a vector by the inverse of this quaternion. Requires that this is normalized.
| bool UT_QuaternionT< T >::save | ( | UT_JSONValue & | v | ) | const |
Methods to serialize to a JSON stream. The vector is stored as an array of 4 reals.
| bool UT_QuaternionT< T >::save | ( | UT_JSONWriter & | w | ) | const |
Methods to serialize to a JSON stream. The vector is stored as an array of 4 reals.
| void UT_QuaternionT< T >::save | ( | ostream & | os, | |
| int | binary = 0 | |||
| ) | const |
| void UT_QuaternionT< T >::updateFromAngleAxis | ( | T | angle, | |
| const UT_Vector3T< T > & | axis, | |||
| int | normalize = 1 | |||
| ) |
| void UT_QuaternionT< T >::updateFromEuler | ( | const UT_Vector3T< T > & | rot, | |
| const UT_XformOrder & | order | |||
| ) |
| void UT_QuaternionT< T >::updateFromLogMap | ( | const UT_Vector3T< T > & | v | ) |
| void UT_QuaternionT< T >::updateFromRotationMatrix | ( | const UT_DMatrix3 & | ) |
| void UT_QuaternionT< T >::updateFromRotationMatrix | ( | const UT_Matrix3 & | ) |
| void UT_QuaternionT< T >::updateFromVectors | ( | const UT_Vector3T< T > & | v1, | |
| const UT_Vector3T< T > & | v2 | |||
| ) |
| T UT_QuaternionT< T >::w | ( | ) | const [inline] |
Definition at line 225 of file UT_Quaternion.h.
| T& UT_QuaternionT< T >::w | ( | ) | [inline] |
Definition at line 220 of file UT_Quaternion.h.
| T UT_QuaternionT< T >::x | ( | ) | const [inline] |
Definition at line 222 of file UT_Quaternion.h.
| T& UT_QuaternionT< T >::x | ( | ) | [inline] |
Definition at line 217 of file UT_Quaternion.h.
| T UT_QuaternionT< T >::y | ( | ) | const [inline] |
Definition at line 223 of file UT_Quaternion.h.
| T& UT_QuaternionT< T >::y | ( | ) | [inline] |
Definition at line 218 of file UT_Quaternion.h.
| T UT_QuaternionT< T >::z | ( | ) | const [inline] |
Definition at line 224 of file UT_Quaternion.h.
| T& UT_QuaternionT< T >::z | ( | ) | [inline] |
Definition at line 219 of file UT_Quaternion.h.
| ostream& operator<< | ( | ostream & | os, | |
| const UT_QuaternionT< T > & | v | |||
| ) | [friend] |
Definition at line 253 of file UT_Quaternion.h.
1.5.9