glActiveTexture declaration
"MindFlyer" <[email protected]>
| Newsgroups | gmane.comp.lib.sdl |
|---|---|
| Message-ID | <[email protected]> |
I am using SDL2 with CodeBlocks/MinGW/gcc, and I have a problem with glActiveTexture. If I call this function without declaring it, it says "undefined reference to `glActiveTexture@4'". If I declare it as PFNGLACTIVETEXTUREPROC glActiveTexture, it says "'glActiveTexture' redeclared as different kind of symbol".
The way I fixed it is by going into SDL_opengl.h and deleting line 2019:
GLAPI void GLAPIENTRY glActiveTextureARB(GLenum texture);
Now I do
PFNGLACTIVETEXTUREPROC glActiveTexture = (PFNGLACTIVETEXTUREPROC) SDL_GL_GetProcAddress("glActiveTexture");
and everything works fine.
But I'm pretty sure this shouldn't happen. Every other OpenGL function is either loaded automatically or I can declare it no problem. For some reason only glActiveTexture is giving me a headache.
Is this a bug with SDL2 or my OpenGL driver, or am I doing something wrong?
_______________________________________________
SDL mailing list
[email protected]
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org