From 2621fc95722f6611d3994aaec701efe6a7eb8150 Mon Sep 17 00:00:00 2001 From: Francisco Casas Date: Sat, 30 Mar 2024 02:11:01 -0300 Subject: [PATCH] vkd3d-shader/ir: Add missing src swizzle in vsir_program_lower_texkills(). --- libs/vkd3d-shader/ir.c | 1 + tests/hlsl/clip.shader_test | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/libs/vkd3d-shader/ir.c b/libs/vkd3d-shader/ir.c index 8af53739..973d66ea 100644 --- a/libs/vkd3d-shader/ir.c +++ b/libs/vkd3d-shader/ir.c @@ -127,6 +127,7 @@ static enum vkd3d_result vsir_program_lower_texkills(struct vsir_program *progra ins->dst[0].write_mask = VKD3DSP_WRITEMASK_ALL; ins->src[0].reg = texkill_ins->dst[0].reg; + ins->src[0].swizzle = VKD3D_SHADER_NO_SWIZZLE; vsir_register_init(&ins->src[1].reg, VKD3DSPR_IMMCONST, VKD3D_DATA_FLOAT, 0); ins->src[1].reg.dimension = VSIR_DIMENSION_VEC4; ins->src[1].reg.u.immconst_f32[0] = 0.0f; diff --git a/tests/hlsl/clip.shader_test b/tests/hlsl/clip.shader_test index 64ccb6b1..4a8d223c 100644 --- a/tests/hlsl/clip.shader_test +++ b/tests/hlsl/clip.shader_test @@ -22,7 +22,7 @@ todo(glsl) draw quad probe all rgba (9, 0, 7, 6) uniform 0 float4 3 -8 3 0 todo(glsl) draw quad -todo(sm<4) probe all rgba (9, 0, 7, 6) +probe all rgba (9, 0, 7, 6) uniform 0 float4 3 3 3 -1 todo(glsl) draw quad -todo(sm<4) probe all rgba (9, 0, 7, 6) +probe all rgba (9, 0, 7, 6)