17#ifndef __albaQuaternion_H__
18#define __albaQuaternion_H__
albaMatrix - Time stamped 4x4 Matrix.
albaQuaternion(albaMatrix &matr)
Construct quaternion from rotation albaMatrix.
void Identity()
Set quaternion to identity.
bool Normalized()
return true if the quaternion is normalized
albaQuaternion operator*(double s)
void Subtract(albaQuaternion &q)
Subtract another quaternion from this quaternion.
void Multiply(double s)
Multiply this quaternion by a scalar.
double m_X
x component of quaternion
albaQuaternion Dot(albaQuaternion &q)
Dot product of two quaternions.
static albaQuaternion Slerp(albaQuaternion &a, albaQuaternion &b, double t)
Spherical linear interpolation.
double m_W
w component of quaternion
double & operator[](int i)
void Multiply(albaQuaternion &q)
Multiply this quaternion with another quaternion.
void Multiply(albaQuaternion &q, albaQuaternion &result)
Multiply this quaternion with another quaternion and store result in parameter.
albaQuaternion & operator*=(const albaQuaternion b)
double GetLength()
Calculate and returns the length of quaternion.
void Normalize()
Normalize the quaternion.
albaQuaternion & operator-=(albaQuaternion b)
albaQuaternion Conjugate()
Calculate conjugate of quaternion.
bool operator==(albaQuaternion &other)
Equals operator.
albaQuaternion & operator/=(double s)
bool operator!=(albaQuaternion &other)
Not equals operator.
void Divide(double s)
Divide this quaternion by a scalar.
double m_Z
z component of quaternion
albaQuaternion(double w, double x, double y, double z)
Constructor quaternion from real component w and imaginary x,y,z.
void Dot(albaQuaternion &q, albaQuaternion &result)
Dot product of two quaternions writing result to parameter.
albaQuaternion & operator+=(albaQuaternion b)
albaQuaternion operator-(albaQuaternion b)
albaQuaternion operator+(albaQuaternion b)
albaQuaternion Inverse()
Calculate inverse of quaternion.
void Zero()
Set quaternion to zero.
albaQuaternion(double angle, albaVect3d &axis)
Construct quaternion from angle - axis.
double GetNorm()
Calculate and returns the norm of quaternion.
void Inverse(albaQuaternion &result)
Calculate inverse of quaternion and store result in parameter.
albaQuaternion operator*(albaQuaternion b)
void Conjugate(albaQuaternion &result)
Calculate conjugate of quaternion and store result in parameter.
void Add(albaQuaternion &q)
Add another quaternion to this quaternion.
albaQuaternion()
Default constructor.
albaQuaternion & operator*=(double s)
albaMatrix ToMatrix()
Convert quaternion to albaMatrix.
albaQuaternion operator-()
void AngleAxis(double &angle, albaVect3d &axis)
Convert quaternion to angle - axis.
albaQuaternion operator/(double s)
double m_Y
y component of quaternion