38 #elif defined(__APPLE__) && !defined(GLEW_APPLE_GLX)
46 # define glewGetContext() (&_glewctx)
48 WGLEWContext _wglewctx;
49 # define wglewGetContext() (&_wglewctx)
50 # elif !defined(__APPLE__) || defined(GLEW_APPLE_GLX)
51 GLXEWContext _glxewctx;
52 # define glxewGetContext() (&_glxewctx)
56 typedef struct GLContextStruct
62 #elif defined(__APPLE__) && !defined(GLEW_APPLE_GLX)
91 main (
int argc,
char** argv)
101 fprintf(stderr,
"Usage: visualinfo [-a] [-s] [-h] [-pf <id>]\n");
102 fprintf(stderr,
" -a: show all visuals\n");
103 fprintf(stderr,
" -s: display to stdout instead of visualinfo.txt\n");
104 fprintf(stderr,
" -pf <id>: use given pixelformat\n");
105 fprintf(stderr,
" -h: this screen\n");
107 fprintf(stderr,
"Usage: visualinfo [-h] [-display <display>] [-visual <id>]\n");
108 fprintf(stderr,
" -h: this screen\n");
109 fprintf(stderr,
" -display <display>: use given display\n");
110 fprintf(stderr,
" -visual <id>: use given visual\n");
120 fprintf(stderr,
"Error: CreateContext failed\n");
132 # elif !defined(__APPLE__) || defined(GLEW_APPLE_GLX)
149 file = fopen(
"visualinfo.txt",
"w");
162 fprintf(
file,
"OpenGL extensions (GL_): \n");
168 fprintf(
file,
"GLU extensions (GLU_): \n");
178 fprintf(
file,
"WGL extensions (WGL_): \n");
183 #elif defined(__APPLE__) && !defined(GLEW_APPLE_GLX)
187 fprintf(
file,
"GLX extensions (GLX_): \n");
218 if (*(s+1) !=
'\0') {
231 fprintf(
file,
" %s\n", t);
239 fprintf(
file,
" %s.\n", t);
249 int attrib[32],
value[32], n_attrib, n_pbuffer=0, n_float=0;
303 n_pbuffer = n_attrib;
316 fprintf(
file,
" +-----+-------------------------+-----------------+----------+-----------------+----------+\n");
317 fprintf(
file,
" | | visual | color | ax dp st | accum | layer |\n");
318 fprintf(
file,
" | id | tp ac gd fm db sw st ms | sz r g b a | bf th cl | sz r g b a | ov un sw |\n");
319 fprintf(
file,
" +-----+-------------------------+-----------------+----------+-----------------+----------+\n");
321 for(i = 1; i <= maxpf; i++)
325 if (!value[0])
continue;
328 && ((value[2] && !value[1])
333 fprintf(
file,
" |% 4d | ", i);
338 else fprintf(
file,
"wn ");
342 if (value[2]) fprintf(
file,
"bm ");
350 fprintf(
file,
" %c ", value[25] ?
'y' :
'.');
357 else fprintf(
file,
" ? ");
359 fprintf(
file,
" %c ", value[5] ?
'y' :
'.');
364 else fprintf(
file,
" . ");
366 fprintf(
file,
" %c ", value[6] ?
'y' :
'.');
369 fprintf(
file,
"%2d | ", value[24]);
371 fprintf(
file,
" . | ");
373 if (value[8]) fprintf(
file,
"%3d ", value[8]);
374 else fprintf(
file,
" . ");
376 if (value[9]) fprintf(
file,
"%2d ", value[9]);
377 else fprintf(
file,
" . ");
379 if (value[10]) fprintf(
file,
"%2d ", value[10]);
380 else fprintf(
file,
" . ");
382 if (value[11]) fprintf(
file,
"%2d ", value[11]);
383 else fprintf(
file,
" . ");
385 if (value[12]) fprintf(
file,
"%2d | ", value[12]);
386 else fprintf(
file,
" . | ");
388 if (value[20]) fprintf(
file,
"%2d ", value[20]);
389 else fprintf(
file,
" . ");
391 if (value[18]) fprintf(
file,
"%2d ", value[18]);
392 else fprintf(
file,
" . ");
394 if (value[19]) fprintf(
file,
"%2d | ", value[19]);
395 else fprintf(
file,
" . | ");
397 if (value[13]) fprintf(
file,
"%3d ", value[13]);
398 else fprintf(
file,
" . ");
400 if (value[14]) fprintf(
file,
"%2d ", value[14]);
401 else fprintf(
file,
" . ");
403 if (value[15]) fprintf(
file,
"%2d ", value[15]);
404 else fprintf(
file,
" . ");
406 if (value[16]) fprintf(
file,
"%2d ", value[16]);
407 else fprintf(
file,
" . ");
409 if (value[17]) fprintf(
file,
"%2d | ", value[17]);
410 else fprintf(
file,
" . | ");
412 if (value[21]) fprintf(
file,
"%2d ", value[21]);
413 else fprintf(
file,
" . ");
415 if (value[22]) fprintf(
file,
"%2d ", value[22]);
416 else fprintf(
file,
" . ");
418 if (value[23]) fprintf(
file,
"y ");
419 else fprintf(
file,
" . ");
420 fprintf(
file,
"|\n");
423 fprintf(
file,
" +-----+-------------------------+-----------------+----------+-----------------+----------+\n");
424 fprintf(
file,
" | | visual | color | ax dp st | accum | layer |\n");
425 fprintf(
file,
" | id | tp ac gd fm db sw st ms | sz r g b a | bf th cl | sz r g b a | ov un sw |\n");
426 fprintf(
file,
" +-----+-------------------------+-----------------+----------+-----------------+----------+\n");
433 for(i = 1; i <= maxpf; i++)
435 DescribePixelFormat(ctx->dc, i,
sizeof(PIXELFORMATDESCRIPTOR), &pfd);
437 if(!(pfd.dwFlags & PFD_SUPPORT_OPENGL)
438 || (
drawableonly && !(pfd.dwFlags & PFD_DRAW_TO_WINDOW)))
continue;
439 fprintf(
file,
"Visual ID: %2d depth=%d class=%s\n", i, pfd.cDepthBits,
440 pfd.cColorBits <= 8 ?
"PseudoColor" :
"TrueColor");
441 fprintf(
file,
" bufferSize=%d level=%d renderType=%s doubleBuffer=%d stereo=%d\n", pfd.cColorBits, pfd.bReserved, pfd.iPixelType == PFD_TYPE_RGBA ?
"rgba" :
"ci", pfd.dwFlags & PFD_DOUBLEBUFFER, pfd.dwFlags & PFD_STEREO);
442 fprintf(
file,
" generic=%d generic accelerated=%d\n", (pfd.dwFlags & PFD_GENERIC_FORMAT) == PFD_GENERIC_FORMAT, (pfd.dwFlags & PFD_GENERIC_ACCELERATED) == PFD_GENERIC_ACCELERATED);
443 fprintf(
file,
" rgba: redSize=%d greenSize=%d blueSize=%d alphaSize=%d\n", pfd.cRedBits, pfd.cGreenBits, pfd.cBlueBits, pfd.cAlphaBits);
444 fprintf(
file,
" auxBuffers=%d depthSize=%d stencilSize=%d\n", pfd.cAuxBuffers, pfd.cDepthBits, pfd.cStencilBits);
445 fprintf(
file,
" accum: redSize=%d greenSize=%d blueSize=%d alphaSize=%d\n", pfd.cAccumRedBits, pfd.cAccumGreenBits, pfd.cAccumBlueBits, pfd.cAccumAlphaBits);
446 fprintf(
file,
" multiSample=%d multisampleBuffers=%d\n", 0, 0);
447 fprintf(
file,
" Opaque.\n");
457 PIXELFORMATDESCRIPTOR pfd;
461 maxpf = DescribePixelFormat(ctx->dc, 1, 0,
NULL);
465 fprintf(
file,
"-----------------------------------------------------------------------------\n");
466 fprintf(
file,
" visual x bf lv rg d st ge ge r g b a ax dp st accum buffs ms \n");
467 fprintf(
file,
" id dep tp sp sz l ci b ro ne ac sz sz sz sz bf th cl sz r g b a ns b\n");
468 fprintf(
file,
"-----------------------------------------------------------------------------\n");
471 for(i = 1; i <= maxpf; i++)
473 DescribePixelFormat(ctx->dc, i,
sizeof(PIXELFORMATDESCRIPTOR), &pfd);
475 if(!(pfd.dwFlags & PFD_SUPPORT_OPENGL)
476 || (
drawableonly && (pfd.dwFlags & PFD_DRAW_TO_BITMAP)))
continue;
494 fprintf(
file,
"0x%02x ", i);
495 fprintf(
file,
"%3d ", pfd.cColorBits);
496 if(pfd.dwFlags & PFD_DRAW_TO_WINDOW) fprintf(
file,
"wn ");
497 else if(pfd.dwFlags & PFD_DRAW_TO_BITMAP) fprintf(
file,
"bm ");
498 else fprintf(
file,
"pb ");
500 fprintf(
file,
" . ");
501 fprintf(
file,
"%3d ", pfd.cColorBits);
503 if(pfd.bReserved) fprintf(
file,
" %d ", pfd.bReserved);
504 else fprintf(
file,
" . ");
505 fprintf(
file,
" %c ", pfd.iPixelType == PFD_TYPE_RGBA ?
'r' :
'c');
506 fprintf(
file,
"%c ", pfd.dwFlags & PFD_DOUBLEBUFFER ?
'y' :
'.');
507 fprintf(
file,
" %c ", pfd.dwFlags & PFD_STEREO ?
'y' :
'.');
509 fprintf(
file,
" %c ", pfd.dwFlags & PFD_GENERIC_FORMAT ?
'y' :
'.');
510 fprintf(
file,
" %c ", pfd.dwFlags & PFD_GENERIC_ACCELERATED ?
'y' :
'.');
511 if(pfd.cRedBits && pfd.iPixelType == PFD_TYPE_RGBA)
512 fprintf(
file,
"%2d ", pfd.cRedBits);
513 else fprintf(
file,
" . ");
514 if(pfd.cGreenBits && pfd.iPixelType == PFD_TYPE_RGBA)
515 fprintf(
file,
"%2d ", pfd.cGreenBits);
516 else fprintf(
file,
" . ");
517 if(pfd.cBlueBits && pfd.iPixelType == PFD_TYPE_RGBA)
518 fprintf(
file,
"%2d ", pfd.cBlueBits);
519 else fprintf(
file,
" . ");
520 if(pfd.cAlphaBits && pfd.iPixelType == PFD_TYPE_RGBA)
521 fprintf(
file,
"%2d ", pfd.cAlphaBits);
522 else fprintf(
file,
" . ");
523 if(pfd.cAuxBuffers) fprintf(
file,
"%2d ", pfd.cAuxBuffers);
524 else fprintf(
file,
" . ");
525 if(pfd.cDepthBits) fprintf(
file,
"%2d ", pfd.cDepthBits);
526 else fprintf(
file,
" . ");
527 if(pfd.cStencilBits) fprintf(
file,
"%2d ", pfd.cStencilBits);
528 else fprintf(
file,
" . ");
529 if(pfd.cAccumBits) fprintf(
file,
"%3d ", pfd.cAccumBits);
530 else fprintf(
file,
" . ");
531 if(pfd.cAccumRedBits) fprintf(
file,
"%2d ", pfd.cAccumRedBits);
532 else fprintf(
file,
" . ");
533 if(pfd.cAccumGreenBits) fprintf(
file,
"%2d ", pfd.cAccumGreenBits);
534 else fprintf(
file,
" . ");
535 if(pfd.cAccumBlueBits) fprintf(
file,
"%2d ", pfd.cAccumBlueBits);
536 else fprintf(
file,
" . ");
537 if(pfd.cAccumAlphaBits) fprintf(
file,
"%2d ", pfd.cAccumAlphaBits);
538 else fprintf(
file,
" . ");
540 fprintf(
file,
" . .\n");
543 fprintf(
file,
"-----------------------------------------------------------------------------\n");
544 fprintf(
file,
" visual x bf lv rg d st ge ge r g b a ax dp st accum buffs ms \n");
545 fprintf(
file,
" id dep tp sp sz l ci b ro ne ac sz sz sz sz bf th cl sz r g b a ns b\n");
546 fprintf(
file,
"-----------------------------------------------------------------------------\n");
552 for(i = 1; i <= maxpf; i++)
554 DescribePixelFormat(ctx->dc, i,
sizeof(PIXELFORMATDESCRIPTOR), &pfd);
556 if(!(pfd.dwFlags & PFD_SUPPORT_OPENGL)
557 || (
drawableonly && !(pfd.dwFlags & PFD_DRAW_TO_WINDOW)))
continue;
558 fprintf(
file,
"Visual ID: %2d depth=%d class=%s\n", i, pfd.cDepthBits,
559 pfd.cColorBits <= 8 ?
"PseudoColor" :
"TrueColor");
560 fprintf(
file,
" bufferSize=%d level=%d renderType=%s doubleBuffer=%ld stereo=%ld\n", pfd.cColorBits, pfd.bReserved, pfd.iPixelType == PFD_TYPE_RGBA ?
"rgba" :
"ci", pfd.dwFlags & PFD_DOUBLEBUFFER, pfd.dwFlags & PFD_STEREO);
561 fprintf(
file,
" generic=%d generic accelerated=%d\n", (pfd.dwFlags & PFD_GENERIC_FORMAT) == PFD_GENERIC_FORMAT, (pfd.dwFlags & PFD_GENERIC_ACCELERATED) == PFD_GENERIC_ACCELERATED);
562 fprintf(
file,
" rgba: redSize=%d greenSize=%d blueSize=%d alphaSize=%d\n", pfd.cRedBits, pfd.cGreenBits, pfd.cBlueBits, pfd.cAlphaBits);
563 fprintf(
file,
" auxBuffers=%d depthSize=%d stencilSize=%d\n", pfd.cAuxBuffers, pfd.cDepthBits, pfd.cStencilBits);
564 fprintf(
file,
" accum: redSize=%d greenSize=%d blueSize=%d alphaSize=%d\n", pfd.cAccumRedBits, pfd.cAccumGreenBits, pfd.cAccumBlueBits, pfd.cAccumAlphaBits);
565 fprintf(
file,
" multiSample=%d multisampleBuffers=%d\n", 0, 0);
566 fprintf(
file,
" Opaque.\n");
582 #elif defined(__APPLE__) && !defined(GLEW_APPLE_GLX)
617 fprintf(
file,
" +-----+-------------------------+-----------------+----------+-------------+-------+------+\n");
618 fprintf(
file,
" | | visual | color | ax dp st | accum | ms | cav |\n");
619 fprintf(
file,
" | id | tp xr cl fm db st lv xp | sz r g b a | bf th cl | r g b a | ns b | eat |\n");
620 fprintf(
file,
" +-----+-------------------------+-----------------+----------+-------------+-------+------+\n");
622 for (i=0; i<n_fbc; i++)
629 fprintf(
file,
"| ? |");
633 fprintf(
file,
" |% 4d | ", value);
639 fprintf(
file,
" ? ");
647 fprintf(
file,
"wp ");
651 fprintf(
file,
"wn ");
658 fprintf(
file,
"pb ");
662 fprintf(
file,
"pm ");
666 fprintf(
file,
" ? ");
674 fprintf(
file,
" ? ");
678 fprintf(
file, value ?
" y " :
" n ");
684 fprintf(
file,
" ? ");
689 fprintf(
file,
"tc ");
691 fprintf(
file,
"dc ");
693 fprintf(
file,
"pc ");
695 fprintf(
file,
"sc ");
697 fprintf(
file,
"gs ");
699 fprintf(
file,
"sg ");
701 fprintf(
file,
" . ");
703 fprintf(
file,
" ? ");
709 fprintf(
file,
" ? ");
717 if (Success == ret2 &&
GL_TRUE == value2)
719 fprintf(
file,
" f ");
722 fprintf(
file,
" i ");
724 fprintf(
file,
" c ");
726 fprintf(
file,
" ? ");
731 fprintf(
file,
" f ");
733 fprintf(
file,
" i ");
735 fprintf(
file,
" c ");
737 fprintf(
file,
" ? ");
742 fprintf(
file,
" %c ", Success != ret ?
'?' : (value ?
'y' :
'.'));
745 fprintf(
file,
" %c ", Success != ret ?
'?' : (value ?
'y' :
'.'));
750 fprintf(
file,
" ? ");
754 fprintf(
file,
"%2d ", value);
760 fprintf(
file,
" ? | ");
765 fprintf(
file,
" r | ");
767 fprintf(
file,
" i | ");
769 fprintf(
file,
" . | ");
771 fprintf(
file,
" ? | ");
777 fprintf(
file,
" ? ");
782 fprintf(
file,
"%3d ", value);
784 fprintf(
file,
" . ");
790 fprintf(
file,
" ? ");
795 fprintf(
file,
"%2d ", value);
797 fprintf(
file,
" . ");
803 fprintf(
file,
" ? ");
808 fprintf(
file,
"%2d ", value);
810 fprintf(
file,
" . ");
816 fprintf(
file,
" ? ");
821 fprintf(
file,
"%2d ", value);
823 fprintf(
file,
" . ");
829 fprintf(
file,
" ? | ");
834 fprintf(
file,
"%2d | ", value);
836 fprintf(
file,
" . | ");
842 fprintf(
file,
" ? ");
847 fprintf(
file,
"%2d ", value);
849 fprintf(
file,
" . ");
855 fprintf(
file,
" ? ");
860 fprintf(
file,
"%2d ", value);
862 fprintf(
file,
" . ");
868 fprintf(
file,
" ? | ");
873 fprintf(
file,
"%2d | ", value);
875 fprintf(
file,
" . | ");
881 fprintf(
file,
" ? ");
886 fprintf(
file,
"%2d ", value);
888 fprintf(
file,
" . ");
894 fprintf(
file,
" ? ");
899 fprintf(
file,
"%2d ", value);
901 fprintf(
file,
" . ");
907 fprintf(
file,
" ? ");
912 fprintf(
file,
"%2d ", value);
914 fprintf(
file,
" . ");
920 fprintf(
file,
" ? | ");
925 fprintf(
file,
"%2d | ", value);
927 fprintf(
file,
" . | ");
933 fprintf(
file,
" ? ");
937 fprintf(
file,
"%2d ", value);
942 fprintf(
file,
" ? | ");
946 fprintf(
file,
"%2d | ", value);
952 fprintf(
file,
"???? |");
957 fprintf(
file,
"none |\n");
959 fprintf(
file,
"slow |\n");
961 fprintf(
file,
"ncft |\n");
963 fprintf(
file,
"???? |\n");
967 fprintf(
file,
" +-----+-------------------------+-----------------+----------+-------------+-------+------+\n");
968 fprintf(
file,
" | id | tp xr cl fm db st lv xp | sz r g b a | bf th cl | r g b a | ns b | eat |\n");
969 fprintf(
file,
" | | visual | color | ax dp st | accum | ms | cav |\n");
970 fprintf(
file,
" +-----+-------------------------+-----------------+----------+-------------+-------+------+\n");
991 PIXELFORMATDESCRIPTOR pfd;
995 ZeroMemory(&wc,
sizeof(WNDCLASS));
996 wc.hInstance = GetModuleHandle(
NULL);
997 wc.lpfnWndProc = DefWindowProc;
998 wc.lpszClassName =
"GLEW";
999 if (0 == RegisterClass(&wc))
return GL_TRUE;
1001 ctx->wnd = CreateWindow(
"GLEW",
"GLEW", 0, CW_USEDEFAULT, CW_USEDEFAULT,
1002 CW_USEDEFAULT, CW_USEDEFAULT,
NULL,
NULL,
1006 ctx->dc = GetDC(ctx->wnd);
1009 ZeroMemory(&pfd,
sizeof(PIXELFORMATDESCRIPTOR));
1012 pfd.nSize =
sizeof(PIXELFORMATDESCRIPTOR);
1014 pfd.dwFlags = PFD_DRAW_TO_WINDOW | PFD_SUPPORT_OPENGL;
1015 visual = ChoosePixelFormat(ctx->dc, &pfd);
1021 ctx->rc = wglCreateContext(ctx->dc);
1023 if (
FALSE == wglMakeCurrent(ctx->dc, ctx->rc))
return GL_TRUE;
1029 if (
NULL == ctx)
return;
1031 if (
NULL != ctx->rc) wglDeleteContext(wglGetCurrentContext());
1032 if (
NULL != ctx->wnd &&
NULL != ctx->dc) ReleaseDC(ctx->wnd, ctx->dc);
1033 if (
NULL != ctx->wnd) DestroyWindow(ctx->wnd);
1034 UnregisterClass(
"GLEW", GetModuleHandle(
NULL));
1039 #elif defined(__APPLE__) && !defined(GLEW_APPLE_GLX)
1049 int attrib[] = { AGL_RGBA, AGL_NONE };
1057 pf = aglChoosePixelFormat(
NULL, 0, attrib);
1059 ctx->ctx = aglCreateContext(pf,
NULL);
1060 if (
NULL == ctx->ctx || AGL_NO_ERROR != aglGetError())
return GL_TRUE;
1061 aglDestroyPixelFormat(pf);
1063 ctx->octx = aglGetCurrentContext();
1070 if (
NULL == ctx)
return;
1071 aglSetCurrentContext(ctx->octx);
1072 if (
NULL != ctx->ctx) aglDestroyContext(ctx->ctx);
1092 XSetWindowAttributes swa;
1108 ctx->cmap = XCreateColormap(ctx->dpy, RootWindow(ctx->dpy, ctx->vi->screen),
1109 ctx->vi->visual, AllocNone);
1110 swa.border_pixel = 0;
1111 swa.colormap = ctx->cmap;
1112 ctx->wnd = XCreateWindow(ctx->dpy, RootWindow(ctx->dpy, ctx->vi->screen),
1113 0, 0, 1, 1, 0, ctx->vi->depth, InputOutput, ctx->vi->visual,
1114 CWBorderPixel | CWColormap, &swa);
1124 if (
NULL != ctx->dpy && 0 != ctx->cmap) XFreeColormap(ctx->dpy, ctx->cmap);
1125 if (
NULL != ctx->vi) XFree(ctx->vi);
1137 if (!strcmp(argv[p],
"-pf") || !strcmp(argv[p],
"-pixelformat"))
1139 if (++p >= argc)
return GL_TRUE;
1143 else if (!strcmp(argv[p],
"-a"))
1147 else if (!strcmp(argv[p],
"-s"))
1151 else if (!strcmp(argv[p],
"-h"))
1158 if (!strcmp(argv[p],
"-display"))
1160 if (++p >= argc)
return GL_TRUE;
1163 else if (!strcmp(argv[p],
"-visual"))
1165 if (++p >= argc)
return GL_TRUE;
1168 else if (!strcmp(argv[p],
"-h"))
#define GLX_FLOAT_COMPONENTS_NV
return Display return Display Bool Bool int int int return Display XEvent Bool(*) XPointer retur XCloseDisplay)
#define WGL_DRAW_TO_PBUFFER_ARB
#define wglGetPixelFormatAttribivARB
#define WGL_DOUBLE_BUFFER_ARB
#define WGL_DRAW_TO_BITMAP_ARB
#define WGL_ACCUM_BLUE_BITS_ARB
#define GLX_TRANSPARENT_TYPE
int main(int argc, char **argv)
return Display return Display Bool Bool int int int return Display XEvent Bool(*) XPointer return Display return Display Drawable _Xconst char unsigned int unsigned int return Display Pixmap Pixmap XColor XColor unsigned int unsigned int return Display _Xconst char char int char return Display Visual unsigned int int int char unsigned int unsigned int int int return Display Window Cursor return Display Window return Display Drawable GC int int unsigned int unsigned int return Display Drawable GC int int _Xconst char int return Display Drawable GC int int unsigned int unsigned int return Display return Display Cursor return Display GC return XModifierKeymap return char Display Window int return Display return Display Atom return Display Window XWindowAttributes return Display Window return Display XEvent Bool(*) XPointer return Display Window Bool unsigned int int int Window Cursor Time return Display Window int return KeySym return Display _Xconst char Bool return Display _Xconst char return XKeyEvent char int KeySym XComposeStatus return Display int int int XVisualInfo return Display Window int int retur XOpenDisplay)
#define WGL_TYPE_RGBA_ARB
struct GLContextStruct GLContext
struct __GLXcontextRec * GLXContext
GLboolean glewExperimental
#define GLX_X_VISUAL_TYPE
#define GLX_ACCUM_GREEN_SIZE
GLAPI const GLubyte *GLAPIENTRY gluGetString(GLenum name)
#define GLX_SAMPLE_BUFFERS
#define WGL_FULL_ACCELERATION_ARB
#define WGLEW_ARB_pixel_format
#define glXQueryExtension
GLenum GLEWAPIENTRY wglewContextInit(WGLEW_CONTEXT_ARG_DEF_LIST)
#define WGLEW_ARB_pbuffer
GLXFBConfig * glXGetFBConfigs(Display *dpy, int screen, int *nelements)
#define glXQueryExtensionsString
#define wglChoosePixelFormatARB
static GLenum GLEWAPIENTRY glewContextInit(GLEW_CONTEXT_ARG_DEF_LIST)
#define WGLEW_ARB_extensions_string
#define WGL_GREEN_BITS_ARB
typedef HDC(WINAPI *PFNWGLGETCURRENTREADDCARBPROC)(VOID)
#define WGL_BLUE_BITS_ARB
#define WGL_PIXEL_TYPE_ARB
#define GLX_TRANSPARENT_RGB
#define WGLEW_EXT_extensions_string
void VisualInfo(GLContext *ctx)
#define WGL_SWAP_COPY_ARB
#define WGL_SWAP_EXCHANGE_ARB
GLboolean ParseArgs(int argc, char **argv)
GLenum glxewContextInit(GLXEW_CONTEXT_ARG_DEF_LIST)
#define WGL_SUPPORT_GDI_ARB
struct __GLXFBConfigRec * GLXFBConfig
#define WGL_TYPE_RGBA_UNSIGNED_FLOAT_EXT
#define WGLEW_NV_float_buffer
void InitContext(GLContext *ctx)
typedef HGLRC(WINAPI *PFNWGLCREATEASSOCIATEDCONTEXTAMDPROC)(UINT id)
#define WGLEW_ATI_pixel_format_float
#define glXDestroyContext
#define GLX_DRAWABLE_TYPE
#define GLX_RGBA_FLOAT_ATI_BIT
#define WGL_ACCUM_GREEN_BITS_ARB
#define WGL_NUMBER_UNDERLAYS_ARB
#define GLX_ACCUM_BLUE_SIZE
#define WGL_SWAP_METHOD_ARB
#define WGL_TYPE_RGBA_FLOAT_ATI
#define WGL_ACCELERATION_ARB
#define GLX_NON_CONFORMANT_CONFIG
#define WGL_ACCUM_ALPHA_BITS_ARB
#define WGL_NUMBER_PIXEL_FORMATS_ARB
#define GLX_ACCUM_ALPHA_SIZE
void DestroyContext(GLContext *ctx)
EGLSurface EGLint void ** value
#define WGL_SUPPORT_OPENGL_ARB
int glXGetFBConfigAttrib(Display *dpy, GLXFBConfig config, int attribute, int *value)
#define wglGetExtensionsStringEXT
#define GLXEW_NV_float_buffer
#define WGL_SWAP_LAYER_BUFFERS_ARB
#define GLX_ACCUM_RED_SIZE
GLboolean CreateContext(GLContext *ctx)
const GLubyte *GLEWAPIENTRY glewGetErrorString(GLenum error)
#define WGL_SWAP_UNDEFINED_ARB
#define WGL_NO_ACCELERATION_ARB
#define GLX_CONFIG_CAVEAT
#define WGL_NUMBER_OVERLAYS_ARB
return Display return Display Bool Bool int int int return Display XEvent Bool(*) XPointer return Display return Display Drawable _Xconst char unsigned int unsigned int return Display Pixmap Pixmap XColor XColor unsigned int unsigned int return Display _Xconst char char int char return Display Visual unsigned int int int char unsigned int unsigned int int int return Display Window Cursor retur XDestroyWindow)
void PrintExtensions(const char *s)
#define WGL_DEPTH_BITS_ARB
#define WGL_STENCIL_BITS_ARB
#define WGL_ALPHA_BITS_ARB
#define GLX_COLOR_INDEX_BIT
#define WGL_DRAW_TO_WINDOW_ARB
#define WGL_FLOAT_COMPONENTS_NV
Display * glXGetCurrentDisplay(void)
GLenum GLEWAPIENTRY glewInit(void)
#define GLX_TRANSPARENT_INDEX
#define WGL_COLOR_BITS_ARB
#define WGL_ACCUM_RED_BITS_ARB
#define WGL_ACCUM_BITS_ARB
#define WGL_AUX_BUFFERS_ARB
#define WGL_GENERIC_ACCELERATION_ARB
#define wglGetExtensionsStringARB
#define WGL_TYPE_COLORINDEX_ARB