Skip to content

et_normalizeQuaternion

DeveloperGY edited this page Apr 13, 2023 · 4 revisions

Signature

et_Quat et_normalizeQuaternion(et_Quat q);

Parameters

et_Quat q: The quaternion to normalize

Return Value

et_Quat: The normalized version of the specified quaternion

Description

Returns the normalized version of the quaternion.
This is NOT the norm of the quaternion, that would be returned by

float et_normQuaternion(et_Quat q);

Uses

The normalized quaternion is used to make sure that when rotating a vector, it rotates by a standard amount

Example

et_Quat q = et_genQuaternion(0, et_genVec3f(3, 4, 5));
et_Quat r = et_normalizeQuaternion(q);

Clone this wiki locally