Class representing quaternion object. The quaternion is number system that extends the complex numbers. Quaternions are used for calculations involving three-dimensional rotations,.
More...
#include <Quaternion.hpp>
|
|
| Quaternion () |
| | Constructs default quaternion.
|
| |
| | Quaternion (double x, double y, double z, const vrml_proc::math::Angle &angle) |
| | Constructs quaternion.
|
| |
|
Quaternion | operator* (const Quaternion &second) const |
| | Overloaded operator for multiplying quaternions.
|
| |
| bool | IsNormalized () const |
| | Checks if the quaternion is normalized.
|
| |
|
void | Normalize () |
| | Normalized the quaternion.
|
| |
| void | Inverse () |
| | Inverses the quaternion.
|
| |
|
|
double | x |
| | Publicly available values. Note that value w is in radians!
|
| |
|
double | y |
| |
|
double | z |
| |
|
double | w |
| |
Class representing quaternion object. The quaternion is number system that extends the complex numbers. Quaternions are used for calculations involving three-dimensional rotations,.
- Note
- The main resource for this topic was https://www.cprogramming.com/tutorial/3d/quaternions.html.
- Todo
- Values
x, y, z and w should be private and getters and setters shouls be made!
◆ Quaternion()
| vrml_proc::math::Quaternion::Quaternion |
( |
double | x, |
|
|
double | y, |
|
|
double | z, |
|
|
const vrml_proc::math::Angle & | angle ) |
|
inline |
Constructs quaternion.
- Parameters
-
| x | x value |
| y | y value |
| z | z value |
| angle | w value representing angle |
◆ Inverse()
| void vrml_proc::math::Quaternion::Inverse |
( |
| ) |
|
|
inline |
◆ IsNormalized()
| bool vrml_proc::math::Quaternion::IsNormalized |
( |
| ) |
const |
|
inline |
Checks if the quaternion is normalized.
- Returns
- true if quaterniion is normalized, otherwise false
The documentation for this struct was generated from the following file: