Skip to content

shz_quat_inv

Markdown
SHZ_INLINE shz_quat_t shz_quat_inv(shz_quat_t quat) SHZ_NOEXCEPT;

Returns the inverse of the given quaternion.

NameTypeDescription
quatshz_quat_tThe quaternion to invert.

The inverse of quat.

The inverse is the conjugate of quat divided by its squared magnitude.

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

shz_quat_conjugate