- Fall back to D3D for software on systems without GL2 support.

This commit is contained in:
drfrag 2019-08-13 22:04:05 +02:00
parent 9f0d5ac113
commit b3c4e24b58

View file

@ -46,6 +46,7 @@ static double realglversion; // this is public so the statistics code can access
EXTERN_CVAR(Bool, gl_legacy_mode) EXTERN_CVAR(Bool, gl_legacy_mode)
extern int currentrenderer; extern int currentrenderer;
EXTERN_CVAR(Int, vid_renderer); EXTERN_CVAR(Int, vid_renderer);
EXTERN_CVAR(Bool, vid_glswfb);
CVAR(Bool, gl_riskymodernpath, false, CVAR_ARCHIVE|CVAR_GLOBALCONFIG) CVAR(Bool, gl_riskymodernpath, false, CVAR_ARCHIVE|CVAR_GLOBALCONFIG)
//========================================================================== //==========================================================================
@ -192,9 +193,10 @@ void gl_LoadExtensions()
if ((gl_version < 2.0f || !CheckExtension("GL_EXT_framebuffer_object")) && gl_version < 3.0f) if ((gl_version < 2.0f || !CheckExtension("GL_EXT_framebuffer_object")) && gl_version < 3.0f)
{ {
vid_renderer = 0; vid_renderer = 0;
vid_glswfb = 0;
I_FatalError("Unsupported OpenGL version.\nAt least OpenGL 2.0 with framebuffer support is required to run " GAMENAME ".\nFalling back to software renderer.\n"); I_FatalError("Unsupported OpenGL version.\nAt least OpenGL 2.0 with framebuffer support is required to run " GAMENAME ".\nFalling back to software renderer.\n");
} }
gl.es = false; gl.es = false;
// add 0.01 to account for roundoff errors making the number a tad smaller than the actual version // add 0.01 to account for roundoff errors making the number a tad smaller than the actual version