From 04fd90ecec9d4aa05d8b129475ae3d459bd475ed Mon Sep 17 00:00:00 2001 From: papadanku <115061077+papadanku@users.noreply.github.com> Date: Sat, 6 Jul 2024 21:58:28 -0700 Subject: [PATCH] Update cAutoExposure.fx --- shaders/cAutoExposure.fx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/shaders/cAutoExposure.fx b/shaders/cAutoExposure.fx index 2a80946..a720035 100644 --- a/shaders/cAutoExposure.fx +++ b/shaders/cAutoExposure.fx @@ -69,6 +69,7 @@ float4 PS_Blit(VS2PS_Quad Input) : SV_TARGET0 if (_Meter == 1) { Tex = (Tex * 2.0) - 1.0; + // Expand the UV so [-1, 1] fills the shape of its input texture instead of output #if BUFFER_WIDTH > BUFFER_HEIGHT Tex.x /= ASPECT_RATIO; #else @@ -100,6 +101,8 @@ float3 PS_Exposure(VS2PS_Quad Input) : SV_TARGET0 float2 Pos = (Input.Tex0 * 2.0) - 1.0; Pos -= float2(_Offset.x, -_Offset.y); Pos /= _Scale; + + // Shrink the UV so [-1, 1] fills a square #if BUFFER_WIDTH > BUFFER_HEIGHT Pos.x *= ASPECT_RATIO; #else