Mesa (master): radeonsi: always interpolate PrimID as flat

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Wed Jun 12 00:05:40 UTC 2019


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

Author: Marek Olšák <marek.olsak at amd.com>
Date:   Tue May 28 20:12:53 2019 -0400

radeonsi: always interpolate PrimID as flat

---

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

diff --git a/src/gallium/drivers/radeonsi/si_state_shaders.c b/src/gallium/drivers/radeonsi/si_state_shaders.c
index c26acbbc927..c4517fcf538 100644
--- a/src/gallium/drivers/radeonsi/si_state_shaders.c
+++ b/src/gallium/drivers/radeonsi/si_state_shaders.c
@@ -2828,7 +2828,8 @@ static unsigned si_get_ps_input_cntl(struct si_context *sctx,
 	unsigned j, offset, ps_input_cntl = 0;
 
 	if (interpolate == TGSI_INTERPOLATE_CONSTANT ||
-	    (interpolate == TGSI_INTERPOLATE_COLOR && sctx->flatshade))
+	    (interpolate == TGSI_INTERPOLATE_COLOR && sctx->flatshade) ||
+	    name == TGSI_SEMANTIC_PRIMID)
 		ps_input_cntl |= S_028644_FLAT_SHADE(1);
 
 	if (name == TGSI_SEMANTIC_PCOORD ||




More information about the mesa-commit mailing list