summaryrefslogtreecommitdiffstatshomepage
path: root/hlsl/deconverge.fx
diff options
context:
space:
mode:
author Ryan Holtz <rholtz@batcountryentertainment.com>2011-05-22 02:27:31 +0000
committer Ryan Holtz <rholtz@batcountryentertainment.com>2011-05-22 02:27:31 +0000
commit53e20c168ff568f618efa3aa5b1e58e5a8457031 (patch)
treeb2585c3df902817c4d3197c87b3d02b10f0f5fa6 /hlsl/deconverge.fx
parent2cd23c14765a433c589a9627ae01080cb1f3a5d8 (diff)
Fixing multiscreen games, nwn
Diffstat (limited to 'hlsl/deconverge.fx')
-rw-r--r--hlsl/deconverge.fx3
1 files changed, 2 insertions, 1 deletions
diff --git a/hlsl/deconverge.fx b/hlsl/deconverge.fx
index 2315ab5f89f..178fbef578e 100644
--- a/hlsl/deconverge.fx
+++ b/hlsl/deconverge.fx
@@ -113,11 +113,12 @@ float4 ps_main(PS_INPUT Input) : COLOR
float MagnetDistance = length((MagnetCenter - Input.TexCoord) * float2(WidthRatio, HeightRatio));
float Deconverge = 1.0f - MagnetDistance / MagnetCenter;
Deconverge = clamp(Deconverge, 0.0f, 1.0f);
+ float Alpha = tex2D(DiffuseSampler, Input.TexCoord).a;
float RedTexel = tex2D(DiffuseSampler, lerp(Input.TexCoord, Input.RedCoord, Deconverge)).r;
float GrnTexel = tex2D(DiffuseSampler, lerp(Input.TexCoord, Input.GrnCoord, Deconverge)).g;
float BluTexel = tex2D(DiffuseSampler, lerp(Input.TexCoord, Input.BluCoord, Deconverge)).b;
- return float4(RedTexel, GrnTexel, BluTexel, 1.0f);
+ return float4(RedTexel, GrnTexel, BluTexel, Alpha);
}
//-----------------------------------------------------------------------------