Mesa (master): radeonsi: fix gl_PrimitiveIDIn in geometry shader when using tessellation

Nicolai Hähnle nh at kemper.freedesktop.org
Tue May 16 14:12:05 UTC 2017


Module: Mesa
Branch: master
Commit: f4dbe2efb77be366c52cdd134876a6b00bf324bd
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=f4dbe2efb77be366c52cdd134876a6b00bf324bd

Author: Nicolai Hähnle <nicolai.haehnle at amd.com>
Date:   Mon May 15 11:10:13 2017 +0200

radeonsi: fix gl_PrimitiveIDIn in geometry shader when using tessellation

This builds on commit 0549ea15ec38 ("radeonsi: fix primitive ID in
fragment shader when using tessellation").

Fixes piglit
arb_tessellation_shader/execution/gs-primitiveid-instanced.shader_test

Cc: 17.1 <mesa-stable at lists.freedesktop.org>
Reviewed-by: Marek Olšák <marek.olsak at amd.com>

---

 src/gallium/drivers/radeonsi/si_state_shaders.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/gallium/drivers/radeonsi/si_state_shaders.c b/src/gallium/drivers/radeonsi/si_state_shaders.c
index 5da60148af..f761073616 100644
--- a/src/gallium/drivers/radeonsi/si_state_shaders.c
+++ b/src/gallium/drivers/radeonsi/si_state_shaders.c
@@ -2133,6 +2133,8 @@ static void si_update_tcs_tes_uses_prim_id(struct si_context *sctx)
 		 sctx->tes_shader.cso->info.uses_primid) ||
 		(sctx->tcs_shader.cso &&
 		 sctx->tcs_shader.cso->info.uses_primid) ||
+		(sctx->gs_shader.cso &&
+		 sctx->gs_shader.cso->info.uses_primid) ||
 		(sctx->ps_shader.cso && !sctx->gs_shader.cso &&
 		 sctx->ps_shader.cso->info.uses_primid);
 }




More information about the mesa-commit mailing list