#include <nCine/Primitives/Quaternion.h>
template<class T>
Quaternion class
Quaternion.
Public static variables
- static const Quaternion Zero
- A quaternion with all zero elements.
- static const Quaternion Identity
- An identity quaternion.
Public static functions
- static auto FromAxisAngle(T xx, T yy, T zz, T degrees) -> Quaternion
- static auto FromAxisAngle(const Vector3<T>& axis, T degrees) -> Quaternion
- static auto FromXAxisAngle(T degrees) -> Quaternion
- static auto FromYAxisAngle(T degrees) -> Quaternion
- static auto FromZAxisAngle(T degrees) -> Quaternion
Constructors, destructors, conversion operators
- Quaternion() constexpr noexcept
- Quaternion(NoInitT) explicit noexcept
- constexprQuaternion(T x, T y, T z, T w) noexcept
- Quaternion(const Vector4<T>& v) explicit noexcept
- Quaternion(const Quaternion& other) constexpr noexcept
Public functions
- auto operator=(const Quaternion& other) -> Quaternion&
- void Set(T x, T y, T z, T w)
- auto Data() -> T*
- auto Data() const -> const T*
-
auto operator[](std::
size_t index) -> T& -
auto operator[](std::
size_t index) const -> const T& - auto operator==(const Quaternion& q) const -> bool
- auto operator!=(const Quaternion& q) const -> bool
- auto operator-() const -> Quaternion
- auto operator+=(const Quaternion& q) -> Quaternion&
- auto operator-=(const Quaternion& q) -> Quaternion&
- auto operator*=(const Quaternion& q) -> Quaternion&
- auto operator*=(T s) -> Quaternion&
- auto operator/=(T s) -> Quaternion&
- auto operator+(const Quaternion& q) const -> Quaternion
- auto operator-(const Quaternion& q) const -> Quaternion
- auto operator*(const Quaternion& q) const -> Quaternion
- auto operator*(T s) const -> Quaternion
- auto operator/(T s) const -> Quaternion
- auto Magnitude() const -> T
- auto SqrMagnitude() const -> T
- auto Normalized() const -> Quaternion
- auto Normalize() -> Quaternion&
- auto Conjugated() const -> Quaternion
- auto Conjugate() -> Quaternion&
- auto ToMatrix4x4() const -> Matrix4x4<T>