From c915193e8256c2ff875e943249c2fa17505eb652 Mon Sep 17 00:00:00 2001 From: Stuart Carnie Date: Sat, 14 Jul 2018 14:42:33 -0700 Subject: [PATCH] fix(crt-royale): Ensures output location is defined for Metal support * error after SPIRV-Cross is that output locations are not defined --- crt/shaders/crt-royale/src/crt-royale-bloom-approx.h | 2 +- .../crt-royale/src/crt-royale-mask-resize-horizontal.slang | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/crt/shaders/crt-royale/src/crt-royale-bloom-approx.h b/crt/shaders/crt-royale/src/crt-royale-bloom-approx.h index 0983b97..8b239ec 100644 --- a/crt/shaders/crt-royale/src/crt-royale-bloom-approx.h +++ b/crt/shaders/crt-royale/src/crt-royale-bloom-approx.h @@ -119,7 +119,7 @@ void main() // resize is used instead of tex2Dblur3x3_resize (which samples between // texels even for upsizing). const float2 dxdy_min_scale = ORIG_LINEARIZEDvideo_size/IN.output_size; - const float2 texture_size_inv = float2(1.0)/ORIG_LINEARIZEDtexture_size; + texture_size_inv = float2(1.0)/ORIG_LINEARIZEDtexture_size; if(bloom_approx_filter > 1.5) // 4x4 true Gaussian resize { // For upsizing, we'll snap to texels and sample the nearest 4. diff --git a/crt/shaders/crt-royale/src/crt-royale-mask-resize-horizontal.slang b/crt/shaders/crt-royale/src/crt-royale-mask-resize-horizontal.slang index 27fb69c..37e7e43 100755 --- a/crt/shaders/crt-royale/src/crt-royale-mask-resize-horizontal.slang +++ b/crt/shaders/crt-royale/src/crt-royale-mask-resize-horizontal.slang @@ -117,7 +117,7 @@ void main() // and the number of tiles that will fit in the FBO. const float2 output_tiles_this_pass = IN.output_size / mask_resize_tile_size; const float2 output_video_uv = tex_uv * IN.texture_size / IN.video_size; - const float2 tile_uv_wrap = output_video_uv * output_tiles_this_pass; + tile_uv_wrap = output_video_uv * output_tiles_this_pass; // Get the texel size of an input tile and related values: const float2 input_tile_size = float2(min(