Skip to content

shz_quat_normalize

Markdown
SHZ_INLINE shz_quat_t shz_quat_normalize(shz_quat_t quat) SHZ_NOEXCEPT;

Returns the normalized form of the given quaternion.

NameTypeDescription
quatshz_quat_tThe quaternion to normalize.

The unit quaternion in the same direction as quat.

This is the fastest normalization routine, which does not check for a zero-length quaternion.

  • Results in a division-by-zero when quat has a magnitude of 0.0f.

shz_quat_normalize_or, shz_quat_normalize_safe