init swrast->CurrentBuffer
authorBrian Paul <brian.paul@tungstengraphics.com>
Fri, 11 Oct 2002 17:50:59 +0000 (17:50 +0000)
committerBrian Paul <brian.paul@tungstengraphics.com>
Fri, 11 Oct 2002 17:50:59 +0000 (17:50 +0000)
src/mesa/swrast/s_context.c

index 8decd1c4a6eb9419e9c8f1d9b9decd7c1fae2298..5299bf85497ee8af7df1342921a24e638f8078ec 100644 (file)
@@ -1,4 +1,4 @@
-/* $Id: s_context.c,v 1.39 2002/10/04 17:37:46 brianp Exp $ */
+/* $Id: s_context.c,v 1.40 2002/10/11 17:50:59 brianp Exp $ */
 
 /*
  * Mesa 3-D graphics library
@@ -507,6 +507,11 @@ _swrast_CreateContext( GLcontext *ctx )
    swrast->AllowVertexFog = GL_TRUE;
    swrast->AllowPixelFog = GL_TRUE;
 
+   if (ctx->Visual.doubleBufferMode)
+      swrast->CurrentBuffer = BACK_LEFT_BIT;
+   else
+      swrast->CurrentBuffer = FRONT_LEFT_BIT;
+
    /* Optimized Accum buffer */
    swrast->_IntegerAccumMode = GL_TRUE;
    swrast->_IntegerAccumScaler = 0.0;