Browse Source

set per-context GL_DRAW_BUFFER state regardless of currently bound FBO

tags/mesa-6_5-20060712
Brian Paul 19 years ago
parent
commit
21fbdb14e9
1 changed files with 4 additions and 6 deletions
  1. 4
    6
      src/mesa/main/buffers.c

+ 4
- 6
src/mesa/main/buffers.c View File



ASSERT(output < ctx->Const.MaxDrawBuffers); ASSERT(output < ctx->Const.MaxDrawBuffers);


/* Set per-FBO state */
fb->ColorDrawBuffer[output] = buffer; fb->ColorDrawBuffer[output] = buffer;
fb->_ColorDrawBufferMask[output] = destMask; fb->_ColorDrawBufferMask[output] = destMask;

if (fb->Name == 0) {
/* Set traditional state var */
ctx->Color.DrawBuffer[output] = buffer;
}

/* not really needed, will be set later */ /* not really needed, will be set later */
fb->_NumColorDrawBuffers[output] = 0; fb->_NumColorDrawBuffers[output] = 0;

/* Set traditional state var */
ctx->Color.DrawBuffer[output] = buffer;
} }





Loading…
Cancel
Save