diff options
| author | Michael R Sweet <michael.r.sweet@gmail.com> | 1998-11-20 20:00:29 +0000 |
|---|---|---|
| committer | Michael R Sweet <michael.r.sweet@gmail.com> | 1998-11-20 20:00:29 +0000 |
| commit | fa39ee278fcfcc2387a935af1ff93571a6816b9a (patch) | |
| tree | fbd4e36bb198d9fc9a4958c431758485d694ff9e | |
| parent | 08954f3c640a9f6b5f089c576d7fecadb9fbbe6f (diff) | |
Changed pixel format stuff for Windows - request a minimum size of 8 bits
RGB, and added depth buffer support.
git-svn-id: file:///fltk/svn/fltk/trunk@98 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
| -rw-r--r-- | src/Fl_Gl_Choice.cxx | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/Fl_Gl_Choice.cxx b/src/Fl_Gl_Choice.cxx index 53ff47de0..94ffe31cc 100644 --- a/src/Fl_Gl_Choice.cxx +++ b/src/Fl_Gl_Choice.cxx @@ -1,5 +1,5 @@ // -// "$Id: Fl_Gl_Choice.cxx,v 1.3 1998/10/21 14:20:04 mike Exp $" +// "$Id: Fl_Gl_Choice.cxx,v 1.4 1998/11/20 20:00:29 mike Exp $" // // OpenGL visual selection code for the Fast Light Tool Kit (FLTK). // @@ -105,8 +105,8 @@ Fl_Gl_Choice *Fl_Gl_Choice::find(int mode, const int *alist) { PIXELFORMATDESCRIPTOR pfd = { sizeof(PIXELFORMATDESCRIPTOR), 1, - PFD_DRAW_TO_WINDOW | PFD_SUPPORT_OPENGL /*| PFD_DEPTH_DONTCARE*/, - PFD_TYPE_RGBA, 24 }; + PFD_DRAW_TO_WINDOW | PFD_SUPPORT_OPENGL, + PFD_TYPE_RGBA, 8 }; if (mode & FL_INDEX) { pfd.iPixelType = PFD_TYPE_COLORINDEX; @@ -115,12 +115,12 @@ Fl_Gl_Choice *Fl_Gl_Choice::find(int mode, const int *alist) { if (mode & FL_ALPHA) pfd.cAlphaBits = 8; if (mode & FL_ACCUM) { pfd.cAccumBits = 6; // Wonko: I didn't find any documentation on those bits - pfd.cAccumGreenBits = 1;// Wonko: They don't seem to get anny support yet (4/98) + pfd.cAccumGreenBits = 1; // Wonko: They don't seem to get any support yet (4/98) if (mode & FL_ALPHA) pfd.cAccumAlphaBits = 1; } } if (mode & FL_DOUBLE) pfd.dwFlags |= PFD_DOUBLEBUFFER; - // if (!(mode & FL_DEPTH)) pfd.dwFlags = PFD_DEPTH_DONTCARE; + if (mode & FL_DEPTH) pfd.cDepthBits = 16; if (mode & FL_STENCIL) pfd.cStencilBits = 1; pfd.bReserved = 1; // always ask for overlay @@ -179,5 +179,5 @@ HDC fl_private_dc(Fl_Window* w, int mode, Fl_Gl_Choice **gp) { #endif // -// End of "$Id: Fl_Gl_Choice.cxx,v 1.3 1998/10/21 14:20:04 mike Exp $". +// End of "$Id: Fl_Gl_Choice.cxx,v 1.4 1998/11/20 20:00:29 mike Exp $". // |
