|
#define | FUNC(ret, name, params) ret (GL_CALL_CONV *p##name) params; |
|
#define | FUNC2(ret, nameARB, nameCore, version, params) ret (GL_CALL_CONV *p##nameARB) params; |
|
#define | FUNC3(ret, nameARB, nameCore, version, params) ret (GL_CALL_CONV *p##nameCore) params; |
|
#define | MATCH(known_ext) |
|
#define | FUNC(ret, name, params) p##name = (ret (GL_CALL_CONV*) params)SDL_GL_GetProcAddress(#name); |
|
#define | FUNC23(pname, ret, nameARB, nameCore, version, params) |
|
#define | FUNC2(ret, nameARB, nameCore, version, params) FUNC23(p##nameARB, ret, nameARB, nameCore, version, params) |
|
#define | FUNC3(ret, nameARB, nameCore, version, params) FUNC23(p##nameCore, ret, nameARB, nameCore, version, params) |
|
#define | E(e) case e: debug_printf("%s\n", #e); break; |
|
|
const char * | ogl_ExtensionString () |
| get a list of all supported extensions. More...
|
|
static bool | isImplementedInCore (const char *ext) |
|
bool | ogl_HaveExtension (const char *ext) |
| check if an extension is supported by the OpenGL implementation. More...
|
|
bool | ogl_HaveVersion (const char *desired_version) |
| make sure the OpenGL implementation version matches or is newer than the given version. More...
|
|
const char * | ogl_HaveExtensions (int dummy,...) |
| check if a list of extensions are all supported (as determined by ogl_HaveExtension). More...
|
|
static void GL_CALL_CONV | dummy_glDrawRangeElementsEXT (GLenum mode, GLuint, GLuint, GLsizei count, GLenum type, GLvoid *indices) |
|
static void GL_CALL_CONV | dummy_glActiveTextureARB (int) |
|
static void GL_CALL_CONV | dummy_glClientActiveTextureARB (int) |
|
static void GL_CALL_CONV | dummy_glMultiTexCoord2fARB (int, float s, float t) |
|
static void GL_CALL_CONV | dummy_glMultiTexCoord3fARB (int, float s, float t, float r) |
|
static void | enableDummyFunctions () |
|
static void | importExtensionFunctions () |
|
static void | dump_gl_error (GLenum err) |
|
void | ogl_WarnIfErrorLoc (const char *file, int line) |
| raise a warning (break into the debugger) if an OpenGL error is pending. More...
|
|
bool | ogl_SquelchError (GLenum err_to_ignore) |
| ignore and reset the specified OpenGL error. More...
|
|
void | ogl_Init () |
| initialization: import extension function pointers and do feature detect. More...
|
|
bool ogl_SquelchError |
( |
GLenum |
err_to_ignore | ) |
|
ignore and reset the specified OpenGL error.
this is useful for suppressing annoying error messages, e.g. "invalid enum" for GL_CLAMP_TO_EDGE even though we've already warned the user that their OpenGL implementation is too old.
call after the fact, i.e. the error has been raised. if another or different error is pending, those are reported immediately.
- Parameters
-
err_to_ignore | one of the glGetError enums. |
- Returns
- true if the requested error was seen and ignored
void ogl_WarnIfErrorLoc |
( |
const char * |
file, |
|
|
int |
line |
|
) |
| |
raise a warning (break into the debugger) if an OpenGL error is pending.
resets the OpenGL error state afterwards.
when an error is reported, insert calls to this in a binary-search scheme to quickly narrow down the actual error location.
reports a bogus invalid_operation error if called before OpenGL is initialized, so don't!
disabled in release mode for efficiency and to avoid annoying errors.