diff --git a/plugins/GSdx/res/glsl/tfx_fs.glsl b/plugins/GSdx/res/glsl/tfx_fs.glsl index 572189d6cb..26ab97c736 100644 --- a/plugins/GSdx/res/glsl/tfx_fs.glsl +++ b/plugins/GSdx/res/glsl/tfx_fs.glsl @@ -428,7 +428,7 @@ vec4 sample_color(vec2 st) // Background in Shin Megami Tensei Lucifers // I suspect that uv isn't a standard number, so fract is outside of the [0;1] range // Note: it is free on GPU but let's do it only for float coordinate - // Strangely Dx doesn't suffer from this issue. + // Strangely DX9 doesn't suffer from this issue. dd = clamp(dd, vec2(0.0f), vec2(1.0f)); #endif } diff --git a/plugins/GSdx/res/tfx.fx b/plugins/GSdx/res/tfx.fx index f918bb1660..a3ebdc2cba 100644 --- a/plugins/GSdx/res/tfx.fx +++ b/plugins/GSdx/res/tfx.fx @@ -403,6 +403,12 @@ float4 sample(float2 st, float q) { uv = st.xyxy + HalfTexel; dd = frac(uv.xy * WH.zw); + #if SHADER_MODEL >= 0x400 + if(PS_FST == 0) + { + dd = clamp(dd, (float2)0.0, (float2)0.9999999); + } + #endif } else {