16
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-07-18 23:49:19 +02:00
Files
maszyna/betterRenderer/shaders/manul/apply_auto_exposure.hlsl
2025-04-15 01:32:56 +02:00

8 lines
313 B
HLSL

RWTexture2D<float4> g_ColorImage : register(u0);
Texture2D<float2> g_AutoExposureTexture : register(t0);
[numthreads(8, 8, 1)]
void CS_ApplyAutoExposure(uint3 PixCoord : SV_DispatchThreadID) {
g_ColorImage[PixCoord.xy] = max(1.e-6, g_ColorImage[PixCoord.xy] * pow(2., g_AutoExposureTexture[uint2(0, 0)].x));
}