|
Gateware Libraries
6.3.A
Beta Build
|
Quaternion functions. More...
#include <GQuaternion.h>
Public Member Functions | |
| virtual GReturn | AddQuaternionF (GQUATERNIONF _quaternion1, GQUATERNIONF _quaternion2, GQUATERNIONF &_outQuaternion)=0 |
| Add two quaternions. More... | |
| virtual GReturn | SubtractQuaternionF (GQUATERNIONF _quaternion1, GQUATERNIONF _quaternion2, GQUATERNIONF &_outQuaternion)=0 |
| Subtract two quaternions. More... | |
| virtual GReturn | MultiplyQuaternionF (GQUATERNIONF _quaternion1, GQUATERNIONF _quaternion2, GQUATERNIONF &_outQuaternion)=0 |
| Multiply two quaternions. More... | |
| virtual GReturn | ScaleF (GQUATERNIONF _quaternion, float _scalar, GQUATERNIONF &_outQuaternion)=0 |
| Scale the quaternion. More... | |
| virtual GReturn | SetByVectorAngleF (GVECTORF _vector, float _radian, GQUATERNIONF &_outQuaternion)=0 |
| Set the quaternion by the specified vector and the specified angle. More... | |
| virtual GReturn | SetByMatrixF (GMATRIXF _matrix, GQUATERNIONF &_outQuaternion)=0 |
| Set the quaternion by the specified matrix. More... | |
| virtual GReturn | DotF (GQUATERNIONF _quaternion1, GQUATERNIONF _quaternion2, float &_outValue)=0 |
| Calculates the dot product of the two specified quaternions. More... | |
| virtual GReturn | CrossF (GQUATERNIONF _quaternion1, GQUATERNIONF _quaternion2, GVECTORF &_outVector)=0 |
| Calculates the cross product of the two specified quaternions. More... | |
| virtual GReturn | ConjugateF (GQUATERNIONF _quaternion, GQUATERNIONF &_outQuaternion)=0 |
| Conjugate the specified quaternion. More... | |
| virtual GReturn | InverseF (GQUATERNIONF _quaternion, GQUATERNIONF &_outQuaternion)=0 |
| Inverse the specified quaternion. More... | |
| virtual GReturn | MagnitudeF (GQUATERNIONF _quaternion, float &_outMagnitude)=0 |
| Calculate the magnitude of quaternion. More... | |
| virtual GReturn | NormalizeF (GQUATERNIONF _quaternion, GQUATERNIONF &_outQuaternion)=0 |
| Normalize the specified quaternion. More... | |
| virtual GReturn | IdentityF (GQUATERNIONF &_outQuaternion)=0 |
| Identity the specified quaternion. More... | |
| virtual GReturn | LerpF (GQUATERNIONF _quaternion1, GQUATERNIONF _quaternion2, float _ratio, GQUATERNIONF &_outQuaternion)=0 |
| Linear interpolate between two specified quaternions. More... | |
| virtual GReturn | SlerpF (GQUATERNIONF _quaternion1, GQUATERNIONF _quaternion2, float _ratio, GQUATERNIONF &_outQuaternion)=0 |
| Spherical linear interpolates between two specified quaternions. More... | |
| virtual GReturn | AddQuaternionD (GQUATERNIOND _quaternion1, GQUATERNIOND _quaternion2, GQUATERNIOND &_outQuaternion)=0 |
| Add two quaternions. More... | |
| virtual GReturn | SubtractQuaternionD (GQUATERNIOND _quaternion1, GQUATERNIOND _quaternion2, GQUATERNIOND &_outQuaternion)=0 |
| Subtract two quaternions. More... | |
| virtual GReturn | MultiplyQuaternionD (GQUATERNIOND _quaternion1, GQUATERNIOND _quaternion2, GQUATERNIOND &_outQuaternion)=0 |
| Multiply two quaternions. More... | |
| virtual GReturn | ScaleD (GQUATERNIOND _quaternion, double _scalar, GQUATERNIOND &_outQuaternion)=0 |
| Scale the quaternion. More... | |
| virtual GReturn | SetByVectorAngleD (GVECTORD _vector, double _radain, GQUATERNIOND &_outQuaternion)=0 |
| Set the quaternion by the specified vector and the specified angle. More... | |
| virtual GReturn | SetByMatrixD (GMATRIXD _matrix, GQUATERNIOND &_outQuaternion)=0 |
| Set the quaternion by the specified matrix. More... | |
| virtual GReturn | DotD (GQUATERNIOND _quaternion1, GQUATERNIOND _quaternion2, double &_outQuaternion)=0 |
| Calculates the dot product of the two specified quaternions. More... | |
| virtual GReturn | CrossD (GQUATERNIOND _quaternion1, GQUATERNIOND _quaternion2, GVECTORD &_outVector)=0 |
| Calculates the cross product of the two specified quaternions. More... | |
| virtual GReturn | ConjugateD (GQUATERNIOND _quaternion, GQUATERNIOND &_outQuaternion)=0 |
| Conjugate the specified quaternion. More... | |
| virtual GReturn | InverseD (GQUATERNIOND _quaternion, GQUATERNIOND &_outQuaternion)=0 |
| Inverse the specified quaternion. More... | |
| virtual GReturn | MagnitudeD (GQUATERNIOND _quaternion, double &_outMagnitude)=0 |
| Calculate the magnitude of quaternion. More... | |
| virtual GReturn | NormalizeD (GQUATERNIOND _quaternion, GQUATERNIOND &_outQuaternion)=0 |
| Normalize the specified quaternion. More... | |
| virtual GReturn | IdentityD (GQUATERNIOND &_outQuaternion)=0 |
| Identity the specified quaternion. More... | |
| virtual GReturn | LerpD (GQUATERNIOND _quaternion1, GQUATERNIOND _quaternion2, float _ratio, GQUATERNIOND &_outQuaternion)=0 |
| Linear interpolate between two specified quaternions. More... | |
| virtual GReturn | SlerpD (GQUATERNIOND _quaternion1, GQUATERNIOND _quaternion2, double _ratio, GQUATERNIOND &_outQuaternion)=0 |
| Spherical linear interpolates between two specified quaternions. More... | |
Public Member Functions inherited from GW::CORE::GInterface | |
| virtual GReturn | GetCount (unsigned int &_outCount)=0 |
| Return the total number of active references to this object. More... | |
| virtual GReturn | IncrementCount ()=0 |
| Increase the total number of active references to this object. More... | |
| virtual GReturn | DecrementCount ()=0 |
| Decrease the total number of active references to this object. More... | |
| virtual GReturn | RequestInterface (const GUUIID &_interfaceID, void **_outputInterface)=0 |
| Requests an interface that may or may not be supported by this object. More... | |
Quaternion functions.
Include float vector and double quaternion's functions
|
pure virtual |
Add two quaternions.
Adds the two specified quaternions and stores the result in the output quaternion.
| [in] | _quaternion1 | The first quaternion |
| [in] | _quaternion2 | The second quaternion |
| [out] | _outQuaternion | The result of the addition |
| SUCCESS | The calculation succeed |
|
pure virtual |
Add two quaternions.
Adds the two specified quaternions and stores the result in the output quaternion.
| [in] | _quaternion1 | The first quaternion |
| [in] | _quaternion2 | The second quaternion |
| [out] | _outQuaternion | The result of the addition |
| SUCCESS | The calculation succeed |
|
pure virtual |
Conjugate the specified quaternion.
Conjugates the specified quaternion and stores the result in the output quaternion.
| [in] | _quaternion | The quaternion |
| [out] | _outQuaternion | The result of the conjugate |
| SUCCESS | The calculation succeed |
|
pure virtual |
Conjugate the specified quaternion.
Conjugates the specified quaternion and stores the result in the output quaternion.
| [in] | _quaternion | The quaternion |
| [out] | _outQuaternion | The result of the conjugate |
| SUCCESS | The calculation succeed |
|
pure virtual |
Calculates the cross product of the two specified quaternions.
Corsses two specified quaternions and stores the result in the output Value.
| [in] | _quaternion1 | The first quaternion |
| [in] | _quaternion2 | The second quaternion |
| [out] | _outVector | The vector of the corss product |
| SUCCESS | The calculation succeed |
|
pure virtual |
Calculates the cross product of the two specified quaternions.
Corsses two specified quaternions and stores the result in the output Value.
| [in] | _quaternion1 | The first quaternion |
| [in] | _quaternion2 | The second quaternion |
| [out] | _outVector | The vector of the corss product |
| SUCCESS | The calculation succeed |
|
pure virtual |
Calculates the dot product of the two specified quaternions.
Calculates the dot product of two specified quaternions and stores the result in the output Value.
| [in] | _quaternion1 | The first quaternion |
| [in] | _quaternion2 | The second quaternion |
| [out] | _outValue | The value of the dot product |
| SUCCESS | The calculation succeed |
|
pure virtual |
Calculates the dot product of the two specified quaternions.
Calculates the dot product of two specified quaternions and stores the result in the output Value.
| [in] | _quaternion1 | The first quaternion |
| [in] | _quaternion2 | The second quaternion |
| [out] | _outValue | The value of the dot product |
| SUCCESS | The calculation succeed |
|
pure virtual |
Identity the specified quaternion.
Set the output quaternion as an identity quaternion
| [out] | _outQuaternion | The result of the identity |
| SUCCESS | The calculation succeed |
|
pure virtual |
Identity the specified quaternion.
Set the output quaternion as an identity quaternion
| [out] | _outQuaternion | The result of the identity |
| SUCCESS | The calculation succeed |
|
pure virtual |
Inverse the specified quaternion.
Inverses the specified quaternion and stores the result in the output quaternion.
| [in] | _quaternion | The specified quaternion |
| [out] | _outQuaternion | The result of the inverse |
| SUCCESS | The calculation succeed |
| FAILURE | The calculation failed |
|
pure virtual |
Inverse the specified quaternion.
Inverses the specified quaternion and stores the result in the output quaternion.
| [in] | _quaternion | The specified quaternion |
| [out] | _outQuaternion | The result of the inverse |
| SUCCESS | The calculation succeed |
| FAILURE | The calculation failed |
|
pure virtual |
Linear interpolate between two specified quaternions.
Linear interpolates between two specified quaternions and stores the result in the output quaternion.
| [in] | _quaternion1 | The first quaternion |
| [in] | _quaternion2 | The seconds quaternion |
| [in] | _ratio | The interpolation coefficient |
| [out] | _outQuaternion | The result of the lerp |
| SUCCESS | The calculation succeed |
|
pure virtual |
Linear interpolate between two specified quaternions.
Linear interpolates between two specified quaternions and stores the result in the output quaternion.
| [in] | _quaternion1 | The first quaternion |
| [in] | _quaternion2 | The seconds quaternion |
| [in] | _ratio | The interpolation coefficient |
| [out] | _outQuaternion | The result of the lerp |
| SUCCESS | The calculation succeed |
|
pure virtual |
Calculate the magnitude of quaternion.
Calculate the magnitude of the specified quaternion and stores the result in the output value.
| [in] | _quaternion | The quaternion |
| [out] | _outMagnitude | The result of the Calculation |
| SUCCESS | The calculation succeed |
| FAILURE | The calculation failed |
|
pure virtual |
Calculate the magnitude of quaternion.
Calculate the magnitude of the specified quaternion and stores the result in the output value.
| [in] | _quaternion | The quaternion |
| [out] | _outMagnitude | The result of the Calculation |
| SUCCESS | The calculation succeed |
| FAILURE | The calculation failed |
|
pure virtual |
Multiply two quaternions.
Multiplies the two specified quaternions and stores the result in the output quaternion.
| [in] | _quaternion1 | The first quaternion |
| [in] | _quaternion2 | The second quaternion |
| [out] | _outQuaternion | The result of the multiplication |
| SUCCESS | The calculation succeed |
|
pure virtual |
Multiply two quaternions.
Multiplies the two specified quaternions and stores the result in the output quaternion.
| [in] | _quaternion1 | The first quaternion |
| [in] | _quaternion2 | The second quaternion |
| [out] | _outQuaternion | The result of the multiplication |
| SUCCESS | The calculation succeed |
|
pure virtual |
Normalize the specified quaternion.
Normalizes the specified quaternion and stores the result in the output quaternion.
| [in] | _quaternion | The quaternion |
| [out] | _outMagnitude | The result of the normalization |
| SUCCESS | The calculation succeed |
| FAILURE | The calculation failed |
|
pure virtual |
Normalize the specified quaternion.
Normalizes the specified quaternion and stores the result in the output quaternion.
| [in] | _quaternion | The quaternion |
| [out] | _outMagnitude | The result of the normalization |
| SUCCESS | The calculation succeed |
| FAILURE | The calculation failed |
|
pure virtual |
Scale the quaternion.
Scales the specified quaternion with a number and stores the result in the output quaternion.
| [in] | _quaternion | The quaternion |
| [in] | _scalar | The specified value to scale |
| [out] | _outQuaternion | The result of the scaling |
| SUCCESS | The calculation succeed |
|
pure virtual |
Scale the quaternion.
Scales the specified quaternion with a number and stores the result in the output quaternion.
| [in] | _quaternion | The quaternion |
| [in] | _scalar | The specified value to scale |
| [out] | _outQuaternion | The result of the scaling |
| SUCCESS | The calculation succeed |
|
pure virtual |
Set the quaternion by the specified matrix.
Sets the quaternion by the rotational part of the specifed matrix and stores the result in the output quaternion.
| [in] | _matrix | The specified matrix |
| [out] | _outQuaternion | The result of the rotation of matrix |
| SUCCESS | The calculation succeed |
| FAILURE | The calculation failed |
|
pure virtual |
Set the quaternion by the specified matrix.
Sets the quaternion by the rotational part of the specifed matrix and stores the result in the output quaternion.
| [in] | _matrix | The specified matrix |
| [out] | _outQuaternion | The result of the rotation of matrix |
| SUCCESS | The calculation succeed |
| FAILURE | The calculation failed |
|
pure virtual |
Set the quaternion by the specified vector and the specified angle.
Sets the quaternion with a number and stores the result in the output quaternion.
| [in] | _vector | The specified vector |
| [in] | _radain | The specified value of angle |
| [out] | _outQuaternion | The result of the rotation |
| SUCCESS | The calculation succeed |
|
pure virtual |
Set the quaternion by the specified vector and the specified angle.
Sets the quaternion with a number and stores the result in the output quaternion.
| [in] | _vector | The specified vector |
| [in] | _radian | The specified value of angle |
| [out] | _outQuaternion | The result of the rotation |
| SUCCESS | The calculation succeed |
|
pure virtual |
Spherical linear interpolates between two specified quaternions.
Spherical linear interpolates between two specified quaternions and stores the result in the output quaternion.
| [in] | _quaternion1 | The first quaternion |
| [in] | _quaternion2 | The seconds quaternion |
| [in] | _ratio | The interpolation coefficient |
| [out] | _outQuaternion | The result of the lerp |
| SUCCESS | The calculation succeed |
| FAILURE | The calculation failed |
|
pure virtual |
Spherical linear interpolates between two specified quaternions.
Spherical linear interpolates between two specified quaternions and stores the result in the output quaternion.
| [in] | _quaternion1 | The first quaternion |
| [in] | _quaternion2 | The seconds quaternion |
| [in] | _ratio | The interpolation coefficient |
| [out] | _outQuaternion | The result of the lerp |
| SUCCESS | The calculation succeed |
| FAILURE | The calculation failed |
|
pure virtual |
Subtract two quaternions.
Subtracts the two specified quaternions and stores the result in the output quaternion.
| [in] | _quaternion1 | The first quaternion |
| [in] | _quaternion2 | The second quaternion |
| [out] | _outQuaternion | The result of the subtraction |
| SUCCESS | The calculation succeed |
|
pure virtual |
Subtract two quaternions.
Subtracts the two specified quaternions and stores the result in the output quaternion.
| [in] | _quaternion1 | The first quaternion |
| [in] | _quaternion2 | The second quaternion |
| [out] | _outQuaternion | The result of the subtraction |
| SUCCESS | The calculation succeed |