Author: manolo
Date: 2010-03-27 23:58:39 -0700 (Sat, 27 Mar 2010)
New Revision: 7348
Log:
Fl_Gl_Device_Plugin: better code for GL window capture after coverage by print 
dialog windows

Modified:
   branches/branch-1.3/src/Fl_Gl_Device_Plugin.cxx

Modified: branches/branch-1.3/src/Fl_Gl_Device_Plugin.cxx
===================================================================
--- branches/branch-1.3/src/Fl_Gl_Device_Plugin.cxx     2010-03-27 16:35:14 UTC 
(rev 7347)
+++ branches/branch-1.3/src/Fl_Gl_Device_Plugin.cxx     2010-03-28 06:58:39 UTC 
(rev 7348)
@@ -58,13 +58,15 @@
   Fl_Window *win = (Fl_Window*)glw;
   while( win->window() ) win = win->window();
   win->redraw();
+  Fl::check();
+  glw->make_current();
 #else
+  glw->make_current();
   glw->redraw();
+  glFlush();
+  Fl::check();
+  glFinish();
 #endif
-  Fl::check();
-  glw->make_current();
-  // select front buffer as our source for pixel data
-  glReadBuffer(GL_FRONT);
   // Read OpenGL context pixels directly.
   // For extra safety, save & restore OpenGL states that are changed
   glPushClientAttrib(GL_CLIENT_PIXEL_STORE_BIT);

_______________________________________________
fltk-commit mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk-commit

Reply via email to