mirror of https://github.com/stella-emu/stella.git
Make the 'gl_vsync' argument work with Nvidia cards under Linux. Stella
will have to be restarted for this to take effect, so it still isn't the ideal solution. git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@1359 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
This commit is contained in:
parent
9e8d75fff5
commit
bd09057d69
|
@ -13,7 +13,7 @@
|
||||||
// See the file "license" for information on usage and redistribution of
|
// See the file "license" for information on usage and redistribution of
|
||||||
// this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
// this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||||
//
|
//
|
||||||
// $Id: mainSDL.cxx,v 1.74 2007-07-27 13:49:16 stephena Exp $
|
// $Id: mainSDL.cxx,v 1.75 2007-08-25 23:57:35 stephena Exp $
|
||||||
//============================================================================
|
//============================================================================
|
||||||
|
|
||||||
#include <SDL.h>
|
#include <SDL.h>
|
||||||
|
@ -138,6 +138,15 @@ int main(int argc, char* argv[])
|
||||||
if(theOSystem->settings().getBool("center"))
|
if(theOSystem->settings().getBool("center"))
|
||||||
putenv("SDL_VIDEO_CENTERED=1");
|
putenv("SDL_VIDEO_CENTERED=1");
|
||||||
|
|
||||||
|
#ifdef BSPF_UNIX
|
||||||
|
// Nvidia cards under UNIX don't currently support SDL_GL_SWAP_CONTROL
|
||||||
|
// So we need to do it with an Nvidia-specific environment variable
|
||||||
|
// This also means the setting can only be changed by restarting Stella
|
||||||
|
// This functionality should really be integrated into SDL directly
|
||||||
|
if(theOSystem->settings().getBool("gl_vsync"))
|
||||||
|
putenv("__GL_SYNC_TO_VBLANK=1");
|
||||||
|
#endif
|
||||||
|
|
||||||
//// Main loop ////
|
//// Main loop ////
|
||||||
// First we check if a ROM is specified on the commandline. If so, and if
|
// First we check if a ROM is specified on the commandline. If so, and if
|
||||||
// the ROM actually exists, use it to create a new console.
|
// the ROM actually exists, use it to create a new console.
|
||||||
|
|
Loading…
Reference in New Issue