aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri/r300/r300_state.c
diff options
context:
space:
mode:
authorAlex Deucher <[email protected]>2009-09-04 18:21:34 -0400
committerAlex Deucher <[email protected]>2009-09-04 18:46:15 -0400
commit60ca65c0165874bb18f1f89951da0281ee235cb3 (patch)
tree625e0afe989876883635b12623707ff434506139 /src/mesa/drivers/dri/r300/r300_state.c
parent8fd7586bcccc49a627c9dfe23653be6620b95320 (diff)
r300: Add support for GL_EXT_provoking_vertex
Diffstat (limited to 'src/mesa/drivers/dri/r300/r300_state.c')
-rw-r--r--src/mesa/drivers/dri/r300/r300_state.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/r300/r300_state.c b/src/mesa/drivers/dri/r300/r300_state.c
index 9301543d389..d4c3ecee669 100644
--- a/src/mesa/drivers/dri/r300/r300_state.c
+++ b/src/mesa/drivers/dri/r300/r300_state.c
@@ -2253,6 +2253,14 @@ static void r300InvalidateState(GLcontext * ctx, GLuint new_state)
R300_STATECHANGE(r300, zb);
}
+ if (new_state & (_NEW_LIGHT)) {
+ R300_STATECHANGE(r300, shade2);
+ if (ctx->Light.ProvokingVertex == GL_LAST_VERTEX_CONVENTION)
+ r300->hw.shade2.cmd[1] |= R300_GA_COLOR_CONTROL_PROVOKING_VERTEX_LAST;
+ else
+ r300->hw.shade2.cmd[1] &= ~R300_GA_COLOR_CONTROL_PROVOKING_VERTEX_LAST;
+ }
+
r300->radeon.NewGLState |= new_state;
}