glxewInit and wglewInit for non-MX mode.

This commit is contained in:
Nigel Stewart 2015-08-07 17:04:27 +10:00
parent d4a0a8401c
commit 470652935c
4 changed files with 10 additions and 6 deletions

View File

@ -12,7 +12,11 @@ GLboolean glxewGetExtension (const char* name)
return _glewSearchExtension(name, start, end); return _glewSearchExtension(name, start, end);
} }
#ifdef GLEW_MX
GLenum glxewContextInit (GLXEW_CONTEXT_ARG_DEF_LIST) GLenum glxewContextInit (GLXEW_CONTEXT_ARG_DEF_LIST)
#else
GLenum glxewInit (GLXEW_CONTEXT_ARG_DEF_LIST)
#endif
{ {
int major, minor; int major, minor;
const GLubyte* extStart; const GLubyte* extStart;

View File

@ -20,7 +20,11 @@ GLboolean GLEWAPIENTRY wglewGetExtension (const char* name)
return _glewSearchExtension(name, start, end); return _glewSearchExtension(name, start, end);
} }
#ifdef GLEW_MX
GLenum GLEWAPIENTRY wglewContextInit (WGLEW_CONTEXT_ARG_DEF_LIST) GLenum GLEWAPIENTRY wglewContextInit (WGLEW_CONTEXT_ARG_DEF_LIST)
#else
GLenum GLEWAPIENTRY wglewInit (WGLEW_CONTEXT_ARG_DEF_LIST)
#endif
{ {
GLboolean crippled; GLboolean crippled;
const GLubyte* extStart; const GLubyte* extStart;

View File

@ -14,11 +14,9 @@ GLEWAPI GLboolean GLEWAPIENTRY glxewContextIsSupported (const GLXEWContext *ctx,
#else /* GLEW_MX */ #else /* GLEW_MX */
GLEWAPI GLenum GLEWAPIENTRY glxewContextInit (); GLEWAPI GLenum GLEWAPIENTRY glxewInit ();
GLEWAPI GLboolean GLEWAPIENTRY glxewIsSupported (const char *name); GLEWAPI GLboolean GLEWAPIENTRY glxewIsSupported (const char *name);
#define glxewInit() glxewContextInit()
#define GLXEW_GET_VAR(x) (*(const GLboolean*)&x) #define GLXEW_GET_VAR(x) (*(const GLboolean*)&x)
#define GLXEW_GET_FUN(x) x #define GLXEW_GET_FUN(x) x

View File

@ -14,11 +14,9 @@ GLEWAPI GLboolean GLEWAPIENTRY wglewContextIsSupported (const WGLEWContext *ctx,
#else /* GLEW_MX */ #else /* GLEW_MX */
GLEWAPI GLenum GLEWAPIENTRY wglewContextInit (); GLEWAPI GLenum GLEWAPIENTRY wglewInit ();
GLEWAPI GLboolean GLEWAPIENTRY wglewIsSupported (const char *name); GLEWAPI GLboolean GLEWAPIENTRY wglewIsSupported (const char *name);
#define wglewInit() wglewContextInit()
#define WGLEW_GET_VAR(x) (*(const GLboolean*)&x) #define WGLEW_GET_VAR(x) (*(const GLboolean*)&x)
#define WGLEW_GET_FUN(x) x #define WGLEW_GET_FUN(x) x