Math::Quaternion class reference
[Core module]
Declaration
#include <Goptical/Math/Quaternion>
namespace Goptical {
namespace Math {
class Quaternion;
};
};
This class is a member of the Math namespace.
Description
This class describe a quaternion object. Useful for 3d rotations.
Members
See also the full member list section for this class.
Functions
- Quaternion()
- Quaternion(double x, double y, double z, double w)
- Quaternion(const Vector3 &a, const Vector3 &b)
- double norm() const
- const Quaternion & normalize()
- Quaternion operator*(const Quaternion &q) const
- double w() const
- double & w()
- double x() const
- double & x()
- double y() const
- double & y()
- double z() const
- double & z()
Static functions
Members detail
No documentation available
Create a Quaternion from its real values
Create a Quaternion as rotation between two unit vectors
static Quaternion angle(const Vector3 &v, double angle)
Create a Quaternion with given rotation angle along a 3d vector
static Quaternion angle_rad(const Vector3 &v, double angle)
Create a Quaternion with given rotation angle in radian along a 3d vector
Adjust vector length
const Quaternion & normalize()
Normalize vector length
Quaternion operator*(const Quaternion &q) const
Multiply with an other quaternion
Get quaterion w value
Get reference to quaterion w value
Get quaterion x value
Get reference to quaterion x value
Get quaterion y value
Get reference to quaterion y value
Get quaterion z value
Get reference to quaterion z value