Stereo OpenGL patch from Stuart Levy...
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2012 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
parent
ba2eae871a
commit
98c9f2cc6b
1
CHANGES
1
CHANGES
@ -1,5 +1,6 @@
|
||||
CHANGES IN FLTK 1.1.0b12
|
||||
|
||||
- Stereo OpenGL support (patch from Stuart Levy)
|
||||
- All of the convenience functions defined in fl_ask.H
|
||||
now resize the widgets and dialog window as needed for
|
||||
the labels and prompt.
|
||||
|
@ -1,5 +1,5 @@
|
||||
//
|
||||
// "$Id: Enumerations.H,v 1.18.2.14.2.19 2002/01/09 21:50:02 easysw Exp $"
|
||||
// "$Id: Enumerations.H,v 1.18.2.14.2.20 2002/03/25 16:41:01 easysw Exp $"
|
||||
//
|
||||
// Enumerations for the Fast Light Tool Kit (FLTK).
|
||||
//
|
||||
@ -361,7 +361,8 @@ enum Fl_Mode { // visual types and Fl_Gl_Window::mode() (values match Glut)
|
||||
FL_DEPTH = 16,
|
||||
FL_STENCIL = 32,
|
||||
FL_RGB8 = 64,
|
||||
FL_MULTISAMPLE= 128
|
||||
FL_MULTISAMPLE= 128,
|
||||
FL_STEREO = 256
|
||||
};
|
||||
|
||||
// damage masks
|
||||
@ -377,5 +378,5 @@ enum Fl_Damage {
|
||||
#endif
|
||||
|
||||
//
|
||||
// End of "$Id: Enumerations.H,v 1.18.2.14.2.19 2002/01/09 21:50:02 easysw Exp $".
|
||||
// End of "$Id: Enumerations.H,v 1.18.2.14.2.20 2002/03/25 16:41:01 easysw Exp $".
|
||||
//
|
||||
|
@ -1,5 +1,5 @@
|
||||
//
|
||||
// "$Id: glut.H,v 1.6.2.10.2.1 2002/01/01 15:11:28 easysw Exp $"
|
||||
// "$Id: glut.H,v 1.6.2.10.2.2 2002/03/25 16:41:01 easysw Exp $"
|
||||
//
|
||||
// GLUT emulation header file for the Fast Light Tool Kit (FLTK).
|
||||
//
|
||||
@ -106,7 +106,7 @@ FL_EXPORT void glutInitDisplayMode(unsigned int mode);
|
||||
#define GLUT_DEPTH FL_DEPTH
|
||||
#define GLUT_STENCIL FL_STENCIL
|
||||
#define GLUT_MULTISAMPLE FL_MULTISAMPLE
|
||||
// #define GLUT_STEREO 256
|
||||
#define GLUT_STEREO FL_STEREO
|
||||
// #define GLUT_LUMINANCE 512
|
||||
|
||||
FL_EXPORT void glutInitWindowPosition(int x, int y);
|
||||
@ -470,5 +470,5 @@ extern void APIENTRY glutSolidIcosahedron();
|
||||
#endif /* __glut_h__ */
|
||||
|
||||
//
|
||||
// End of "$Id: glut.H,v 1.6.2.10.2.1 2002/01/01 15:11:28 easysw Exp $".
|
||||
// End of "$Id: glut.H,v 1.6.2.10.2.2 2002/03/25 16:41:01 easysw Exp $".
|
||||
//
|
||||
|
@ -1,5 +1,5 @@
|
||||
//
|
||||
// "$Id: Fl_Gl_Choice.cxx,v 1.5.2.7.2.8 2002/01/03 08:08:21 matthiaswm Exp $"
|
||||
// "$Id: Fl_Gl_Choice.cxx,v 1.5.2.7.2.9 2002/03/25 16:41:01 easysw Exp $"
|
||||
//
|
||||
// OpenGL visual selection code for the Fast Light Tool Kit (FLTK).
|
||||
//
|
||||
@ -84,6 +84,11 @@ Fl_Gl_Choice *Fl_Gl_Choice::find(int mode, const int *alist) {
|
||||
if (mode & FL_STENCIL) {
|
||||
list[n++] = AGL_STENCIL_SIZE; list[n++] = 1;
|
||||
}
|
||||
#ifdef AGL_STEREO /* is there such a thing as AGL_STEREO? */
|
||||
if (mode & FL_STEREO) {
|
||||
list[n++] = AGL_STEREO;
|
||||
}
|
||||
#endif
|
||||
list[n] = AGL_NONE;
|
||||
blist = list;
|
||||
}
|
||||
@ -129,6 +134,9 @@ Fl_Gl_Choice *Fl_Gl_Choice::find(int mode, const int *alist) {
|
||||
if (mode & FL_STENCIL) {
|
||||
list[n++] = GLX_STENCIL_SIZE; list[n++] = 1;
|
||||
}
|
||||
if (mode & FL_STEREO) {
|
||||
list[n++] = GLX_STEREO;
|
||||
}
|
||||
#if defined(GLX_VERSION_1_1) && defined(GLX_SGIS_multisample)
|
||||
if (mode & FL_MULTISAMPLE) {
|
||||
list[n++] = GLX_SAMPLES_SGIS;
|
||||
@ -164,6 +172,7 @@ Fl_Gl_Choice *Fl_Gl_Choice::find(int mode, const int *alist) {
|
||||
if ((mode & FL_ALPHA) && !pfd.cAlphaBits) continue;
|
||||
if ((mode & FL_ACCUM) && !pfd.cAccumBits) continue;
|
||||
if ((!(mode & FL_DOUBLE)) != (!(pfd.dwFlags & PFD_DOUBLEBUFFER))) continue;
|
||||
if ((!(mode & FL_STEREO)) != (!(pfd.dwFlags & PFD_STEREO))) continue;
|
||||
if ((mode & FL_DEPTH) && !pfd.cDepthBits) continue;
|
||||
if ((mode & FL_STENCIL) && !pfd.cStencilBits) continue;
|
||||
// see if better than the one we have already:
|
||||
@ -309,5 +318,5 @@ void fl_delete_gl_context(GLContext context) {
|
||||
#endif
|
||||
|
||||
//
|
||||
// End of "$Id: Fl_Gl_Choice.cxx,v 1.5.2.7.2.8 2002/01/03 08:08:21 matthiaswm Exp $".
|
||||
// End of "$Id: Fl_Gl_Choice.cxx,v 1.5.2.7.2.9 2002/03/25 16:41:01 easysw Exp $".
|
||||
//
|
||||
|
Loading…
Reference in New Issue
Block a user