From: Vladimir Dergachev Date: Tue, 8 Feb 2005 04:20:40 +0000 (+0000) Subject: Let Polygon Offset be turned on and off. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=3f847b73f3f480eb823f58e73edf53c2a5317a55;p=mesa.git Let Polygon Offset be turned on and off. --- diff --git a/src/mesa/drivers/dri/r300/r300_state.c b/src/mesa/drivers/dri/r300/r300_state.c index 88318ecda44..f8d3de65d31 100644 --- a/src/mesa/drivers/dri/r300/r300_state.c +++ b/src/mesa/drivers/dri/r300/r300_state.c @@ -506,7 +506,11 @@ static void r300Enable(GLcontext* ctx, GLenum cap, GLboolean state) case GL_POLYGON_OFFSET_FILL: R300_STATECHANGE(r300, unk42B4); - r300->hw.unk42B4.cmd[1] = 3; + if(state){ + r300->hw.unk42B4.cmd[1] |= 3; + } else { + r300->hw.unk42B4.cmd[1] &= ~3; + } break; case GL_VERTEX_PROGRAM_ARB: //TCL_FALLBACK(rmesa->glCtx, R200_TCL_FALLBACK_TCL_DISABLE, state);