Mesa (master): r300g: only set clip_halfz for chips with HW TCL

Marek Olšák mareko at kemper.freedesktop.org
Tue Oct 28 22:41:25 UTC 2014


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

Author: Marek Olšák <marek.olsak at amd.com>
Date:   Tue Oct 28 11:12:27 2014 +0100

r300g: only set clip_halfz for chips with HW TCL

I forgot that we cannot emit vertex shader state on a chip without VS.
In such a case, clip_halfz is handled by the Draw module.

---

 src/gallium/drivers/r300/r300_state.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/gallium/drivers/r300/r300_state.c b/src/gallium/drivers/r300/r300_state.c
index cfcc19d..6ce0329 100644
--- a/src/gallium/drivers/r300/r300_state.c
+++ b/src/gallium/drivers/r300/r300_state.c
@@ -1432,7 +1432,7 @@ static void r300_bind_rs_state(struct pipe_context* pipe, void* state)
         }
     }
 
-    if (last_clip_halfz != r300->clip_halfz) {
+    if (r300->screen->caps.has_tcl && last_clip_halfz != r300->clip_halfz) {
         r300_mark_atom_dirty(r300, &r300->vs_state);
     }
 }




More information about the mesa-commit mailing list