diff options
| author | Manolo Gouy <Manolo> | 2018-02-07 15:34:44 +0000 |
|---|---|---|
| committer | Manolo Gouy <Manolo> | 2018-02-07 15:34:44 +0000 |
| commit | dcc82d8926e447e422f200d01e1aa990233bc16a (patch) | |
| tree | bc0d120f1381e0e8c0ef5c66262289e93d3b9a08 /FL/gl.h | |
| parent | 90630409cbe8740d2c8b66823757a4ea5441aa21 (diff) | |
STR#3450: Draw text with OpenGL using textures on all platforms.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12650 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'FL/gl.h')
| -rw-r--r-- | FL/gl.h | 21 |
1 files changed, 7 insertions, 14 deletions
@@ -3,7 +3,7 @@ // // OpenGL header file for the Fast Light Tool Kit (FLTK). // -// Copyright 1998-2011 by Bill Spitzak and others. +// Copyright 1998-2018 by Bill Spitzak and others. // // You must include this instead of GL/gl.h to get the Microsoft // APIENTRY stuff included (from <windows.h>) prior to the OpenGL @@ -28,10 +28,11 @@ * * To use OpenGL from within an FLTK application you MUST use gl_visual() * to select the default visual before doing show() on any windows. Mesa - * will crash if yoy try to use a visual not returned by glxChooseVidual. + * will crash if you try to use a visual not returned by glxChooseVisual. * - * This does not work with Fl_Double_Window's! It will try to draw - * into the front buffer. Depending on the system this will either + * Historically, this did not always work well with Fl_Double_Window's! + * It can try to draw into the front buffer. + * Depending on the system this might either * crash or do nothing (when pixmaps are being used as back buffer * and GL is being done by hardware), work correctly (when GL is done * with software, such as Mesa), or draw into the front buffer and @@ -89,16 +90,8 @@ FL_EXPORT void gl_draw(const char*, int n, int x, int y); FL_EXPORT void gl_draw(const char*, int n, float x, float y); FL_EXPORT void gl_draw(const char*, int x, int y, int w, int h, Fl_Align); FL_EXPORT void gl_measure(const char*, int& x, int& y); -#ifdef __APPLE__ // PORTME: OpenGL platform texture -extern FL_EXPORT void gl_texture_pile_height(int max); -extern FL_EXPORT int gl_texture_pile_height(); -#elif defined(WIN32) - // not needed -#elif defined(FL_PORTING) -# pragma message "FL_PORTING: define functions to control OpenGL texture pile height if supported" -#else // X11 - // not needed -#endif +FL_EXPORT void gl_texture_pile_height(int max); +FL_EXPORT int gl_texture_pile_height(); FL_EXPORT void gl_draw_image(const uchar *, int x,int y,int w,int h, int d=3, int ld=0); |
