17 : x{0.0f}, y{0.0f}, z{0.0f}, w{1.0f}
21 explicit Quaternion(
float X,
float Y,
float Z,
float W);
23 auto ToEulerAngles()
const noexcept ->
Vector3;
24 void ToAxisAngle(
Vector3* axisOut,
float* angleOut)
const noexcept;
28 static auto FromEulerAngles(
float x,
float y,
float z) ->
Quaternion;
53 return FloatEqual(lhs.x, rhs.x) &&
54 FloatEqual(lhs.y, rhs.y) &&
55 FloatEqual(lhs.z, rhs.z) &&
56 FloatEqual(lhs.w, rhs.w);
59inline auto operator!=(
const Quaternion& lhs,
const Quaternion& rhs) ->
bool
auto Normalize(const Quaternion &quat) -> Quaternion
Return a normalized quaternion.
auto Multiply(const Quaternion &lhs, const Quaternion &rhs) -> Quaternion
Multiplies two quaternions.
auto Scale(const Quaternion &quat, float factor) -> Quaternion
Slerp from Identity to quat.
auto Slerp(const Quaternion &lhs, const Quaternion &rhs, float factor) -> Quaternion
Interpolates from lhs to rhs.
auto Difference(const Quaternion &lhs, const Quaternion &rhs) -> Quaternion
Finds rotation between lhs and rhs such that result * lhs == rhs.
Quaternion type for representing 3D rotations.
Definition: Quaternion.h:13
A three component vector.
Definition: Vector.h:29