diff --git a/auto/Makefile b/auto/Makefile index 5c42291..15f7cf7 100644 --- a/auto/Makefile +++ b/auto/Makefile @@ -107,8 +107,6 @@ $(S.DEST)/glewinfo.c: $(EXT)/.dummy cat $(SRC)/glewinfo_post.c >> $@ $(BIN)/fix_OML_sync_control.sh $@ -#doc: $(D.DEST)/glew.html $(D.DEST)/wglew.html $(D.DEST)/glxew.html - $(D.DEST)/glew.html: $(EXT)/.dummy cp -f $(SRC)/glew_pre.html $@ $(BIN)/make_html.pl $(EXT)/GL_* >> $@ diff --git a/auto/bin/make_list.pl b/auto/bin/make_list.pl index c694108..0bdf273 100755 --- a/auto/bin/make_list.pl +++ b/auto/bin/make_list.pl @@ -47,8 +47,11 @@ foreach my $ext (sort @extlist) my $extvar = $extname; $extvar =~ s/GL(X*)_/GL$1EW_/; + my $extpre = $extname; + $extpre =~ s/^(W?)GL(X?).*$/\l$1gl\l$2ew/; + print "#ifdef $extname\n"; - print " $extvar = glewGetExtension(\"$extname\");\n"; + print " $extvar = " . $extpre . "GetExtension(\"$extname\");\n"; if (keys %$functions) { print " if (glewExperimental || $extvar) $extvar = !_glewInit_$extname();\n"; diff --git a/src/wglinfo.c b/src/wglinfo.c index 6acabe5..669c3f4 100644 --- a/src/wglinfo.c +++ b/src/wglinfo.c @@ -84,13 +84,13 @@ VisualInfoARB (HDC hDC, int verbose) attrib[22] = WGL_NUMBER_UNDERLAYS_ARB; attrib[23] = WGL_SWAP_LAYER_BUFFERS_ARB; n_attrib = 24; - if (wglew_ARB_pbuffer) + if (WGLEW_ARB_pbuffer) { attrib[n_attrib] = WGL_DRAW_TO_PBUFFER_ARB; n_pbuffer = n_attrib; n_attrib++; } - if (wglew_NV_float_buffer) + if (WGLEW_NV_float_buffer) { attrib[n_attrib] = WGL_FLOAT_COMPONENTS_NV; n_float = n_attrib; @@ -114,7 +114,7 @@ VisualInfoARB (HDC hDC, int verbose) /* by default show only fully accelerated window or pbuffer capable visuals */ if (!showall && ((value[2] && !value[1]) - || (!wglew_ARB_pbuffer || !value[n_pbuffer]) + || (!WGLEW_ARB_pbuffer || !value[n_pbuffer]) || (value[3] != WGL_FULL_ACCELERATION_ARB))) continue; /* print out the information for this visual */ /* visual id */ @@ -122,21 +122,21 @@ VisualInfoARB (HDC hDC, int verbose) /* visual type */ if (value[1]) { - if (wglew_ARB_pbuffer && value[n_pbuffer]) fprintf(file, "wp "); + if (WGLEW_ARB_pbuffer && value[n_pbuffer]) fprintf(file, "wp "); else fprintf(file, "wn "); } else { if (value[2]) fprintf(file, "bm "); - else if (wglew_ARB_pbuffer && value[n_pbuffer]) fprintf(file, "pb "); + else if (WGLEW_ARB_pbuffer && value[n_pbuffer]) fprintf(file, "pb "); } /* acceleration */ fprintf(file, "%s", value[3] == WGL_FULL_ACCELERATION_ARB ? "fu" : value[3] == WGL_GENERIC_ACCELERATION_ARB ? "ge" : value[3] == WGL_NO_ACCELERATION_ARB ? "no" : ". "); /* format */ - if (wglew_NV_float_buffer && value[n_float]) fprintf(file, " f "); - else if (wglew_ATI_pixel_format_float && value[7] == WGL_TYPE_RGBA_FLOAT_ATI) fprintf(file, " f "); + if (WGLEW_NV_float_buffer && value[n_float]) fprintf(file, " f "); + else if (WGLEW_ATI_pixel_format_float && value[7] == WGL_TYPE_RGBA_FLOAT_ATI) fprintf(file, " f "); else if (value[7] == WGL_TYPE_RGBA_ARB) fprintf(file, " i "); else if (value[7] == WGL_TYPE_COLORINDEX_ARB) fprintf(file, " c "); /* double buffer */ @@ -556,14 +556,14 @@ main (int argc, char** argv) fprintf(file, "GLU extensions (GLU_): \n"); PrintExtensions((char*)gluGetString(GLU_EXTENSIONS)); /* WGL extensions */ - if (wglew_ARB_extensions_string || wglew_EXT_extensions_string) + if (WGLEW_ARB_extensions_string || WGLEW_EXT_extensions_string) { fprintf(file, "WGL extensions (WGL_): \n"); PrintExtensions(wglGetExtensionsStringARB ? (char*)wglGetExtensionsStringARB(hDC) : (char*)wglGetExtensionsStringEXT()); } /* enumerate all the formats */ - if (wglew_ARB_pixel_format) + if (WGLEW_ARB_pixel_format) { int attrib[16], value[16], pf; unsigned int c;