Changeset 2526 for trunk/src/gdi32/opengl.cpp
- Timestamp:
- Jan 27, 2000, 12:20:00 AM (26 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/gdi32/opengl.cpp
r526 r2526 1 /* $Id: opengl.cpp,v 1. 4 1999-08-17 13:28:36 phallerExp $ */1 /* $Id: opengl.cpp,v 1.5 2000-01-26 23:19:55 sandervl Exp $ */ 2 2 3 3 /* … … 33 33 typedef BOOL (* WIN32API SETPIXELFMT) (HDC, int, CONST PIXELFORMATDESCRIPTOR *); 34 34 typedef BOOL (* WIN32API SWAPBUFFERS) (HDC hdc); 35 // JVDH MOD STARTS 36 typedef int (* WIN32API DESCRIBEPIXELFMT) (HDC, int, UINT, LPPIXELFORMATDESCRIPTOR); 37 // JVDH MOD ENDS 35 38 36 39 … … 39 42 ****************************************************************************/ 40 43 41 static CHOOSEPIXELFMT glChoosePixelFormat = NULL; 42 static SETPIXELFMT glSetPixelFormat = NULL; 43 static SWAPBUFFERS glSwapBuffers = NULL; 44 static HINSTANCE hOpenGL = NULL; 44 static CHOOSEPIXELFMT glChoosePixelFormat = NULL; 45 static SETPIXELFMT glSetPixelFormat = NULL; 46 static SWAPBUFFERS glSwapBuffers = NULL; 47 // JVDH MOD STARTS 48 static DESCRIBEPIXELFMT glDescribePixelFormat = NULL; 49 // JVDH MOD ENDS 50 static HINSTANCE hOpenGL = NULL; 45 51 46 52 … … 84 90 } 85 91 86 return(TRUE); /* OpenGL is initialized and enabled */ 92 // JVDH MOD STARTS 93 if(glDescribePixelFormat == NULL) { 94 glDescribePixelFormat = (DESCRIBEPIXELFMT)O32_GetProcAddress(hOpenGL, "OS2wglDescribePixelFormat"); 95 if(glDescribePixelFormat == NULL) 96 return(FALSE); 97 } 98 // JVDH MOD ENDS 99 100 return(TRUE); /* OpenGL is initialized and enabled*/ 87 101 } 88 102 … … 110 124 111 125 return(glChoosePixelFormat(hdc, pformat)); 126 } 127 128 ODINFUNCTION4(int,DescribePixelFormat,HDC,hdc, 129 int,iFormat, 130 UINT,nBytes, 131 LPPIXELFORMATDESCRIPTOR,pformat) 132 { 133 if (glDescribePixelFormat == NULL) 134 if (internalOpenGLEnable() == FALSE) 135 return(0); 136 137 return(glDescribePixelFormat(hdc, iFormat, nBytes, pformat)); 112 138 } 113 139
Note:
See TracChangeset
for help on using the changeset viewer.