aboutsummaryrefslogtreecommitdiffstats
path: root/code/sdl/sdl_glimp.c
diff options
context:
space:
mode:
authorthilo <thilo@edf5b092-35ff-0310-97b2-ce42778d08ea>2008-04-27 19:07:57 +0000
committerthilo <thilo@edf5b092-35ff-0310-97b2-ce42778d08ea>2008-04-27 19:07:57 +0000
commit9b480854604f6d45a71d8c88a6fa21dbcdedc521 (patch)
treef8d0e9e58e54bce8a69af7910993f64b9b692e50 /code/sdl/sdl_glimp.c
parentd64880acada0a85c768b7009cc1c1451931de12c (diff)
downloadioquake3-aero-9b480854604f6d45a71d8c88a6fa21dbcdedc521.tar.gz
ioquake3-aero-9b480854604f6d45a71d8c88a6fa21dbcdedc521.zip
This may enable stereo rendering for other devices like shutter glasses, but I don't know whether this works yet.
git-svn-id: svn://svn.icculus.org/quake3/trunk@1330 edf5b092-35ff-0310-97b2-ce42778d08ea
Diffstat (limited to 'code/sdl/sdl_glimp.c')
-rw-r--r--code/sdl/sdl_glimp.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/code/sdl/sdl_glimp.c b/code/sdl/sdl_glimp.c
index b933a86..c378d5d 100644
--- a/code/sdl/sdl_glimp.c
+++ b/code/sdl/sdl_glimp.c
@@ -316,6 +316,18 @@ static int GLimp_SetMode( int mode, qboolean fullscreen )
SDL_GL_SetAttribute( SDL_GL_BLUE_SIZE, sdlcolorbits );
SDL_GL_SetAttribute( SDL_GL_DEPTH_SIZE, tdepthbits );
SDL_GL_SetAttribute( SDL_GL_STENCIL_SIZE, tstencilbits );
+
+ if(r_stereoEnabled->integer)
+ {
+ glConfig.stereoEnabled = qtrue;
+ SDL_GL_SetAttribute(SDL_GL_STEREO, 1);
+ }
+ else
+ {
+ glConfig.stereoEnabled = qfalse;
+ SDL_GL_SetAttribute(SDL_GL_STEREO, 0);
+ }
+
SDL_GL_SetAttribute( SDL_GL_DOUBLEBUFFER, 1 );
#if 0 // See http://bugzilla.icculus.org/show_bug.cgi?id=3526