Philip Rebohle : vkd3d-shader: Don't redundantly override shader output info.

Alexandre Julliard julliard at winehq.org
Sun Oct 27 14:21:21 CDT 2019


Module: vkd3d
Branch: master
Commit: 1eb7eca411f71d8dec7cfae5c58c1dff9626a7e0
URL:    https://source.winehq.org/git/vkd3d.git/?a=commit;h=1eb7eca411f71d8dec7cfae5c58c1dff9626a7e0

Author: Philip Rebohle <philip.rebohle at tu-dortmund.de>
Date:   Thu Oct 24 22:33:15 2019 +0200

vkd3d-shader: Don't redundantly override shader output info.

Signed-off-by: Philip Rebohle <philip.rebohle at tu-dortmund.de>
Signed-off-by: Henri Verbeet <hverbeet at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 libs/vkd3d-shader/spirv.c | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/libs/vkd3d-shader/spirv.c b/libs/vkd3d-shader/spirv.c
index 6291036..13c6fd2 100644
--- a/libs/vkd3d-shader/spirv.c
+++ b/libs/vkd3d-shader/spirv.c
@@ -4268,11 +4268,13 @@ static void vkd3d_dxbc_compiler_emit_shader_signature_outputs(struct vkd3d_dxbc_
         {
             case VKD3D_SV_CLIP_DISTANCE:
                 compiler->output_info[i].id = clip_distance_id;
+                compiler->output_info[i].component_type = VKD3D_TYPE_FLOAT;
                 compiler->output_info[i].array_element_mask = clip_distance_mask;
                 break;
 
             case VKD3D_SV_CULL_DISTANCE:
                 compiler->output_info[i].id = cull_distance_id;
+                compiler->output_info[i].component_type = VKD3D_TYPE_FLOAT;
                 compiler->output_info[i].array_element_mask = cull_distance_mask;
                 break;
 
@@ -4463,10 +4465,10 @@ static void vkd3d_dxbc_compiler_emit_output(struct vkd3d_dxbc_compiler *compiler
             vkd3d_spirv_build_op_decorate(builder, id, SpvDecorationPatch, NULL, 0);
 
         vkd3d_dxbc_compiler_decorate_xfb_output(compiler, id, output_component_count, signature_element);
-    }
 
-    compiler->output_info[signature_idx].id = id;
-    compiler->output_info[signature_idx].component_type = component_type;
+        compiler->output_info[signature_idx].id = id;
+        compiler->output_info[signature_idx].component_type = component_type;
+    }
 
     if (use_private_variable)
         storage_class = SpvStorageClassPrivate;




More information about the wine-cvs mailing list