Home of the best OpenGL headers in the world.
This is a really simple script-driven tool for importing OpenGL and extension functions. It is focused on OpenGL core profile, a setup with no deprecated functions. But it isn't limited to it. We used it to generate headers for our OpenGL ES 2.0 emulator. In fact, it is similar to GLEW, but it has some neat advantages.
Headers generated using GLEH contain OpenGL function documentation, which is very helpful at times.
Also, it does support intellisense (see the image above), which is quite cool if you're so forgetful and lazy like me.
It has quite an unique feature called GLACH (GL AutoCheck), which transparently inserts OpenGL error checking after each OpenGL command. It may seem like a terrible overhead, and in fact, debug code gets slower on high CPU load (because of CPU-GPU synchronization), but it enables you to write code without any error checking in release, which makes it faster (error reporting on target machine is disabled in driver settings by default anyway - so why bother). In case an OpenGL error occurs, it throws an exception (several other options such as user breakpoint are also available) with error code (such as GL_INVALID_OPERATION), file and line where the error occured in the source code, and the name of OpenGL function where the error occured. Enabling GL_TEXTURE_2D_ARRAY (which is illegal) may look like this:
GL_AUTOCHECK: file 'e:\my-job-today\gl4demo\main.cpp', line 75, function glEnable(): GL_INVALID_ENUM Press any key to continue . . .
Autocheck can be enabled or disabled using a macro, by default it is present in debug and stripped in release, but any behavior is possible.
And last, but not least, GLEH does have a snappy name.
The headers are generated automatically from extensions from OpenGL extension registry, so it is very easy to add new extensions. The documentation is downloaded and parsed from OpenGL man pages. The only downside with this is there are sometimes errors in the documentation files, or sometimes the specification and documentation doesn't agree on function parameter names so it may be necessary to edit the downloaded files here and there. But the parser reports all the errors and oddities so it is rather easy to avoid (most of the) mistakes.
status: functional, under development
os: os independent
|version||changes from previous version|
Have the following extensions:
Improved autocheck so the debugger points to a line in user's source code where the error occured, not in gl4.h (see the image below).
Output files do not contain any tabs now (only spaces), so there should be no problem displaying the files in editors that do not set 4 spaces per tab. Added support for automatic space-to-tab conversion (can set number of spaces per tab, or disable the conversion).
Fixed OpenGL 4.1 / GL_ARB_viewport_array (the *Indexed() functions are not supported by NVidia driver, but they can be replaced by the *i() functions). See GL_ARB_viewport_array, look for issue 5 ("Why glViewportIndex rather than glEnablei, and so on?").
Optimized the code (gl4.cpp / .h) to reduce compilation time.
Added the following extensions:
Added support for OpenGL ES 2.0 (a different header compilation target).
Added OpenGL 4.3 core extensions:
Changed features with respect to the deprecation model:
Added support for OpenGL 4.4, specifically added:
Added non-core extensions:
Fixed some minor commenting issues, added documentation for more functions.
Improved GLACH shows bugs in user's source and not in gl4.h now.
|version||release date||file||release notes|
|v10||2011-07-18||OpenGL40_nolame_2011-07-18_.zip||headers for OpenGL 4.1 core and extensions above|
|v10||2011-07-18||OpenGL_ExtensionCompiler_v10_2011-07-18_.zip||extension compiler tool|
|v11||2011-07-20||OpenGL40_nolame_2011-07-20_.zip||headers for OpenGL 4.1 core and extensions above|
|v11||2011-07-20||OpenGL_ExtensionCompiler_v11_2011-07-20_.zip||extension compiler tool|
|v12||2011-08-09||OpenGL40_nolame_2011-08-09_.zip||headers for OpenGL 4.2 core and extensions above|
|v12||2011-08-09||OpenGL_ExtensionCompiler_v12_2011-08-09_.zip||extension compiler tool|
|v13||2011-10-26||OpenGL_ExtensionCompiler_v13_2011-10-26_gles-support_.zip||extension compiler tool|
|v15||2014-05-07||OpenGL40_nolame_2014-05-07_.zip||headers for OpenGL 4.4 core and extensions above|
|v15||2014-05-07||OpenGL_ExtensionCompiler_v15_2014-05-07_added-gl44_.zip||extension compiler tool|