summaryrefslogtreecommitdiffstats
path: root/src/mesa/swrast/s_buffers.c
diff options
context:
space:
mode:
authorJon Smirl <[email protected]>2005-05-08 05:01:03 +0000
committerJon Smirl <[email protected]>2005-05-08 05:01:03 +0000
commit5c6aec2f39e1c3bbb218ad19b5b475028125105a (patch)
tree366db093ffe48dad4b3dab4b25915ea399fb213e /src/mesa/swrast/s_buffers.c
parent86300c694501a8b2ca7c4a03f74e68af24586010 (diff)
dri fb works using renderbuffers now in RGBA mode
Diffstat (limited to 'src/mesa/swrast/s_buffers.c')
-rw-r--r--src/mesa/swrast/s_buffers.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/mesa/swrast/s_buffers.c b/src/mesa/swrast/s_buffers.c
index d2a8572e1c3..bf0e2270872 100644
--- a/src/mesa/swrast/s_buffers.c
+++ b/src/mesa/swrast/s_buffers.c
@@ -261,7 +261,8 @@ clear_color_buffers(GLcontext *ctx)
for (i = 0; i < ctx->DrawBuffer->_NumColorDrawBuffers[0]; i++) {
struct gl_renderbuffer *rb = ctx->DrawBuffer->_ColorDrawBuffers[0][i];
#if OLD_RENDERBUFFER /* this is obsolete code */
- swrast->Driver.SetBuffer(ctx, ctx->DrawBuffer,
+ if (swrast->Driver.SetBuffer)
+ swrast->Driver.SetBuffer(ctx, ctx->DrawBuffer,
ctx->DrawBuffer->_ColorDrawBit[0][i]);
#endif
@@ -426,5 +427,6 @@ _swrast_use_draw_buffer( GLcontext *ctx )
/* glDrawBuffer(GL_NONE) */
swrast->CurrentBufferBit = BUFFER_BIT_FRONT_LEFT; /* we always have this buffer */
- swrast->Driver.SetBuffer(ctx, ctx->DrawBuffer, swrast->CurrentBufferBit);
+ if (swrast->Driver.SetBuffer)
+ swrast->Driver.SetBuffer(ctx, ctx->DrawBuffer, swrast->CurrentBufferBit);
}