From 384c8677f590df290c442b378b077fe8e8c365b9 Mon Sep 17 00:00:00 2001 From: Dave Airlie Date: Fri, 30 Jun 2023 13:16:17 +1000 Subject: [PATCH] draw/gs: handle extra shader outputs in geometry. When geometry shader is used with unfilled lines and front face, we don't handle the extra shader output. Instead of taking the output from the gs, ask draw for the total which should give the correct answer. Fixes a test program attached to: https://gitlab.freedesktop.org/mesa/mesa/-/issues/8644 Reviewed-by: Brian Paul Cc: mesa-stable Part-of: --- src/gallium/auxiliary/draw/draw_pt_fetch_shade_pipeline_llvm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gallium/auxiliary/draw/draw_pt_fetch_shade_pipeline_llvm.c b/src/gallium/auxiliary/draw/draw_pt_fetch_shade_pipeline_llvm.c index 360aa8ac38d..8fa6bc6bf8f 100644 --- a/src/gallium/auxiliary/draw/draw_pt_fetch_shade_pipeline_llvm.c +++ b/src/gallium/auxiliary/draw/draw_pt_fetch_shade_pipeline_llvm.c @@ -120,7 +120,7 @@ llvm_middle_end_prepare_gs(struct llvm_middle_end *fpme) } } - variant = draw_gs_llvm_create_variant(llvm, gs->info.num_outputs, key); + variant = draw_gs_llvm_create_variant(llvm, draw_total_gs_outputs(draw), key); if (variant) { list_add(&variant->list_item_local.list, &shader->variants.list);