* We don't try and detect duplicate markers between GREMEDY and KHR_debug,
just assume the program is smart enough to detect that both are available
and pick only one to use.
* Now instead of returning NULL for entry points that we don't support and
hoping the application will handle that or error out, instead we return
a function that will log an error if it is ever called, and then pass
through to the real function. In most cases, the capture will probably be
broken as whichever function isn't saved.
* hookset.pl is much faster too, it outputs the whole gl_hookset_defs.h
file and doesn't do multiple searches over the whole set of headers in
official/ for each function.
* None of these require extra serialisation functions, but some upgraded
to DSA style serialise instead of selector serialise functions.
* There's a lot of duplication here now (expecially for MultiTex calls).
This could really do with cleanup soon.
* This won't work if the feedback is started before the captured frame then
captured inside it, either by being paused or actually active across the
SwapBuffers call.
* Note that the uniform subroutines are saved and restored by the render
state, but they are not properly restored anywhere where we fetch &
restore the current program. Will probably need a special helper class
to push/pop that correctly.
* We want the application to pass us real GLSL shaders so we can do all
kinds of juicy things to them. This is generally indicated by the program
having a LINK_STATUS of FALSE or similar, and we can pretty much get that
by just not passing through the call.
* glTexImage probably makes some assumptions about usage, at the least it
assumes that it won't be called to re-size/re-allocate textures (that
will probably break), and it also assumes that level 0 will always be
glTexImage'd and the other levels are standard mip sizes (I don't know
what happens in GL if you specify non pow-2 descending mip sizes for
different levels. Given we're only targetting core 3.2 and above, this is
probably a safe set of assumptions.