Fix SDL_GL_ACCELERATED_VISUAL on Windows in the 1.3 branch.
authorRyan C. Gordon <icculus@icculus.org>
Sun, 21 Aug 2011 12:24:27 -0400
changeset 562484d302e859d1
parent 5622 08e941dad8e9
child 5625 0a9b94c0613c
Fix SDL_GL_ACCELERATED_VISUAL on Windows in the 1.3 branch.

Fixes Bugzilla #1254.

Thanks to Thilo Schulz for the patch!
src/video/windows/SDL_windowsopengl.c
     1.1 --- a/src/video/windows/SDL_windowsopengl.c	Sun Aug 21 11:52:21 2011 -0400
     1.2 +++ b/src/video/windows/SDL_windowsopengl.c	Sun Aug 21 12:24:27 2011 -0400
     1.3 @@ -466,9 +466,11 @@
     1.4          *iAttr++ = _this->gl_config.multisamplesamples;
     1.5      }
     1.6  
     1.7 -    *iAttr++ = WGL_ACCELERATION_ARB;
     1.8 -    *iAttr++ = (_this->gl_config.accelerated ? WGL_FULL_ACCELERATION_ARB :
     1.9 -                                               WGL_NO_ACCELERATION_ARB);
    1.10 +    if ( this->gl_config.accelerated >= 0 ) {
    1.11 +        *iAttr++ = WGL_ACCELERATION_ARB;
    1.12 +        *iAttr++ = (_this->gl_config.accelerated ? WGL_FULL_ACCELERATION_ARB :
    1.13 +                                                   WGL_NO_ACCELERATION_ARB);
    1.14 +    }
    1.15  
    1.16      *iAttr = 0;
    1.17