ref: gl: add -glnoerr flag that enables no error context, for possible performance gains

This commit is contained in:
Alibek Omarov
2026-04-25 03:56:45 +05:00
parent 2320734ec0
commit 9898948424
+6
View File
@@ -1405,6 +1405,12 @@ void GL_SetupAttributes( int safegl )
glw_state.extended = true;
}
if( gEngfuncs.Sys_CheckParm( "-glnoerr" ))
{
gEngfuncs.Con_Reportf( "Creating a no-error GL context...\n" );
gEngfuncs.GL_SetAttribute( REF_GL_CONTEXT_NO_ERROR, 1 );
}
if( safegl > SAFE_DONTCARE )
{
safegl = -1; // can't retry anymore, can only shutdown engine