diff options
author | brianp <brianp> | 2000-05-05 23:49:04 +0000 |
---|---|---|
committer | brianp <brianp> | 2000-05-05 23:49:04 +0000 |
commit | 4d018a2aedcaf36ddefe0fde5f229b468cfce07d (patch) | |
tree | bad617fb2691ed0fd41919664e286e12e8059557 /xc | |
parent | 402baf7d50508a26c26dbb2c742bbe794910d29f (diff) |
fixed glDrawBuffer(GL_NONE) bug
Diffstat (limited to 'xc')
-rw-r--r-- | xc/extras/Mesa/src/FX/fxdd.c | 8 | ||||
-rw-r--r-- | xc/extras/Mesa/src/FX/fxsetup.c | 14 |
2 files changed, 16 insertions, 6 deletions
diff --git a/xc/extras/Mesa/src/FX/fxdd.c b/xc/extras/Mesa/src/FX/fxdd.c index d37943f0c..a979cad04 100644 --- a/xc/extras/Mesa/src/FX/fxdd.c +++ b/xc/extras/Mesa/src/FX/fxdd.c @@ -286,7 +286,7 @@ static GLbitfield fxDDClear(GLcontext *ctx, GLbitfield mask, GLboolean all, /* Set the buffer used for drawing */ /* XXX support for separate read/draw buffers hasn't been tested */ -static GLboolean fxDDSetDrawBuffer(GLcontext *ctx, GLenum mode ) +static GLboolean fxDDSetDrawBuffer(GLcontext *ctx, GLenum mode) { fxMesaContext fxMesa=(fxMesaContext)ctx->DriverCtx; @@ -304,6 +304,10 @@ static GLboolean fxDDSetDrawBuffer(GLcontext *ctx, GLenum mode ) FX_grRenderBuffer(fxMesa->currentFB); return GL_TRUE; } + else if (mode == GL_NONE) { + FX_grColorMask(FXFALSE,FXFALSE); + return GL_TRUE; + } else { return GL_FALSE; } @@ -943,7 +947,7 @@ static GLboolean fxIsInHardware(GLcontext *ctx) if (!ctx->Hint.AllowDrawMem) return GL_TRUE; /* you'll take it and like it */ - if((ctx->RasterMask & STENCIL_BIT) || + if((ctx->RasterMask & (STENCIL_BIT | MULTI_DRAW_BIT)) || ((ctx->Color.BlendEnabled) && (ctx->Color.BlendEquation!=GL_FUNC_ADD_EXT)) || ((ctx->Color.ColorLogicOpEnabled) && (ctx->Color.LogicOp!=GL_COPY)) || (ctx->Light.Model.ColorControl==GL_SEPARATE_SPECULAR_COLOR) || diff --git a/xc/extras/Mesa/src/FX/fxsetup.c b/xc/extras/Mesa/src/FX/fxsetup.c index e8c75b7c4..5e82443d7 100644 --- a/xc/extras/Mesa/src/FX/fxsetup.c +++ b/xc/extras/Mesa/src/FX/fxsetup.c @@ -1411,14 +1411,20 @@ static void fxSetupColorMask(GLcontext *ctx) { fxMesaContext fxMesa = FX_CONTEXT(ctx); - FX_grColorMask(ctx->Color.ColorMask[RCOMP] || - ctx->Color.ColorMask[GCOMP] || - ctx->Color.ColorMask[BCOMP], - ctx->Color.ColorMask[ACOMP] && fxMesa->haveAlphaBuffer); + if (ctx->Color.DrawBuffer == GL_NONE) { + FX_grColorMask(FXFALSE, FXFALSE); + } + else { + FX_grColorMask(ctx->Color.ColorMask[RCOMP] || + ctx->Color.ColorMask[GCOMP] || + ctx->Color.ColorMask[BCOMP], + ctx->Color.ColorMask[ACOMP] && fxMesa->haveAlphaBuffer); + } } + /************************************************************************/ /**************************** Fog Mode SetUp ****************************/ /************************************************************************/ |