It probably still doesn't work on some systems running GTK earlier than 3.22 and I could use some help with that.
I'm putting bits on the screen using OpenGL (because typically that is the fastest way to do so), and the code is written for OpenGL 1.3, AKA "Real GL" (because that's what I had already, and because every Linux system supports it and will until the end of time).
However, apparently GtkGLArea has other notions, and on some systems, creates a GL context that only works with... OpenGLES 2.0? OpenGL 4.3? Who can tell. If I set the "use_es" flag on the GtkGLArea, things work on those systems, but that flag was only implemented in GTK 3.22.
So, two requests:
- If you have a pre-3.22 system, and it is not working, and you can figure out how to make it work, please let me know. Possibly this involves the "create_context" callback in window.c, but I dunno.
- If you would care to rewrite my dead simple GL code that just blasts a texture onto a quad in such a way that those failing systems are happy with it, please let me know what you did. I'm guessing this means using GLSL, but since I don't know what version of the OpenGL spec is being targeted by GtkGLArea, I'm not sure.
The failing systems are absolutely capable of running OpenGL 1.3 code, because they are all capable of running XScreenSaver and that's what it uses, so GtkGLArea's requirements are baffling, particularly that they shift like the sand depending on.... distro? Video card? Who can tell.
Oh yeah, some other stuff:
Is there a way to tell GtkWindow "draw on this X11 Window ID instead of creating your own"? Asking for a friend who is a screen saver.
Is there a way to tell the compositor to respect the alpha channel of the OpenGL frame buffer, so that (as in the Mac version) the clock can have a translucent background while the foreground digits are fully opaque?
By the way, here's a rundown on the various versions of OpenGL, ask me how I know:
|OpenGL 1.0 1992:||Standardized version of SGI's "GL"|
|OpenGL 1.1 1997:||Improved texture support|
|OpenGL 1.2 1998:||Nothing interesting|
|OpenGL 1.3 2001:||Multisampling, cubemaps|
|OpenGL 1.4 2002:||Added auto-mipmapping|
|OpenGLES 1.0 2003:||Deprecated 80% of the language; fork of OpenGL 1.3|
|OpenGL 1.5 2003:||Added VBOs|
|OpenGLES 1.1 2004:||Fork of OpenGL 1.5|
|OpenGL 2.0 2004:||A political quagmire, added shader language GLSL 1.1|
|OpenGLES 2.0 2007:||Deprecated 95% of the language; fork of OpenGL 2.0; GLSL 1.20|
|OpenGL 3.0 2008:||Added FBOs, VAOs, deprecated 60% of the language|
|OpenGL 3.3 2010:||OpenGL 3.3 and OpenGL 4.0 released concurrently; 3.3 has GLSL 3.30, but 4.0 has GLSL 4.00|
|OpenGLES 3.0 2012:||Same as WebGL 2.0, but has GLSL 3.00|
|OpenGL 4.3 2012:||Superset of GLES 3.0, but has GLSL 4.30|
|Anything later:||My ignorance is blissful.|