Template Function TRAP::Math::FrExp(Vec<L, T>, Vec<L, i32>&)#

Function Documentation#

template<u32 L, typename T>
Vec<L, T> TRAP::Math::FrExp(Vec<L, T> v, Vec<L, i32> &exp)#

Splits x into a floating-point significant in the range [0.5, 1.0) and an integral exponent of two, such that x = significant * Exp(2, exponent). This significant is returned by the function and exponent is returned in the parameter exp. For a floating-point value of zero, the significant and exponent are both zero.

Note

For a floating-point value that is at infinity or is not a number, the results are undefined!

Parameters:
  • v – Specifies the value from which significand and exponent are to be extracted.

  • exp – Out specifies the variable into which to place the exponent.

Returns:

See description.