Go to the documentation of this file.
31 #include "../../../Primitives/interface/BasicTypes.h"
38 return x <= 0.0031308 ? x * 12.92f : 1.055f * std::pow(x, 1.f / 2.4f) - 0.055f;
43 return x <= 0.04045f ? x / 12.92f : std::pow((x + 0.055f) / 1.055f, 2.4f);
51 return x < 0.0031308f ? 12.92f * x : 1.13005f * sqrtf(
std::abs(x - 0.00228f)) - 0.13448f * x + 0.005719f;
57 return x * (x * (x * 0.305306011f + 0.682171111f) + 0.012522878f);
Vector2< T > abs(const Vector2< T > &a)
Definition: BasicMath.hpp:1672
float SRGBToLinear(Uint8 x)
Definition: ColorConversion.cpp:86
#define DILIGENT_END_NAMESPACE
Definition: CommonDefinitions.h:86
n n float LinearToSRGB(float x)\n" "
Definition: GenerateMipsCS_inc.h:51
float FastLinearToSRGB(float x)
Definition: ColorConversion.h:49
uint8_t Uint8
8-bit unsigned integer
Definition: BasicTypes.h:53
#define DILIGENT_BEGIN_NAMESPACE(Name)
Definition: CommonDefinitions.h:82
float FastSRGBToLinear(float x)
Definition: ColorConversion.h:54
The library uses Direct3D-style math:
Definition: AdvancedMath.hpp:37