Template Function TRAP::Math::ConvertSRGBToLinear(const Vec<L, T>&, T)#
Function Documentation#
-
template<u32 L, typename T>
constexpr Vec<L, T> TRAP::Math::ConvertSRGBToLinear(const Vec<L, T> &colorSRGB, T gamma)# Convert a sRGB color to linear color using a custom gamma correction. IEC 61966-2-1:1999 / Rec. 709 specification https://www.w3.org/Graphics/Color/srgb.
- Parameters:
colorSRGB – Color in sRGB space.
gamma – Gamma correction value to use. Typically 2.4 is used.
- Returns:
Color in linear space.