Template Function TRAP::Math::Sign(genFIType)#

Function Documentation#

template<typename genFIType>
constexpr genFIType TRAP::Math::Sign(genFIType x)#

Extract the sign of x.

Parameters:

x – Specify the value from which to extract the sign.

Returns:

1.0f if x > 0, 0.0 if x == 0, or -1.0 if x < 0.