diff src/video/wincommon/SDL_wingl.c @ 450:8a43e0cbf02f

Added SDL_GL_STEREO for stereoscopic OpenGL contexts
author Sam Lantinga <slouken@libsdl.org>
date Mon, 19 Aug 2002 17:58:08 +0000
parents c638fde8a824
children a6fa62b1be09
line wrap: on
line diff
--- a/src/video/wincommon/SDL_wingl.c	Mon Aug 19 03:40:44 2002 +0000
+++ b/src/video/wincommon/SDL_wingl.c	Mon Aug 19 17:58:08 2002 +0000
@@ -106,6 +106,9 @@
 		if ( this->gl_config.double_buffer ) {
 			GL_pfd.dwFlags |= PFD_DOUBLEBUFFER;
 		}
+		if ( this->gl_config.stereo ) {
+			GL_pfd.dwFlags |= PFD_STEREO;
+		}
 		GL_pfd.iPixelType = PFD_TYPE_RGBA;
 		GL_pfd.cColorBits = this->gl_config.buffer_size;
 		GL_pfd.cRedBits = this->gl_config.red_size;
@@ -242,6 +245,13 @@
 	    case SDL_GL_ACCUM_ALPHA_SIZE:
 		*value = GL_pfd.cAccumAlphaBits;
 		break;
+	    case SDL_GL_STEREO:
+		if ( GL_pfd.dwFlags & PFD_STEREO ) {
+			*value = 1;
+		} else {
+			*value = 0;
+		}
+		break;
 	    default:
 		retval = -1;
 		break;