summaryrefslogtreecommitdiff
path: root/src/drivers/OpenGL
diff options
context:
space:
mode:
authorManolo Gouy <Manolo>2018-10-31 12:45:51 +0000
committerManolo Gouy <Manolo>2018-10-31 12:45:51 +0000
commit6c8115ee9b30a89724df122c0af20c24ac6cfe52 (patch)
treee9142b3a91954f2ca61c3a49fb855af7f6198909 /src/drivers/OpenGL
parent22bcc7b4cacee37be4e0559c84c848d1f6b1daf6 (diff)
Remove use of Fl_Gl_Window_Driver.H in file src/Fl_cocoa.mm
Thus, Fl_cocoa.mm is completely independent from code of libfltk_gl. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@13104 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/drivers/OpenGL')
-rw-r--r--src/drivers/OpenGL/Fl_OpenGL_Display_Device.cxx7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/drivers/OpenGL/Fl_OpenGL_Display_Device.cxx b/src/drivers/OpenGL/Fl_OpenGL_Display_Device.cxx
index a51788018..3035ff94c 100644
--- a/src/drivers/OpenGL/Fl_OpenGL_Display_Device.cxx
+++ b/src/drivers/OpenGL/Fl_OpenGL_Display_Device.cxx
@@ -39,6 +39,7 @@ Fl_OpenGL_Display_Device::Fl_OpenGL_Display_Device(Fl_OpenGL_Graphics_Driver *gr
#ifdef FL_CFG_GFX_QUARTZ
#include "../../Fl_Gl_Window_Driver.H"
+#include "../Cocoa/Fl_Cocoa_Window_Driver.H"
// convert BGRA to RGB and also exchange top and bottom
static uchar *convert_BGRA_to_RGB(uchar *baseAddress, int w, int h, int mByteWidth)
@@ -68,8 +69,8 @@ Fl_RGB_Image* Fl_OpenGL_Display_Device::capture_gl_rectangle(Fl_Gl_Window* glw,
if (factor != 1) {
w *= factor; h *= factor; x *= factor; y *= factor;
}
- Fl_Cocoa_Gl_Window_Driver::GLcontext_makecurrent(glw->context());
- Fl_Cocoa_Gl_Window_Driver::flush_context(glw->context()); // to capture also the overlay and for directGL demo
+ Fl_Cocoa_Window_Driver::GLcontext_makecurrent(glw->context());
+ Fl_Cocoa_Window_Driver::flush_context(glw->context()); // to capture also the overlay and for directGL demo
// Read OpenGL context pixels directly.
// For extra safety, save & restore OpenGL states that are changed
glPushClientAttrib(GL_CLIENT_PIXEL_STORE_BIT);
@@ -87,7 +88,7 @@ Fl_RGB_Image* Fl_OpenGL_Display_Device::capture_gl_rectangle(Fl_Gl_Window* glw,
baseAddress = convert_BGRA_to_RGB(baseAddress, w, h, mByteWidth);
Fl_RGB_Image *img = new Fl_RGB_Image(baseAddress, w, h, 3, 3 * w);
img->alloc_array = 1;
- Fl_Cocoa_Gl_Window_Driver::flush_context(glw->context());
+ Fl_Cocoa_Window_Driver::flush_context(glw->context());
return img;
}