- Use SDL_GL_GetProcAddress on platforms where the SDL is being used. Since SDL initialized OpenGL for us, it is the only reliable way of retrieving proc addresses.

- Check if ogl_LoadFunctions failed and make OpenGLSWFrameBuffer gracefully recover from that
This commit is contained in:
Magnus Norddahl 2017-04-07 02:17:34 +02:00 committed by Rachael Alexanderson
commit e690de25a8
2 changed files with 8 additions and 2 deletions

View file

@ -194,7 +194,11 @@ OpenGLSWFrameBuffer::OpenGLSWFrameBuffer(void *hMonitor, int width, int height,
static bool first = true;
if (first)
{
ogl_LoadFunctions();
if (ogl_LoadFunctions() == ogl_LOAD_FAILED)
{
Printf("OpenGL load failed. No OpenGL acceleration will be used.\n");
return;
}
}
gl_LoadExtensions();
InitializeState();