struct gl_renderbuffer *rb = ctx->DrawBuffer->_ColorDrawBuffers[0][i];
#if OLD_RENDERBUFFER || NEW_RENDERBUFFER
/* SetBuffer will go away */
- swrast->Driver.SetBuffer(ctx, ctx->DrawBuffer,
- ctx->DrawBuffer->_ColorDrawBit[0][i]);
+ if (swrast->Driver.SetBuffer)
+ swrast->Driver.SetBuffer(ctx, ctx->DrawBuffer,
+ ctx->DrawBuffer->_ColorDrawBit[0][i]);
#endif
if (ctx->Visual.rgbMode) {
/* Do this so the software-emulated alpha plane span functions work! */
swrast->CurrentBufferBit = ctx->ReadBuffer->_ColorReadBufferMask;
/* Tell the device driver where to read/write spans */
- swrast->Driver.SetBuffer(ctx, ctx->ReadBuffer, swrast->CurrentBufferBit);
+ if (swrast->Driver.SetBuffer)
+ swrast->Driver.SetBuffer(ctx, ctx->ReadBuffer, swrast->CurrentBufferBit);
}
GLuint bufferBit = fb->_ColorDrawBit[output][i];
/* Set the current read/draw buffer */
swrast->CurrentBufferBit = bufferBit;
- (*swrast->Driver.SetBuffer)(ctx, ctx->DrawBuffer, bufferBit);
+ if (swrast->Driver.SetBuffer)
+ (*swrast->Driver.SetBuffer)(ctx, ctx->DrawBuffer, bufferBit);
#endif
/* make copy of incoming colors */