From cc5ceb1165735b532779503267ea8a7186c70c9b Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Fri, 4 Aug 2017 13:06:56 -0700 Subject: [PATCH] Temporary hack to fix bug 3725 - Call made to glGetString before context creation This breaks bugs 2570, 3145 --- src/video/SDL_video.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/video/SDL_video.c b/src/video/SDL_video.c index 89524defe..d1e7b278c 100644 --- a/src/video/SDL_video.c +++ b/src/video/SDL_video.c @@ -2916,6 +2916,8 @@ SDL_GL_ExtensionSupported(const char *extension) void SDL_GL_DeduceMaxSupportedESProfile(int* major, int* minor) { +/* This function breaks games because OpenGL functions are being called before a context is current - see bug 3725 */ +#if 0 #if SDL_VIDEO_OPENGL || SDL_VIDEO_OPENGL_ES || SDL_VIDEO_OPENGL_ES2 /* XXX This is fragile; it will break in the event of release of * new versions of OpenGL ES. @@ -2934,6 +2936,10 @@ SDL_GL_DeduceMaxSupportedESProfile(int* major, int* minor) *minor = 0; } #endif +#else + *major = 2; + *minor = 0; +#endif /* 0 */ } void