summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri/savage/savagestate.c
diff options
context:
space:
mode:
authorFelix Kuehling <[email protected]>2004-12-15 17:45:23 +0000
committerFelix Kuehling <[email protected]>2004-12-15 17:45:23 +0000
commit58f5b91b1bd3d329f98969c7d6c8434107b3ec6d (patch)
tree1e6e2e2de88161d4cc88c0a714277767b455bfb7 /src/mesa/drivers/dri/savage/savagestate.c
parent489ccef3982267b0d35c8548921f58d553c25a3a (diff)
Added configuration support to the Savage driver. Three options are
supported so far.
Diffstat (limited to 'src/mesa/drivers/dri/savage/savagestate.c')
-rw-r--r--src/mesa/drivers/dri/savage/savagestate.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/savage/savagestate.c b/src/mesa/drivers/dri/savage/savagestate.c
index 04d8f0870cb..f4f22602d8d 100644
--- a/src/mesa/drivers/dri/savage/savagestate.c
+++ b/src/mesa/drivers/dri/savage/savagestate.c
@@ -46,6 +46,8 @@
#include "tnl/tnl.h"
#include "swrast_setup/swrast_setup.h"
+#include "xmlpool.h"
+
static void savageBlendFunc_s4(GLcontext *);
static void savageBlendFunc_s3d(GLcontext *);
@@ -1619,7 +1621,9 @@ static void savageDDInitState_s4( savageContextPtr imesa )
imesa->regs.s4.drawLocalCtrl.ni.flushPdDestWrites= GL_TRUE;
imesa->regs.s4.drawLocalCtrl.ni.zUpdateEn= GL_TRUE;
- imesa->regs.s4.drawCtrl1.ni.ditherEn=GL_TRUE;
+ imesa->regs.s4.drawCtrl1.ni.ditherEn = (
+ driQueryOptioni(&imesa->optionCache, "color_reduction") ==
+ DRI_CONF_COLOR_REDUCTION_DITHER) ? GL_TRUE : GL_FALSE;
imesa->regs.s4.drawCtrl1.ni.cullMode = BCM_None;
imesa->regs.s4.zBufCtrl.ni.stencilRefVal = 0x00;
@@ -1684,7 +1688,9 @@ static void savageDDInitState_s3d( savageContextPtr imesa )
imesa->regs.s3d.drawCtrl.ni.flushPdZbufWrites = GL_TRUE;
imesa->regs.s3d.drawCtrl.ni.flushPdDestWrites = GL_TRUE;
- imesa->regs.s3d.drawCtrl.ni.ditherEn = GL_TRUE;
+ imesa->regs.s3d.drawCtrl.ni.ditherEn = (
+ driQueryOptioni(&imesa->optionCache, "color_reduction") ==
+ DRI_CONF_COLOR_REDUCTION_DITHER) ? GL_TRUE : GL_FALSE;
imesa->regs.s3d.drawCtrl.ni.cullMode = BCM_None;
imesa->LcsCullMode = BCM_None;