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().
This commit is contained in:
@@ -381,7 +381,7 @@ clear_buffers(GLcontext *ctx, GLbitfield buffers)
|
||||
{
|
||||
if (ctx->DrawBuffer->Name == 0) {
|
||||
/* this is a window system framebuffer */
|
||||
const GLuint *colorMask = (GLuint *) &ctx->Color.ColorMask;
|
||||
const GLuint *colorMask = (GLuint *) &ctx->Color.ColorMask[0];
|
||||
XMesaBuffer b = XMESA_BUFFER(ctx->DrawBuffer);
|
||||
const GLint x = ctx->DrawBuffer->_Xmin;
|
||||
const GLint y = ctx->DrawBuffer->_Ymin;
|
||||
|
Reference in New Issue
Block a user