stw: ignore swapbuffer requests on singlebuffer
authorKeith Whitwell <keithw@vmware.com>
Tue, 9 Jun 2009 15:35:55 +0000 (16:35 +0100)
committerKeith Whitwell <keithw@vmware.com>
Tue, 9 Jun 2009 15:37:38 +0000 (16:37 +0100)
Return TRUE in this case.  Returning FALSE seems to result in
mis-rendering -- possibly opengl32.dll is trying to compensate by
doing a software blit??

src/gallium/state_trackers/wgl/shared/stw_framebuffer.c

index f27f4cda2186e75295b7f5b0482ecf7b8e9f2aba..a601fc5646b78a04512b45c2bdbf098c5fa37160 100644 (file)
@@ -380,6 +380,9 @@ stw_swap_buffers(
    if (fb == NULL)
       return FALSE;
 
+   if (!(fb->pfi->pfd.dwFlags & PFD_DOUBLEBUFFER))
+      return TRUE;
+
    pipe_mutex_lock( fb->mutex );
 
    /* If we're swapping the buffer associated with the current context