From fd5511d27fc44096117c47ab503fb5b47f993061 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Tue, 29 Dec 2009 16:17:14 -0700 Subject: mesa: implement per-buffer color masking This is part of the GL_EXT_draw_buffers2 extension and part of GL 3.0. The ctx->Color.ColorMask field is now a 2-D array. Until drivers are modified to support per-buffer color masking, they can just look at the 0th color mask. The new _mesa_ColorMaskIndexed() function will be called by glColorMaskIndexedEXT() or glColorMaski(). --- src/mesa/drivers/dri/r128/r128_state.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/mesa/drivers/dri/r128') diff --git a/src/mesa/drivers/dri/r128/r128_state.c b/src/mesa/drivers/dri/r128/r128_state.c index 4ae7bf5b97d..ac175d59ec3 100644 --- a/src/mesa/drivers/dri/r128/r128_state.c +++ b/src/mesa/drivers/dri/r128/r128_state.c @@ -702,10 +702,10 @@ static void r128UpdateMasks( GLcontext *ctx ) r128ContextPtr rmesa = R128_CONTEXT(ctx); GLuint mask = r128PackColor( rmesa->r128Screen->cpp, - ctx->Color.ColorMask[RCOMP], - ctx->Color.ColorMask[GCOMP], - ctx->Color.ColorMask[BCOMP], - ctx->Color.ColorMask[ACOMP] ); + ctx->Color.ColorMask[0][RCOMP], + ctx->Color.ColorMask[0][GCOMP], + ctx->Color.ColorMask[0][BCOMP], + ctx->Color.ColorMask[0][ACOMP] ); if ( rmesa->setup.plane_3d_mask_c != mask ) { rmesa->setup.plane_3d_mask_c = mask; -- cgit v1.2.3