diff options
-rw-r--r-- | backends/graphics/opengl/gltexture.h | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/backends/graphics/opengl/gltexture.h b/backends/graphics/opengl/gltexture.h index 944cdf221c..c5a06bbc54 100644 --- a/backends/graphics/opengl/gltexture.h +++ b/backends/graphics/opengl/gltexture.h @@ -36,11 +36,16 @@ #include <GLES/gl.h> #elif defined(MACOSX) #include <OpenGL/gl.h> -#elif defined(WIN32) -#include <GL/gl.h> -#include <GL/glext.h> #else + #include <GL/gl.h> +#if defined(SDL_BACKEND) && !defined(GL_VERSION_1_2) +// The OpenGL libraries included in Windows are for OpenGL 1.1. Use the SDL +// OpenGL header file to enable the additional needed defines for OpenGL 1.2 +// here. +#include <SDL_opengl.h> +#endif + #endif #include "graphics/surface.h" |