Mercurial > fife-parpg
changeset 59:129d3dafd3a5
fix initialization of opengl, SDL_GL_DOUBLEBUFFER was accidently used as flag for SDL_SetVideoMode, instead it has to be used with SDL_GL_SetAttribute, thanks to austin_, who reported that.
author | spq@33b003aa-7bff-0310-803a-e67f0ece8222 |
---|---|
date | Tue, 15 Jul 2008 15:34:47 +0000 |
parents | 9ec572a5a944 |
children | 1de7e6740a4a |
files | engine/core/video/opengl/renderbackendopengl.cpp |
diffstat | 1 files changed, 2 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/engine/core/video/opengl/renderbackendopengl.cpp Mon Jul 14 16:39:27 2008 +0000 +++ b/engine/core/video/opengl/renderbackendopengl.cpp Tue Jul 15 15:34:47 2008 +0000 @@ -57,6 +57,7 @@ Uint32 flags = SDL_INIT_VIDEO; if (SDL_InitSubSystem(flags) < 0) throw SDLException(SDL_GetError()); + SDL_GL_SetAttribute(SDL_GL_DOUBLEBUFFER, 1); SDL_EnableKeyRepeat(SDL_DEFAULT_REPEAT_DELAY, SDL_DEFAULT_REPEAT_INTERVAL); // temporary hack } @@ -65,7 +66,7 @@ delete m_screen; m_screen = 0; - Uint32 flags = SDL_OPENGL | SDL_GL_DOUBLEBUFFER | SDL_HWPALETTE | SDL_HWACCEL; + Uint32 flags = SDL_OPENGL | SDL_HWPALETTE | SDL_HWACCEL; if ( fs ) { flags |= SDL_FULLSCREEN; }