From 7f57e74535849ca3ddd7d2fe2d14896457ad0916 Mon Sep 17 00:00:00 2001 From: hunterk Date: Wed, 18 Jan 2017 12:45:32 -0600 Subject: [PATCH] fix some dumb mistakes --- retro/shaders/sharp-bilinear.slang | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/retro/shaders/sharp-bilinear.slang b/retro/shaders/sharp-bilinear.slang index 4c5766d..73b2590 100644 --- a/retro/shaders/sharp-bilinear.slang +++ b/retro/shaders/sharp-bilinear.slang @@ -44,10 +44,10 @@ layout(set = 0, binding = 2) uniform sampler2D Source; void main() { - vec2 texel = vTexCoord * global.SourceSize.xy; + vec2 texel = vTexCoord * params.SourceSize.xy; vec2 texel_floored = floor(texel); vec2 s = fract(texel); - float scale = (AUTO_PRESCALE > 0.5) ? floor(params.OutputSize.y / params.SourceSize.y) : params.SHARP_BILINEAR_PRE_SCALE; + float scale = (params.AUTO_PRESCALE > 0.5) ? floor(params.OutputSize.y / params.SourceSize.y) : params.SHARP_BILINEAR_PRE_SCALE; float region_range = 0.5 - 0.5 / scale; // Figure out where in the texel to sample to get correct pre-scaled bilinear. @@ -58,5 +58,5 @@ void main() vec2 mod_texel = texel_floored + f; - FragColor = vec4(texture(Source, mod_texel / global.SourceSize.xy).rgb, 1.0); + FragColor = vec4(texture(Source, mod_texel / params.SourceSize.xy).rgb, 1.0); }