Be more verbose in the case of hardware errors, in case OMC has that issue again.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@6311 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
parent
3be61ca1bc
commit
cac4c91778
1 changed files with 8 additions and 1 deletions
|
@ -240,6 +240,7 @@ qboolean GLSCR_UpdateScreen (void)
|
||||||
//gl 4.5 / GL_ARB_robustness / GL_KHR_robustness
|
//gl 4.5 / GL_ARB_robustness / GL_KHR_robustness
|
||||||
if (qglGetGraphicsResetStatus)
|
if (qglGetGraphicsResetStatus)
|
||||||
{
|
{
|
||||||
|
char *reason;
|
||||||
GLenum err = qglGetGraphicsResetStatus();
|
GLenum err = qglGetGraphicsResetStatus();
|
||||||
switch(err)
|
switch(err)
|
||||||
{
|
{
|
||||||
|
@ -249,7 +250,13 @@ qboolean GLSCR_UpdateScreen (void)
|
||||||
case GL_INNOCENT_CONTEXT_RESET: //something else broke the hardware and broke our ram
|
case GL_INNOCENT_CONTEXT_RESET: //something else broke the hardware and broke our ram
|
||||||
case GL_UNKNOWN_CONTEXT_RESET: //whodunit
|
case GL_UNKNOWN_CONTEXT_RESET: //whodunit
|
||||||
default:
|
default:
|
||||||
Con_Printf("OpenGL reset detected\n");
|
if (err == GL_GUILTY_CONTEXT_RESET)
|
||||||
|
reason = "guilty";
|
||||||
|
else if (err == GL_INNOCENT_CONTEXT_RESET)
|
||||||
|
reason = "innocent";
|
||||||
|
else
|
||||||
|
reason = "unknown";
|
||||||
|
Con_Printf("OpenGL reset detected (%s)\n", reason);
|
||||||
Sys_Sleep(3.0);
|
Sys_Sleep(3.0);
|
||||||
Cmd_ExecuteString("vid_restart", RESTRICT_LOCAL);
|
Cmd_ExecuteString("vid_restart", RESTRICT_LOCAL);
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in a new issue