diff options
| author | 2026-07-30 10:51:51 -0400 | |
|---|---|---|
| committer | 2026-07-30 10:51:51 -0400 | |
| commit | 298e392ccb1967036b60abc151ec3093304ab00e (patch) | |
| tree | d864933b9fbfd18d1518b93ea5fb95f9ca487e11 /Shaders/alpha_as_luma.hlsl | |
| parent | 6265e51d8270a23fb16e2ecb3e85356910197e32 (diff) | |
| download | WorldTuningTool-298e392ccb1967036b60abc151ec3093304ab00e.tar.gz WorldTuningTool-298e392ccb1967036b60abc151ec3093304ab00e.tar.bz2 WorldTuningTool-298e392ccb1967036b60abc151ec3093304ab00e.zip | |
Improve LUT feature, add HDR params
Signed-off-by: Andrew Opalach <andrew@akon.city>
Diffstat (limited to 'Shaders/alpha_as_luma.hlsl')
| -rw-r--r-- | Shaders/alpha_as_luma.hlsl | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Shaders/alpha_as_luma.hlsl b/Shaders/alpha_as_luma.hlsl index 525f3c6..dff76c6 100644 --- a/Shaders/alpha_as_luma.hlsl +++ b/Shaders/alpha_as_luma.hlsl @@ -1,14 +1,14 @@ // https://stackoverflow.com/a/37624009
float inverseGamma(float t)
{
- return ((t <= 0.0404482362771076) ? (t/12.92) : pow((t + 0.055)/1.055, 2.4));
+ return (t <= 0.0404482362771076) ? (t/12.92) : pow((t + 0.055)/1.055, 2.4);
}
// CIE L*a*b* f function (used to convert XYZ to L*a*b*)
// http://en.wikipedia.org/wiki/Lab_color_space
float LABF(float t)
{
- return ((t >= 8.85645167903563082e-3) ? pow(t, (1.0/3.0)) : (841.0/108.0)*t + (4.0/29.0));
+ return (t >= 8.85645167903563082e-3) ? pow(t, (1.0/3.0)) : (841.0/108.0)*t + (4.0/29.0);
}
float rgbToCIEL(float3 p)
|