diff options
author | Ryan Holtz <rholtz@batcountryentertainment.com> | 2011-05-31 13:53:25 +0000 |
---|---|---|
committer | Ryan Holtz <rholtz@batcountryentertainment.com> | 2011-05-31 13:53:25 +0000 |
commit | f42b5ccda0d819869951538876e8cb8a0433d77b (patch) | |
tree | 0e82d407707cfcc4192e7c19e9bed704ea9e7b25 /hlsl/prescale.fx | |
parent | 7418f28a638b43aadccc5149340817eca5a69486 (diff) |
No whatsnew
Attempting to fix the HLSL 'blurriness' reported by a few people. Now HLSL will auto-prescale to the nearest texture size that is greater than the target screen size on both axes and is also an even multiple of the raw bitmap's size.
Diffstat (limited to 'hlsl/prescale.fx')
-rw-r--r-- | hlsl/prescale.fx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/hlsl/prescale.fx b/hlsl/prescale.fx index 633b0872d48..6b3dff8d058 100644 --- a/hlsl/prescale.fx +++ b/hlsl/prescale.fx @@ -72,7 +72,8 @@ float4 ps_main(PS_INPUT Input) : COLOR { float2 RawDims = float2(RawWidth, RawHeight); float2 TexCoord = Input.TexCoord * RawDims; - TexCoord -= frac(float2(0.0f, TexCoord.y)); + TexCoord -= frac(TexCoord); + TexCoord += 0.5f; TexCoord /= RawDims; float4 Center = tex2D(DiffuseSampler, TexCoord); |