From c8b7ec2dd66ed0a5fc29d4277f7e63a807012b88 Mon Sep 17 00:00:00 2001 From: zakk Date: Sat, 13 Jun 2009 22:00:28 +0000 Subject: See here: http://bugzilla.icculus.org/show_bug.cgi?id=4064 git-svn-id: svn://svn.icculus.org/quake3/trunk@1573 edf5b092-35ff-0310-97b2-ce42778d08ea --- code/sdl/sdl_glimp.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'code/sdl') diff --git a/code/sdl/sdl_glimp.c b/code/sdl/sdl_glimp.c index f1df177..0b143d7 100644 --- a/code/sdl/sdl_glimp.c +++ b/code/sdl/sdl_glimp.c @@ -208,6 +208,7 @@ static int GLimp_SetMode( int mode, qboolean fullscreen ) int sdlcolorbits; int colorbits, depthbits, stencilbits; int tcolorbits, tdepthbits, tstencilbits; + int samples; int i = 0; SDL_Surface *vidscreen = NULL; Uint32 flags = SDL_OPENGL; @@ -270,6 +271,7 @@ static int GLimp_SetMode( int mode, qboolean fullscreen ) else depthbits = r_depthbits->value; stencilbits = r_stencilbits->value; + samples = r_ext_multisample->value; for (i = 0; i < 16; i++) { @@ -337,6 +339,9 @@ static int GLimp_SetMode( int mode, qboolean fullscreen ) SDL_GL_SetAttribute( SDL_GL_DEPTH_SIZE, tdepthbits ); SDL_GL_SetAttribute( SDL_GL_STENCIL_SIZE, tstencilbits ); + SDL_GL_SetAttribute( SDL_GL_MULTISAMPLEBUFFERS, samples ? 1 : 0 ); + SDL_GL_SetAttribute( SDL_GL_MULTISAMPLESAMPLES, samples ); + if(r_stereoEnabled->integer) { glConfig.stereoEnabled = qtrue; @@ -674,6 +679,7 @@ void GLimp_Init( void ) { ri.Printf( PRINT_ALL, "Setting r_mode %d failed, falling back on r_mode %d\n", r_mode->integer, R_MODE_FALLBACK ); + ri.Cvar_Set("r_ext_multisample", "0"); if( !GLimp_StartDriverAndSetMode( R_MODE_FALLBACK, r_fullscreen->integer ) ) success = qfalse; } -- cgit v1.2.3