engine: platform: sdl: don't call SDL_GL_SetSwapInterval each frame while we're not in game
This commit is contained in:
parent
a3aaa87147
commit
f499286a87
1 changed files with 2 additions and 1 deletions
|
@ -491,7 +491,8 @@ void GL_UpdateSwapInterval( void )
|
|||
// disable VSync while level is loading
|
||||
if( cls.state < ca_active )
|
||||
{
|
||||
SDL_GL_SetSwapInterval( 0 );
|
||||
if( SDL_GL_GetSwapInterval() != 0 )
|
||||
SDL_GL_SetSwapInterval( 0 );
|
||||
SetBits( gl_vsync.flags, FCVAR_CHANGED );
|
||||
}
|
||||
else if( FBitSet( gl_vsync.flags, FCVAR_CHANGED ))
|
||||
|
|
Loading…
Add table
Reference in a new issue