[Xorg-commit] xc/programs/Xserver/GL/glx Imakefile,1.1.4.1,1.1.4.2 g_disptab.c,1.1.4.1,1.1.4.2 g_disptab.h,1.1.4.1,1.1.4.2 g_disptab_EXT.c,1.1.4.1,1.1.4.2 g_disptab_EXT.h,1.1.4.1,1.1.4.2 g_render.c,1.1.4.1,1.1.4.2 g_renderswap.c,1.1.4.1,1.1.4.2 glxcmds.c,1.1.4.1,1.1.4.2 glxcmdsswap.c,1.1.4.1,1.1.4.2 glxext.c,1.1.4.1,1.1.4.2 glxext.h,1.1.4.1,1.1.4.2 glxscreens.c,1.1.4.1,1.1.4.2 glxserver.h,1.1.4.1,1.1.4.2 impsize.h,1.1.4.1,1.1.4.2 render2.c,1.1.4.1,1.1.4.2 render2swap.c,1.1,1.1.4.1 rensize.c,1.1.4.1,1.1.4.2 rensizetab.c,1.1.4.1,1.1.4.2 single2.c,1.1,1.1.4.1 single2swap.c,1.1,1.1.4.1 singlesize.c,1.1.4.1,1.1.4.2

Kaleb Keithley xorg-commit at pdx.freedesktop.org
Wed May 9 17:30:30 EEST 2007


Committed by: kaleb

Update of /cvs/xorg/xc/programs/Xserver/GL/glx
In directory pdx:/home/kaleb/xorg/xc.XORG-CURRENT/programs/Xserver/GL/glx

Modified Files:
      Tag: XORG-CURRENT
	Imakefile g_disptab.c g_disptab.h g_disptab_EXT.c 
	g_disptab_EXT.h g_render.c g_renderswap.c glxcmds.c 
	glxcmdsswap.c glxext.c glxext.h glxscreens.c glxserver.h 
	impsize.h render2.c render2swap.c rensize.c rensizetab.c 
	single2.c single2swap.c singlesize.c 
Log Message:
merge most of XFree86 RC3 (4.3.99.903) from vendor branch.
bug #214


Index: Imakefile
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/GL/glx/Imakefile,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/Imakefile	26 Nov 2003 22:48:40 -0000	1.1.4.1
+++ b/Imakefile	23 Feb 2004 21:34:59 -0000	1.1.4.2
@@ -1,4 +1,4 @@
-XCOMM $XFree86: xc/programs/Xserver/GL/glx/Imakefile,v 1.10 2003/08/06 14:04:01 eich Exp $
+XCOMM $XFree86: xc/programs/Xserver/GL/glx/Imakefile,v 1.12 2004/02/12 02:25:00 torrey Exp $
 
 #if DoLoadableServer
 # if !BuildModuleInSubdir
@@ -29,14 +29,18 @@
                 g_render.o g_renderswap.o g_single.o g_singleswap.o \
                 $(MOBJS)
 
-     INCLUDES = -I$(SERVERSRC)/GL/glx -I$(SERVERSRC)/GL/include -I$(SERVERSRC)/include -I$(INCLUDESRC) \
+     INCLUDES = -I$(SERVERSRC)/GL/glx -I$(SERVERSRC)/GL/include -I$(SERVERSRC)/include -I$(INCLUDESRC) -I$(MESASRCDIR)/include \
                 -I$(XINCLUDESRC) -I$(SERVERSRC)/mi \
                 -I$(EXTINCSRC) -I$(FONTINCSRC) -I$(LIBSRC)/GL/include \
                 -I$(XF86SRC)
 
+#if defined(DarwinArchitecture) && ((OSMajorVersion == 6 && OSMinorVersion < 3) || OSMajorVersion < 6)
+  NO_EXT_DEFS = -DMISSING_GL_EXTS
+#endif
+
 XCOMM If you add "-DDEBUG" in DEFINES, then make sure you also
 XCOMM add DEBUG to the define in ../mesa/src/X/xf86glx.c
-      DEFINES = $(GLX_DEFINES)
+      DEFINES = $(GLX_DEFINES) $(NO_EXT_DEFS)
 
 
 #ifdef IHaveModules

Index: g_disptab.c
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/GL/glx/g_disptab.c,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/g_disptab.c	26 Nov 2003 22:48:40 -0000	1.1.4.1
+++ b/g_disptab.c	23 Feb 2004 21:34:59 -0000	1.1.4.2
@@ -1,4 +1,4 @@
-/* $XFree86: xc/programs/Xserver/GL/glx/g_disptab.c,v 1.4 2003/09/28 20:15:41 alanh Exp $ */
+/* $XFree86: xc/programs/Xserver/GL/glx/g_disptab.c,v 1.6 2004/02/12 02:25:00 torrey Exp $ */
 /* DO NOT EDIT - THIS FILE IS AUTOMATICALLY GENERATED */
 /*
 ** License Applicability. Except to the extent portions of this file are
@@ -425,8 +425,12 @@
 	__glXNoSuchRenderOpcode,
 	__glXNoSuchRenderOpcode,
 	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
+	__glXDisp_SampleCoverageARB,
+#ifndef MISSING_GL_EXTS
 	__glXDisp_WindowPos3fARB /* 230 */
+#else
+	__glXNoSuchRenderOpcode
+#endif
 };
 
 __GLXdispatchSingleProcPtr __glXSwapSingleTable[__GLX_SINGLE_TABLE_SIZE] = {
@@ -822,6 +826,10 @@
 	__glXNoSuchRenderOpcode,
 	__glXNoSuchRenderOpcode,
 	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
+	__glXDispSwap_SampleCoverageARB,
+#ifndef MISSING_GL_EXTS
 	__glXDispSwap_WindowPos3fARB /* 230 */
+#else
+	__glXNoSuchRenderOpcode
+#endif
 };

Index: g_disptab.h
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/GL/glx/g_disptab.h,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/g_disptab.h	26 Nov 2003 22:48:40 -0000	1.1.4.1
+++ b/g_disptab.h	23 Feb 2004 21:34:59 -0000	1.1.4.2
@@ -1,4 +1,4 @@
-/* $XFree86: xc/programs/Xserver/GL/glx/g_disptab.h,v 1.4 2003/09/28 20:15:42 alanh Exp $ */
+/* $XFree86: xc/programs/Xserver/GL/glx/g_disptab.h,v 1.5 2004/01/28 18:11:50 alanh Exp $ */
 /* DO NOT EDIT - THIS FILE IS AUTOMATICALLY GENERATED */
 #ifndef _GLX_g_disptab_h_
 #define _GLX_g_disptab_h_
@@ -325,6 +325,7 @@
 extern void __glXDisp_MultiTexCoord4fvARB(GLbyte*);
 extern void __glXDisp_MultiTexCoord4ivARB(GLbyte*);
 extern void __glXDisp_MultiTexCoord4svARB(GLbyte*);
+extern void __glXDisp_SampleCoverageARB(GLbyte *);
 extern void __glXDisp_WindowPos3fARB(GLbyte *);
 
 extern int __glXSwapRender(__GLXclientState*, GLbyte*);
@@ -621,6 +622,7 @@
 extern void __glXDispSwap_MultiTexCoord4fvARB(GLbyte*);
 extern void __glXDispSwap_MultiTexCoord4ivARB(GLbyte*);
 extern void __glXDispSwap_MultiTexCoord4svARB(GLbyte*);
+extern void __glXDispSwap_SampleCoverageARB(GLbyte *);
 extern void __glXDispSwap_WindowPos3fARB(GLbyte *);
 
 #define __GLX_MIN_GLXCMD_OPCODE 1

Index: g_disptab_EXT.c
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/GL/glx/g_disptab_EXT.c,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/g_disptab_EXT.c	26 Nov 2003 22:48:40 -0000	1.1.4.1
+++ b/g_disptab_EXT.c	23 Feb 2004 21:34:59 -0000	1.1.4.2
@@ -1,4 +1,4 @@
-/* $XFree86: xc/programs/Xserver/GL/glx/g_disptab_EXT.c,v 1.4 2003/09/28 20:15:42 alanh Exp $ */
+/* $XFree86: xc/programs/Xserver/GL/glx/g_disptab_EXT.c,v 1.6 2004/02/12 02:25:00 torrey Exp $ */
 /* DO NOT EDIT - THIS FILE IS AUTOMATICALLY GENERATED */
 /*
 ** License Applicability. Except to the extent portions of this file are
@@ -45,8 +45,13 @@
 	__glXNoSuchRenderOpcode,
 	__glXNoSuchRenderOpcode,
 	__glXNoSuchRenderOpcode,
+#ifndef MISSING_GL_EXTS
 	__glXDisp_PointParameterfARB, /* 2065 */
 	__glXDisp_PointParameterfvARB, /* 2066 */
+#else
+	__glXNoSuchRenderOpcode,
+	__glXNoSuchRenderOpcode,
+#endif
 	__glXNoSuchRenderOpcode,
 	__glXNoSuchRenderOpcode,
 	__glXNoSuchRenderOpcode,
@@ -2104,22 +2109,36 @@
 	__glXDisp_CopyTexSubImage1D,  /* 4121 */
 	__glXDisp_CopyTexSubImage2D,  /* 4122 */
 	__glXDisp_CopyTexSubImage3D,  /* 4123 */
-	__glXNoSuchRenderOpcode, /* 4124 */
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode, /* 4130 */
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
+#ifndef MISSING_GL_EXTS
+	__glXDisp_FogCoordfv,         /* 4124 */
+	__glXDisp_FogCoorddv,         /* 4125 */
+	__glXDisp_SecondaryColor3bv,  /* 4126 */
+	__glXDisp_SecondaryColor3sv,  /* 4127 */
+	__glXDisp_SecondaryColor3iv,  /* 4128 */
+	__glXDisp_SecondaryColor3fv,  /* 4129 */
+	__glXDisp_SecondaryColor3dv,  /* 4130 */
+	__glXDisp_SecondaryColor3ubv, /* 4131 */
+	__glXDisp_SecondaryColor3usv, /* 4132 */
+	__glXDisp_SecondaryColor3uiv, /* 4133 */
+	__glXDisp_BlendFuncSeparate,  /* 4134 */
+#else
+	__glXNoSuchRenderOpcode,      /* 4124 */
+	__glXNoSuchRenderOpcode,      /* 4125 */
+	__glXNoSuchRenderOpcode,      /* 4126 */
+	__glXNoSuchRenderOpcode,      /* 4127 */
+	__glXNoSuchRenderOpcode,      /* 4128 */
+	__glXNoSuchRenderOpcode,      /* 4129 */
+	__glXNoSuchRenderOpcode,      /* 4130 */
+	__glXNoSuchRenderOpcode,      /* 4131 */
+	__glXNoSuchRenderOpcode,      /* 4132 */
+	__glXNoSuchRenderOpcode,      /* 4133 */
+	__glXNoSuchRenderOpcode,      /* 4134 */
+#endif
+	__glXNoSuchRenderOpcode,      /* 4135 */
+	__glXNoSuchRenderOpcode,      /* 4136 */
+	__glXNoSuchRenderOpcode,      /* 4137 */
+	__glXNoSuchRenderOpcode,      /* 4138 */
+	__glXNoSuchRenderOpcode,      /* 4139 */
 	__glXNoSuchRenderOpcode, /* 4140 */
 	__glXNoSuchRenderOpcode,
 	__glXNoSuchRenderOpcode,
@@ -2200,7 +2219,20 @@
 	__glXNoSuchRenderOpcode,
 	__glXNoSuchRenderOpcode,
 	__glXNoSuchRenderOpcode, /* 4219 */
+#ifndef MISSING_GL_EXTS
 	__glXDisp_ActiveStencilFaceEXT, /* 4220 */
+# ifndef __DARWIN__
+	__glXDisp_PointParameteri,      /* 4221 */
+	__glXDisp_PointParameteriv,     /* 4222 */
+# else
+	__glXDisp_PointParameteriNV,    /* 4221 */
+	__glXDisp_PointParameterivNV,   /* 4222 */
+# endif
+#else
+	__glXNoSuchRenderOpcode,
+	__glXNoSuchRenderOpcode,
+	__glXNoSuchRenderOpcode,
+#endif
 };
 __GLXdispatchVendorPrivProcPtr __glXVendorPrivTable_EXT[__GLX_MAX_VENDPRIV_OPCODE_EXT - __GLX_MIN_VENDPRIV_OPCODE_EXT + 1] = {
 	__glXDisp_AreTexturesResidentEXT, /* 11 */
@@ -2223,8 +2255,13 @@
 	__glXNoSuchRenderOpcode,
 	__glXNoSuchRenderOpcode,
 	__glXNoSuchRenderOpcode,
+#ifndef MISSING_GL_EXTS
 	__glXDispSwap_PointParameterfARB, /* 2065 */
 	__glXDispSwap_PointParameterfvARB, /* 2066 */
+#else
+	__glXNoSuchRenderOpcode,
+	__glXNoSuchRenderOpcode,
+#endif
 	__glXNoSuchRenderOpcode,
 	__glXNoSuchRenderOpcode,
 	__glXNoSuchRenderOpcode,
@@ -4282,22 +4319,36 @@
 	__glXDispSwap_CopyTexSubImage1D,  /* 4121 */
 	__glXDispSwap_CopyTexSubImage2D,  /* 4122 */
 	__glXDispSwap_CopyTexSubImage3D,  /* 4123 */
-	__glXNoSuchRenderOpcode, /* 4124 */
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode, /* 4130 */
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
-	__glXNoSuchRenderOpcode,
+#ifndef MISSING_GL_EXTS
+	__glXDispSwap_FogCoordfv,         /* 4124 */
+	__glXDispSwap_FogCoorddv,         /* 4125 */
+	__glXDispSwap_SecondaryColor3bv,  /* 4126 */
+	__glXDispSwap_SecondaryColor3sv,  /* 4127 */
+	__glXDispSwap_SecondaryColor3iv,  /* 4128 */
+	__glXDispSwap_SecondaryColor3fv,  /* 4129 */
+	__glXDispSwap_SecondaryColor3dv,  /* 4130 */
+	__glXDispSwap_SecondaryColor3ubv, /* 4131 */
+	__glXDispSwap_SecondaryColor3usv, /* 4132 */
+	__glXDispSwap_SecondaryColor3uiv, /* 4133 */
+	__glXDisp_BlendFuncSeparate,      /* 4134 */
+#else
+	__glXNoSuchRenderOpcode,          /* 4124 */
+	__glXNoSuchRenderOpcode,          /* 4125 */
+	__glXNoSuchRenderOpcode,          /* 4126 */
+	__glXNoSuchRenderOpcode,          /* 4127 */
+	__glXNoSuchRenderOpcode,          /* 4128 */
+	__glXNoSuchRenderOpcode,          /* 4129 */
+	__glXNoSuchRenderOpcode,          /* 4130 */
+	__glXNoSuchRenderOpcode,          /* 4131 */
+	__glXNoSuchRenderOpcode,          /* 4132 */
+	__glXNoSuchRenderOpcode,          /* 4133 */
+	__glXNoSuchRenderOpcode,          /* 4134 */
+#endif
+	__glXNoSuchRenderOpcode,          /* 4135 */
+	__glXNoSuchRenderOpcode,          /* 4136 */
+	__glXNoSuchRenderOpcode,          /* 4137 */
+	__glXNoSuchRenderOpcode,          /* 4138 */
+	__glXNoSuchRenderOpcode,          /* 4139 */
 	__glXNoSuchRenderOpcode, /* 4140 */
 	__glXNoSuchRenderOpcode,
 	__glXNoSuchRenderOpcode,
@@ -4378,7 +4429,20 @@
 	__glXNoSuchRenderOpcode,
 	__glXNoSuchRenderOpcode,
 	__glXNoSuchRenderOpcode, /* 4219 */
+#ifndef MISSING_GL_EXTS
 	__glXDispSwap_ActiveStencilFaceEXT, /* 4220 */
+# ifndef __DARWIN__
+	__glXDispSwap_PointParameteri,      /* 4221 */
+	__glXDispSwap_PointParameteriv,     /* 4222 */
+# else
+	__glXDispSwap_PointParameteriNV,    /* 4221 */
+	__glXDispSwap_PointParameterivNV,   /* 4222 */
+# endif
+#else
+	__glXNoSuchRenderOpcode,
+	__glXNoSuchRenderOpcode,
+	__glXNoSuchRenderOpcode,
+#endif
 };
 __GLXdispatchVendorPrivProcPtr __glXSwapVendorPrivTable_EXT[__GLX_MAX_VENDPRIV_OPCODE_EXT - __GLX_MIN_VENDPRIV_OPCODE_EXT + 1] = {
 	__glXDispSwap_AreTexturesResidentEXT, /* 11 */

Index: g_disptab_EXT.h
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/GL/glx/g_disptab_EXT.h,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/g_disptab_EXT.h	26 Nov 2003 22:48:40 -0000	1.1.4.1
+++ b/g_disptab_EXT.h	23 Feb 2004 21:34:59 -0000	1.1.4.2
@@ -1,4 +1,4 @@
-/* $XFree86: xc/programs/Xserver/GL/glx/g_disptab_EXT.h,v 1.4 2003/09/28 20:15:42 alanh Exp $ */
+/* $XFree86: xc/programs/Xserver/GL/glx/g_disptab_EXT.h,v 1.6 2004/02/12 02:25:01 torrey Exp $ */
 /* DO NOT EDIT - THIS FILE IS AUTOMATICALLY GENERATED */
 #ifndef _GLX_g_disptab_EXT_h_
 #define _GLX_g_disptab_EXT_h_
@@ -69,6 +69,44 @@
 extern void __glXDisp_CopyTexSubImage3D(GLbyte*);
 extern void __glXDisp_PointParameterfARB(GLbyte*);
 extern void __glXDisp_PointParameterfvARB(GLbyte*);
+
+extern void __glXDisp_FogCoordfv(GLbyte *);
+extern void __glXDisp_FogCoorddv(GLbyte *);
+extern void __glXDispSwap_FogCoordfv(GLbyte *);
+extern void __glXDispSwap_FogCoorddv(GLbyte *);
+
+extern void __glXDisp_SecondaryColor3bv(GLbyte *);
+extern void __glXDisp_SecondaryColor3sv(GLbyte *);
+extern void __glXDisp_SecondaryColor3iv(GLbyte *);
+extern void __glXDisp_SecondaryColor3ubv(GLbyte *);
+extern void __glXDisp_SecondaryColor3usv(GLbyte *);
+extern void __glXDisp_SecondaryColor3uiv(GLbyte *);
+extern void __glXDisp_SecondaryColor3fv(GLbyte *);
+extern void __glXDisp_SecondaryColor3dv(GLbyte *);
+extern void __glXDispSwap_SecondaryColor3bv(GLbyte *);
+extern void __glXDispSwap_SecondaryColor3sv(GLbyte *);
+extern void __glXDispSwap_SecondaryColor3iv(GLbyte *);
+extern void __glXDispSwap_SecondaryColor3ubv(GLbyte *);
+extern void __glXDispSwap_SecondaryColor3usv(GLbyte *);
+extern void __glXDispSwap_SecondaryColor3uiv(GLbyte *);
+extern void __glXDispSwap_SecondaryColor3fv(GLbyte *);
+extern void __glXDispSwap_SecondaryColor3dv(GLbyte *);
+
+extern void __glXDisp_BlendFuncSeparate(GLbyte *);
+extern void __glXDispSwap_BlendFuncSeparate(GLbyte *);
+
+#ifdef __DARWIN__
+extern void __glXDisp_PointParameteriNV(GLbyte *);
+extern void __glXDisp_PointParameterivNV(GLbyte *);
+extern void __glXDispSwap_PointParameteriNV(GLbyte *);
+extern void __glXDispSwap_PointParameterivNV(GLbyte *);
+#else
+extern void __glXDisp_PointParameteri(GLbyte *);
+extern void __glXDisp_PointParameteriv(GLbyte *);
+extern void __glXDispSwap_PointParameteri(GLbyte *);
+extern void __glXDispSwap_PointParameteriv(GLbyte *);
+#endif
+
 extern void __glXDisp_ActiveStencilFaceEXT(GLbyte*);
 
 extern int __glXDispSwap_AreTexturesResidentEXT(__GLXclientState*, GLbyte*);
@@ -112,7 +150,7 @@
 extern void __glXDispSwap_ActiveStencilFaceEXT(GLbyte*);
 
 #define __GLX_MIN_RENDER_OPCODE_EXT 2053
-#define __GLX_MAX_RENDER_OPCODE_EXT 4220
+#define __GLX_MAX_RENDER_OPCODE_EXT 4222
 #define __GLX_MIN_VENDPRIV_OPCODE_EXT 11
 #define __GLX_MAX_VENDPRIV_OPCODE_EXT 14
 #define __GLX_VENDPRIV_TABLE_SIZE_EXT (__GLX_MAX_VENDPRIV_OPCODE_EXT - __GLX_MIN_VENDPRIV_OPCODE_EXT + 1)

Index: g_render.c
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/GL/glx/g_render.c,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/g_render.c	26 Nov 2003 22:48:40 -0000	1.1.4.1
+++ b/g_render.c	23 Feb 2004 21:34:59 -0000	1.1.4.2
@@ -1,4 +1,4 @@
-/* $XFree86: xc/programs/Xserver/GL/glx/g_render.c,v 1.6 2003/10/28 22:50:17 tsi Exp $ */
+/* $XFree86: xc/programs/Xserver/GL/glx/g_render.c,v 1.9 2004/02/12 02:25:01 torrey Exp $ */
 /* DO NOT EDIT - THIS FILE IS AUTOMATICALLY GENERATED */
 /*
 ** License Applicability. Except to the extent portions of this file are
@@ -59,6 +59,157 @@
 	);
 }
 
+#define __GLX_SWAP_GLbyte(ptr)
+#define __GLX_SWAP_GLshort(ptr)  __GLX_SWAP_SHORT(ptr)
+#define __GLX_SWAP_GLint(ptr)    __GLX_SWAP_INT(ptr)
+#define __GLX_SWAP_GLubyte(ptr)
+#define __GLX_SWAP_GLushort(ptr) __GLX_SWAP_SHORT(ptr)
+#define __GLX_SWAP_GLuint(ptr)   __GLX_SWAP_INT(ptr)
+#define __GLX_SWAP_GLdouble(ptr) __GLX_SWAP_DOUBLE(ptr)
+#define __GLX_SWAP_GLfloat(ptr)  __GLX_SWAP_FLOAT(ptr)
+
+#define __GLX_SWAP_GLbyte_ARRAY(ptr,count)   (void) swapEnd; (void) swapPC; (void) sw;
+#define __GLX_SWAP_GLshort_ARRAY(ptr,count)  __GLX_SWAP_SHORT_ARRAY(ptr,count)
+#define __GLX_SWAP_GLint_ARRAY(ptr,count)    __GLX_SWAP_INT_ARRAY(ptr,count)
+#define __GLX_SWAP_GLenum_ARRAY(ptr,count)   __GLX_SWAP_INT_ARRAY(ptr,count)
+#define __GLX_SWAP_GLubyte_ARRAY(ptr,count)  (void) swapEnd; (void) swapPC; (void) sw;
+#define __GLX_SWAP_GLushort_ARRAY(ptr,count) __GLX_SWAP_SHORT_ARRAY(ptr,count)
+#define __GLX_SWAP_GLuint_ARRAY(ptr,count)   __GLX_SWAP_INT_ARRAY(ptr,count)
+#define __GLX_SWAP_GLdouble_ARRAY(ptr,count) __GLX_SWAP_DOUBLE_ARRAY(ptr,count)
+#define __GLX_SWAP_GLfloat_ARRAY(ptr,count)  __GLX_SWAP_FLOAT_ARRAY(ptr,count)
+
+#ifdef __GLX_ALIGN64
+/* If type is not GLdouble, the compiler should optimize this away.
+ */
+# define GLX_DO_ALIGN_MAGIC(count, type) \
+	do { \
+	    if ( (sizeof(type) == 8) && ((unsigned long)(pc) & 7)) \
+	    { \
+	       	__GLX_MEM_COPY(pc-4, pc, (count * sizeof( type ) )); \
+	    	pc -= 4; \
+	    } \
+	} while( 0 )
+#else
+# define GLX_DO_ALIGN_MAGIC(count, type)
+#endif
+
+#define dispatch_template_1( name, type ) \
+    void __glXDisp_ ## name ( GLbyte * pc ) \
+    { \
+	GLX_DO_ALIGN_MAGIC( 1, type ); \
+	gl ## name ( (type *) pc ); \
+    } \
+    void __glXDispSwap_ ## name ( GLbyte * pc ) \
+    { \
+	__GLX_DECLARE_SWAP_VARIABLES; \
+	GLX_DO_ALIGN_MAGIC( 1, type ); \
+	__GLX_SWAP_ ## type ( pc ); \
+	gl ## name ( (type *) pc ); \
+    }
+
+#define dispatch_template_3( name, type ) \
+    void __glXDisp_ ## name ( GLbyte * pc ) \
+    { \
+	GLX_DO_ALIGN_MAGIC( 3, type ); \
+	gl ## name ( (type *) pc ); \
+    } \
+    void __glXDispSwap_ ## name ( GLbyte * pc ) \
+    { \
+	__GLX_DECLARE_SWAP_VARIABLES; \
+	__GLX_DECLARE_SWAP_ARRAY_VARIABLES; \
+	GLX_DO_ALIGN_MAGIC( 3, type ); \
+	__GLX_SWAP_ ## type ## _ARRAY(pc, 3); \
+	gl ## name ( (type *) pc ); \
+    }
+
+#define dispatch_template_4( name, type ) \
+    void __glXDisp_ ## name ( GLbyte * pc ) \
+    { \
+	GLX_DO_ALIGN_MAGIC( 4, type ); \
+	gl ## name ( (type *) pc ); \
+    } \
+    void __glXDispSwap_ ## name ( GLbyte * pc ) \
+    { \
+	__GLX_DECLARE_SWAP_VARIABLES; \
+	__GLX_DECLARE_SWAP_ARRAY_VARIABLES; \
+	GLX_DO_ALIGN_MAGIC( 4, type ); \
+	__GLX_SWAP_ ## type ## _ARRAY(pc, 4); \
+	gl ## name ( (type *) pc ); \
+    }
+
+#define dispatch_template_4s( name, type ) \
+    void __glXDisp_ ## name ( GLbyte * pc ) \
+    { \
+	GLX_DO_ALIGN_MAGIC( 4, type ); \
+	gl ## name ( ((type *) pc)[0], ((type *) pc)[1], \
+		     ((type *) pc)[2], ((type *) pc)[3] ); \
+    } \
+    void __glXDispSwap_ ## name ( GLbyte * pc ) \
+    { \
+	__GLX_DECLARE_SWAP_VARIABLES; \
+	__GLX_DECLARE_SWAP_ARRAY_VARIABLES; \
+	GLX_DO_ALIGN_MAGIC( 4, type ); \
+	__GLX_SWAP_ ## type ## _ARRAY(pc, 4); \
+	gl ## name ( ((type *) pc)[0], ((type *) pc)[1], \
+		     ((type *) pc)[2], ((type *) pc)[3] ); \
+    }
+
+/**
+ * \bug All of the enum1 templates need to be updated to handle the case where
+ * \c type is \c GLdouble.  When the type is a double, the data comes before
+ * the enum.  This is also the reason the invocation of the
+ * \c GLX_DO_ALIGN_MAGIC macro was removed.
+ */
+#define dispatch_template_enum1_1s( name, type ) \
+    void __glXDisp_ ## name ( GLbyte * pc ) \
+    { \
+	gl ## name ( *(GLenum *) (pc + 0), \
+		     *(type *)   (pc + 4) ); \
+    } \
+    void __glXDispSwap_ ## name ( GLbyte * pc ) \
+    { \
+	__GLX_DECLARE_SWAP_VARIABLES; \
+	__GLX_SWAP_INT      (pc + 0); \
+	__GLX_SWAP_ ## type (pc + 4); \
+	gl ## name ( *(GLenum *) (pc + 0), \
+		     *(type *)   (pc + 4) ); \
+    }
+
+#define dispatch_template_enum1_Vv( name, type ) \
+    void __glXDisp_ ## name ( GLbyte * pc ) \
+    { \
+	gl ## name ( *(GLenum *) (pc + 0), \
+		      (type *)   (pc + 4) ); \
+    } \
+    void __glXDispSwap_ ## name ( GLbyte * pc ) \
+    { \
+	GLenum pname; GLint compsize; \
+	__GLX_DECLARE_SWAP_VARIABLES; \
+	__GLX_DECLARE_SWAP_ARRAY_VARIABLES; \
+	__GLX_SWAP_INT(pc + 0); \
+	pname = *(GLenum *)(pc + 0); \
+	compsize = __gl ## name ## _size(pname); \
+	if (compsize < 0) compsize = 0; \
+	__GLX_SWAP_ ## type ## _ARRAY(pc + 4, compsize); \
+	gl ## name ( *(GLenum *) (pc + 0), \
+		      (type *)   (pc + 4) ); \
+    }
+
+#ifndef MISSING_GL_EXTS
+dispatch_template_1( FogCoordfv,         GLfloat )
+dispatch_template_1( FogCoorddv,         GLdouble )
+dispatch_template_3( SecondaryColor3bv,  GLbyte )
+dispatch_template_3( SecondaryColor3sv,  GLshort )
+dispatch_template_3( SecondaryColor3iv,  GLint )
+dispatch_template_3( SecondaryColor3ubv, GLubyte )
+dispatch_template_3( SecondaryColor3usv, GLushort )
+dispatch_template_3( SecondaryColor3uiv, GLuint )
+dispatch_template_3( SecondaryColor3fv,  GLfloat )
+dispatch_template_3( SecondaryColor3dv,  GLdouble )
+
+dispatch_template_4s( BlendFuncSeparate,  GLenum )
+#endif /* !MISSING_GL_EXTS */
+
 void __glXDisp_Color3bv(GLbyte *pc)
 {
 	glColor3bv( 
@@ -2079,6 +2230,8 @@
  * Extensions
  */
 
+#ifndef MISSING_GL_EXTS
+
 void __glXDisp_PointParameterfARB(GLbyte *pc)
 {
 	glPointParameterfARB(
@@ -2096,6 +2249,15 @@
 	);
 }
 
+#ifdef __DARWIN__
+#define __glPointParameterivNV_size __glPointParameteriv_size
+dispatch_template_enum1_1s(PointParameteriNV,  GLint)
+dispatch_template_enum1_Vv(PointParameterivNV, GLint)
+#else
+dispatch_template_enum1_1s(PointParameteri,  GLint)
+dispatch_template_enum1_Vv(PointParameteriv, GLint)
+#endif
+
 void __glXDisp_ActiveStencilFaceEXT(GLbyte *pc)
 {
 	glActiveStencilFaceEXT(
@@ -2111,3 +2273,13 @@
 		*(GLfloat *)(pc + 8)
 	);
 }
+
+#endif /* !MISSING_GL_EXTS */
+
+void __glXDisp_SampleCoverageARB(GLbyte *pc)
+{
+	glSampleCoverageARB(
+		*(GLfloat *)(pc + 0),
+		*(GLboolean *)(pc + 4)
+	);
+}

Index: g_renderswap.c
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/GL/glx/g_renderswap.c,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/g_renderswap.c	26 Nov 2003 22:48:40 -0000	1.1.4.1
+++ b/g_renderswap.c	23 Feb 2004 21:34:59 -0000	1.1.4.2
@@ -1,4 +1,4 @@
-/* $XFree86: xc/programs/Xserver/GL/glx/g_renderswap.c,v 1.7 2003/10/28 22:50:17 tsi Exp $ */
+/* $XFree86: xc/programs/Xserver/GL/glx/g_renderswap.c,v 1.9 2004/02/12 02:25:01 torrey Exp $ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
@@ -3313,6 +3313,8 @@
  * Extensions
  */
 
+#ifndef MISSING_GL_EXTS
+
 void __glXDispSwap_PointParameterfARB(GLbyte *pc)
 {
 	__GLX_DECLARE_SWAP_VARIABLES;
@@ -3366,3 +3368,17 @@
 		*(GLfloat *)(pc + 8)
 	);
 }
+
+#endif /* !MISSING_GL_EXTS */
+
+void __glXDispSwap_SampleCoverageARB(GLbyte *pc)
+{
+	__GLX_DECLARE_SWAP_VARIABLES;
+	__GLX_SWAP_FLOAT(pc + 0);
+	__GLX_SWAP_INT(pc + 4);
+
+	glSampleCoverageARB(
+		*(GLfloat *)(pc + 0),
+		*(GLboolean *)(pc + 4)
+	);
+}

Index: glxcmds.c
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/GL/glx/glxcmds.c,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/glxcmds.c	26 Nov 2003 22:48:40 -0000	1.1.4.1
+++ b/glxcmds.c	23 Feb 2004 21:34:59 -0000	1.1.4.2
@@ -1,4 +1,4 @@
-/* $XFree86: xc/programs/Xserver/GL/glx/glxcmds.c,v 1.11 2003/10/28 22:50:17 tsi Exp $ */
+/* $XFree86: xc/programs/Xserver/GL/glx/glxcmds.c,v 1.13 2004/02/12 02:25:01 torrey Exp $ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
@@ -1554,6 +1554,18 @@
     req = (xGLXVendorPrivateReq *) pc;
     vendorcode = req->vendorCode;
 
+#ifndef __DARWIN__
+    switch( vendorcode ) {
+    case X_GLvop_SampleMaskSGIS:
+	glSampleMaskSGIS(*(GLfloat *)(pc + 4),
+			 *(GLboolean *)(pc + 8));
+	return Success;
+    case X_GLvop_SamplePatternSGIS:
+	glSamplePatternSGIS( *(GLenum *)(pc + 4));
+	return Success;
+    }
+#endif
+
     if ((vendorcode >= __GLX_MIN_VENDPRIV_OPCODE_EXT) &&
           (vendorcode <= __GLX_MAX_VENDPRIV_OPCODE_EXT))  {
 	(*__glXVendorPrivTable_EXT[vendorcode-__GLX_MIN_VENDPRIV_OPCODE_EXT])

Index: glxcmdsswap.c
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/GL/glx/glxcmdsswap.c,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/glxcmdsswap.c	26 Nov 2003 22:48:40 -0000	1.1.4.1
+++ b/glxcmdsswap.c	23 Feb 2004 21:34:59 -0000	1.1.4.2
@@ -1,4 +1,4 @@
-/* $XFree86: xc/programs/Xserver/GL/glx/glxcmdsswap.c,v 1.9 2003/10/28 22:50:17 tsi Exp $ */
+/* $XFree86: xc/programs/Xserver/GL/glx/glxcmdsswap.c,v 1.11 2004/02/12 02:25:01 torrey Exp $ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
@@ -791,6 +791,21 @@
 
     vendorcode = req->vendorCode;
 
+#ifndef __DARWIN__
+    switch( vendorcode ) {
+    case X_GLvop_SampleMaskSGIS:
+	__GLX_SWAP_FLOAT(pc + 4);
+	__GLX_SWAP_INT(pc + 8);
+	glSampleMaskSGIS(*(GLfloat *)(pc + 4),
+			 *(GLboolean *)(pc + 8));
+	return Success;
+    case X_GLvop_SamplePatternSGIS:
+	__GLX_SWAP_INT(pc + 4);
+	glSamplePatternSGIS( *(GLenum *)(pc + 4));
+	return Success;
+    }
+#endif
+
     if ((vendorcode >= __GLX_MIN_VENDPRIV_OPCODE_EXT) &&
           (vendorcode <= __GLX_MAX_VENDPRIV_OPCODE_EXT))  {
 	(*__glXSwapVendorPrivTable_EXT[vendorcode-__GLX_MIN_VENDPRIV_OPCODE_EXT])(cl, (GLbyte*)req);

Index: glxext.c
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/GL/glx/glxext.c,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/glxext.c	26 Nov 2003 22:48:40 -0000	1.1.4.1
+++ b/glxext.c	23 Feb 2004 21:34:59 -0000	1.1.4.2
@@ -1,4 +1,4 @@
-/* $XFree86: xc/programs/Xserver/GL/glx/glxext.c,v 1.9 2003/09/28 20:15:43 alanh Exp $
+/* $XFree86: xc/programs/Xserver/GL/glx/glxext.c,v 1.10 2004/01/28 22:36:05 alanh Exp $
 ** The contents of this file are subject to the GLX Public License Version 1.0
 ** (the "License"). You may not use this file except in compliance with the
 ** License. You may obtain a copy of the License at Silicon Graphics, Inc.,
@@ -31,6 +31,9 @@
 
 
 extern __GLXextensionInfo __glDDXExtensionInfo;
+void GlxWrapInitVisuals(miInitVisualsProcPtr *);
+void GlxSetVisualConfigs(int nconfigs, 
+                         __GLXvisualConfig *configs, void **privates);
 
 __GLXextensionInfo *__glXExt = &__glDDXExtensionInfo;
 

Index: glxext.h
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/GL/glx/glxext.h,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/glxext.h	26 Nov 2003 22:48:40 -0000	1.1.4.1
+++ b/glxext.h	23 Feb 2004 21:34:59 -0000	1.1.4.2
@@ -1,4 +1,4 @@
-/* $XFree86: xc/programs/Xserver/GL/glx/glxext.h,v 1.7 2003/11/17 22:20:26 dawes Exp $ */
+/* $XFree86: xc/programs/Xserver/GL/glx/glxext.h,v 1.8 2004/02/09 23:46:31 alanh Exp $ */
 #ifndef _glxext_h_
 #define _glxext_h_
 
@@ -80,6 +80,9 @@
 
 extern Bool __glXCoreType(void);
 
+extern const char GLServerVersion[];
+extern int DoGetString(__GLXclientState *cl, GLbyte *pc, GLboolean need_swap);
+
 extern int GlxInitVisuals(
     VisualPtr *       visualp,
     DepthPtr *        depthp,

Index: glxscreens.c
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/GL/glx/glxscreens.c,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/glxscreens.c	26 Nov 2003 22:48:41 -0000	1.1.4.1
+++ b/glxscreens.c	23 Feb 2004 21:34:59 -0000	1.1.4.2
@@ -1,4 +1,4 @@
-/* $XFree86: xc/programs/Xserver/GL/glx/glxscreens.c,v 1.12 2003/09/28 20:15:43 alanh Exp $ */
+/* $XFree86: xc/programs/Xserver/GL/glx/glxscreens.c,v 1.15 2004/02/12 02:25:01 torrey Exp $ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
@@ -46,11 +46,13 @@
 #include "glxserver.h"
 #include "glxutil.h"
 
+const char GLServerVersion[] = "1.2";
 static const char GLServerExtensions[] = 
 			"GL_ARB_depth_texture "
 			"GL_ARB_imaging "
 			"GL_ARB_multitexture "
 			"GL_ARB_point_parameters "
+			"GL_ARB_point_sprite "
 			"GL_ARB_shadow "
 			"GL_ARB_shadow_ambient "
 			"GL_ARB_texture_border_clamp "
@@ -108,6 +110,7 @@
 			"GL_MESA_pack_invert "
 			"GL_MESA_ycbcr_texture "
 			"GL_NV_blend_square "
+			"GL_NV_point_sprite "
 			"GL_NV_texgen_reflection "
 			"GL_NV_texture_rectangle "
 			"GL_SGIS_generate_mipmap "
@@ -125,11 +128,15 @@
 */
 static char GLXServerVendorName[] = "SGI";
 static char GLXServerVersion[] = "1.2";
-static char GLXServerExtensions[] = 
+static char GLXServerExtensions[] =
+			"GLX_ARB_multisample "
 			"GLX_EXT_visual_info "
 			"GLX_EXT_visual_rating "
 			"GLX_EXT_import_context "
 			"GLX_SGI_make_current_read "
+#ifndef __DARWIN__
+			"GLX_SGIS_multisample "
+#endif
 			;
 
 /*

Index: glxserver.h
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/GL/glx/glxserver.h,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/glxserver.h	26 Nov 2003 22:48:41 -0000	1.1.4.1
+++ b/glxserver.h	23 Feb 2004 21:34:59 -0000	1.1.4.2
@@ -1,4 +1,4 @@
-/* $XFree86: xc/programs/Xserver/GL/glx/glxserver.h,v 1.5 2003/09/28 20:15:43 alanh Exp $ */
+/* $XFree86: xc/programs/Xserver/GL/glx/glxserver.h,v 1.6 2004/01/28 18:11:50 alanh Exp $ */
 #ifndef _GLX_server_h_
 #define _GLX_server_h_
 
@@ -280,5 +280,6 @@
 extern int __glXColorTableParameterivSize(GLenum pname);
 
 extern int __glXPointParameterfvARBReqSize(GLbyte *pc, Bool swap);
+extern int __glXPointParameterivReqSize(GLbyte *pc, Bool swap);
 
 #endif /* !__GLX_server_h__ */

Index: impsize.h
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/GL/glx/impsize.h,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/impsize.h	26 Nov 2003 22:48:41 -0000	1.1.4.1
+++ b/impsize.h	23 Feb 2004 21:34:59 -0000	1.1.4.2
@@ -1,4 +1,4 @@
-/* $XFree86: xc/programs/Xserver/GL/glx/impsize.h,v 1.4 2003/09/28 20:15:43 alanh Exp $ */
+/* $XFree86: xc/programs/Xserver/GL/glx/impsize.h,v 1.5 2004/01/28 18:11:50 alanh Exp $ */
 #ifndef _impsize_h_
 #define _impsize_h_
 
@@ -67,6 +67,7 @@
 extern int __glTexParameteriv_size(GLenum e);
 extern int __glEvalComputeK(GLenum target);
 
-extern int __glPointParameterfvARB_size(GLenum pname);
+extern int __glPointParameterfvARB_size(GLenum e);
+extern int __glPointParameteriv_size(GLenum e);
 
 #endif /* _impsize_h_ */

Index: render2.c
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/GL/glx/render2.c,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/render2.c	26 Nov 2003 22:48:41 -0000	1.1.4.1
+++ b/render2.c	23 Feb 2004 21:34:59 -0000	1.1.4.2
@@ -1,4 +1,4 @@
-/* $XFree86: xc/programs/Xserver/GL/glx/render2.c,v 1.6 2003/10/28 22:50:18 tsi Exp $ */
+/* $XFree86: xc/programs/Xserver/GL/glx/render2.c,v 1.9 2004/02/12 02:25:01 torrey Exp $ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
@@ -234,6 +234,16 @@
 	    glEnableClientState(GL_EDGE_FLAG_ARRAY);
 	    glEdgeFlagPointer(stride, (const GLboolean *)pc);
 	    break;
+#ifndef MISSING_GL_EXTS
+	  case GL_SECONDARY_COLOR_ARRAY:
+	    glEnableClientState(GL_SECONDARY_COLOR_ARRAY);
+	    glSecondaryColorPointer(numVals, datatype, stride, pc);
+	    break;
+	  case GL_FOG_COORDINATE_ARRAY:
+	    glEnableClientState(GL_FOG_COORDINATE_ARRAY);
+	    glFogCoordPointer(datatype, stride, pc);
+	    break;
+#endif
 	  default:
 	    break;
 	}
@@ -250,10 +260,11 @@
     glDisableClientState(GL_INDEX_ARRAY);
     glDisableClientState(GL_TEXTURE_COORD_ARRAY);
     glDisableClientState(GL_EDGE_FLAG_ARRAY);
+    glDisableClientState(GL_SECONDARY_COLOR_ARRAY);
+    glDisableClientState(GL_FOG_COORDINATE_ARRAY);
 }
 
 void __glXDisp_DrawArraysEXT(GLbyte *pc)
 {
-#ifdef XXX_STUB
-#endif /*XXX_STUB*/
+   __glXDisp_DrawArrays(pc);
 }

Index: render2swap.c
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/GL/glx/render2swap.c,v
retrieving revision 1.1
retrieving revision 1.1.4.1
diff -u -d -r1.1 -r1.1.4.1
--- a/render2swap.c	14 Nov 2003 16:48:51 -0000	1.1
+++ b/render2swap.c	23 Feb 2004 21:34:59 -0000	1.1.4.1
@@ -1,4 +1,4 @@
-/* $XFree86: xc/programs/Xserver/GL/glx/render2swap.c,v 1.6 2002/01/14 22:47:08 tsi Exp $ */
+/* $XFree86: xc/programs/Xserver/GL/glx/render2swap.c,v 1.7 2004/02/03 23:04:08 alanh Exp $ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
@@ -386,6 +386,5 @@
 
 void __glXDispSwap_DrawArraysEXT(GLbyte *pc)
 {
-#ifdef XXX_STUB
-#endif /*XXX_STUB*/
+   __glXDispSwap_DrawArrays(pc);
 }

Index: rensize.c
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/GL/glx/rensize.c,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/rensize.c	26 Nov 2003 22:48:41 -0000	1.1.4.1
+++ b/rensize.c	23 Feb 2004 21:34:59 -0000	1.1.4.2
@@ -1,4 +1,4 @@
-/* $XFree86: xc/programs/Xserver/GL/glx/rensize.c,v 1.6 2003/09/28 20:15:43 alanh Exp $ */
+/* $XFree86: xc/programs/Xserver/GL/glx/rensize.c,v 1.7 2004/01/28 18:11:53 alanh Exp $ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
@@ -551,12 +551,14 @@
 	  case GL_COLOR_ARRAY:
 	  case GL_TEXTURE_COORD_ARRAY:
 	    break;
+	  case GL_SECONDARY_COLOR_ARRAY:
 	  case GL_NORMAL_ARRAY:
 	    if (numVals != 3) {
 		/* bad size */
 		return -1;
 	    }
 	    break;
+	  case GL_FOG_COORDINATE_ARRAY:
 	  case GL_INDEX_ARRAY:
 	    if (numVals != 1) {
 		/* bad size */
@@ -918,3 +920,9 @@
     }
     return 4 * __glPointParameterfvARB_size( pname );
 }
+
+int __glXPointParameterivReqSize(GLbyte *pc, Bool swap )
+{
+    /* no difference between fv and iv versions */
+    return __glXPointParameterfvARBReqSize(pc, swap);
+}

Index: rensizetab.c
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/GL/glx/rensizetab.c,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/rensizetab.c	26 Nov 2003 22:48:41 -0000	1.1.4.1
+++ b/rensizetab.c	23 Feb 2004 21:34:59 -0000	1.1.4.2
@@ -1,4 +1,4 @@
-/* $XFree86: xc/programs/Xserver/GL/glx/rensizetab.c,v 1.4 2003/09/28 20:15:43 alanh Exp $ */
+/* $XFree86: xc/programs/Xserver/GL/glx/rensizetab.c,v 1.6 2004/02/03 23:04:08 alanh Exp $ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
@@ -231,9 +231,9 @@
 	/* Translatef          */	{  16, 	0                         },
 	/* Viewport            */	{  20, 	0                         },
 	/* PolygonOffset       */	{  12, 	0                         },
-	/* no such opcode      */	{  0, 	0                         },
+	/* DrawArrays          */	{  16, 	__glXDrawArraysSize       },
 	/* Indexubv            */	{  8, 	0                         },
-	/* ColorSubTable       */       {  44,  __glXColorSubTableReqSize         },
+	/* ColorSubTable       */       {  44,  __glXColorSubTableReqSize },
 	/* CopyColorSubTable   */       {  24,  0                         },
 	/* ActiveTextureARB    */       {  8,   0                         },
 	/* MultiTexCoord1dvARB */       {  16,  0                         },
@@ -2342,17 +2342,17 @@
 	/* CopyTexSubImage1D   */	{  28, 	0 },
 	/* CopyTexSubImage2D   */	{  36, 	0 },
 	/* CopyTexSubImage3D    4123 */ {  40,  0 },
-	/* no such opcode      */	{   0, 	0                         },
-	/* no such opcode      */	{   0, 	0                         },
-	/* no such opcode      */	{   0, 	0                         },
-	/* no such opcode      */	{   0, 	0                         },
-	/* no such opcode      */	{   0, 	0                         },
-	/* no such opcode      */	{   0, 	0                         },
-	/* no such opcode      */	{   0, 	0                         },
-	/* no such opcode      */	{   0, 	0                         },
-	/* no such opcode      */	{   0, 	0                         },
-	/* no such opcode      */	{   0, 	0                         },
-	/* no such opcode      */	{   0, 	0                         },
+	/* FogCoordfv           4124 */	{   8, 	0 },
+	/* FogCoorddv           4125 */	{  12, 	0 },
+	/* SecondaryColor3bv    4126 */	{   8, 	0 },
+	/* SecondaryColor3sv    4127 */	{  12, 	0 },
+	/* SecondaryColor3iv    4128 */	{  16, 	0 },
+	/* SecondaryColor3fv    4129 */	{  16, 	0 },
+	/* SecondaryColor3dv    4130 */	{  28, 	0 },
+	/* SecondaryColor3ubv   4131 */	{   8, 	0 },
+	/* SecondaryColor3usv   4132 */	{  12, 	0 },
+	/* SecondaryColor3uiv   4133 */	{  16, 	0 },
+	/* BlendFuncSeparate    4134 */	{  20, 	0 },
 	/* no such opcode      */	{   0, 	0                         },
 	/* no such opcode      */	{   0, 	0                         },
 	/* no such opcode      */	{   0, 	0                         },
@@ -2439,4 +2439,6 @@
 	/* no such opcode      */	{   0, 	0                         },
 	/* no such opcode      */	{   0, 	0                         },
 	/* ActiveStencilFaceEXT 4220 */ {   8,  0 },
+	/* PointParameteri      4221 */	{  12, 	0 },
+	/* PointParameteriv     4222 */	{   8, 	__glXPointParameterivReqSize },
 };

Index: single2.c
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/GL/glx/single2.c,v
retrieving revision 1.1
retrieving revision 1.1.4.1
diff -u -d -r1.1 -r1.1.4.1
--- a/single2.c	14 Nov 2003 16:48:51 -0000	1.1
+++ b/single2.c	23 Feb 2004 21:34:59 -0000	1.1.4.1
@@ -1,4 +1,4 @@
-/* $XFree86: xc/programs/Xserver/GL/glx/single2.c,v 1.6 2001/06/06 19:00:15 dawes Exp $ */
+/* $XFree86: xc/programs/Xserver/GL/glx/single2.c,v 1.9 2004/02/11 09:18:15 alanh Exp $ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
@@ -296,16 +296,25 @@
    return combo_string;
 }
 
-int __glXDisp_GetString(__GLXclientState *cl, GLbyte *pc)
+int DoGetString(__GLXclientState *cl, GLbyte *pc, GLboolean need_swap)
 {
     ClientPtr client;
     __GLXcontext *cx;
     GLenum name;
     const char *string;
+    __GLX_DECLARE_SWAP_VARIABLES;
     int error;
     char *buf = NULL, *buf1 = NULL;
     GLint length = 0;
 
+    /* If the client has the opposite byte order, swap the contextTag and
+     * the name.
+     */
+    if ( need_swap ) {
+	__GLX_SWAP_INT(pc + 4);
+	__GLX_SWAP_INT(pc + __GLX_SINGLE_HDR_SIZE);
+    }
+
     cx = __glXForceCurrent(cl, __GLX_GET_SINGLE_CONTEXT_TAG(pc), &error);
     if (!cx) {
 	return error;
@@ -331,12 +340,32 @@
 	}
 	string = buf;
     }
+    else if ( name == GL_VERSION ) {
+	if ( atof( string ) > atof( GLServerVersion ) ) {
+	    buf = __glXMalloc( __glXStrlen( string ) 
+			       + __glXStrlen( GLServerVersion )
+			       + 3 );
+	    if ( buf == NULL ) {
+		string = GLServerVersion;
+	    }
+	    else {
+		__glXSprintf( buf, "%s (%s)", GLServerVersion, string );
+		string = buf;
+	    }
+	}
+    }
     if (string) {
 	length = __glXStrlen((const char *) string) + 1;
     }
 
     __GLX_BEGIN_REPLY(length);
     __GLX_PUT_SIZE(length);
+
+    if ( need_swap ) {
+	__GLX_SWAP_REPLY_SIZE();
+	__GLX_SWAP_REPLY_HEADER();
+    }
+
     __GLX_SEND_HEADER();
     WriteToClient(client, length, (char *) string); 
     if (buf != NULL) {
@@ -345,6 +374,11 @@
     return Success;
 }
 
+int __glXDisp_GetString(__GLXclientState *cl, GLbyte *pc)
+{
+    return DoGetString(cl, pc, GL_FALSE);
+}
+
 int __glXDisp_GetClipPlane(__GLXclientState *cl, GLbyte *pc)
 {
     __GLXcontext *cx;

Index: single2swap.c
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/GL/glx/single2swap.c,v
retrieving revision 1.1
retrieving revision 1.1.4.1
diff -u -d -r1.1 -r1.1.4.1
--- a/single2swap.c	14 Nov 2003 16:48:51 -0000	1.1
+++ b/single2swap.c	23 Feb 2004 21:34:59 -0000	1.1.4.1
@@ -1,4 +1,4 @@
-/* $XFree86: xc/programs/Xserver/GL/glx/single2swap.c,v 1.7 2002/01/14 22:47:08 tsi Exp $ */
+/* $XFree86: xc/programs/Xserver/GL/glx/single2swap.c,v 1.8 2004/02/09 23:46:31 alanh Exp $ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
@@ -262,58 +262,7 @@
 
 int __glXDispSwap_GetString(__GLXclientState *cl, GLbyte *pc)
 {
-    ClientPtr client;
-    __GLXcontext *cx;
-    GLenum name;
-    const char *string;
-    __GLX_DECLARE_SWAP_VARIABLES;
-    int error;
-    char *buf = NULL, *buf1 = NULL;
-    GLint length = 0;
-
-    __GLX_SWAP_INT(&((xGLXSingleReq *)pc)->contextTag);
-    cx = __glXForceCurrent(cl, __GLX_GET_SINGLE_CONTEXT_TAG(pc), &error);
-    if (!cx) {
-	return error;
-    }
-
-    pc += __GLX_SINGLE_HDR_SIZE;
-    __GLX_SWAP_INT(pc + 0);
-    name = *(GLenum *)(pc + 0);
-    string = (const char *)glGetString(name);
-    client = cl->client;
-
-    /*
-    ** Restrict extensions to those that are supported by both the
-    ** implementation and the connection.  That is, return the
-    ** intersection of client, server, and core extension strings.
-    */
-    if (name == GL_EXTENSIONS) {
-	buf1 = __glXcombine_strings(string,
-				      cl->GLClientextensions);
-	buf = __glXcombine_strings(buf1,
-				      cx->pGlxScreen->GLextensions);
-	if (buf1 != NULL) {
-	    __glXFree(buf1);
-	}
-	string = buf;
-    }
-    if (string) {
-	length = __glXStrlen((const char *) string) + 1;
-    }
-
-    __GLX_BEGIN_REPLY(length);
-    __GLX_PUT_SIZE(length);
-
-    __GLX_SWAP_REPLY_SIZE();
-    __GLX_SWAP_REPLY_HEADER();
-    __GLX_SEND_HEADER();
-    WriteToClient(client, length, (char *) string); 
-    if (buf != NULL) {
-	__glXFree(buf);
-    }
-
-    return Success;
+    return DoGetString(cl, pc, GL_TRUE);
 }
 
 int __glXDispSwap_GetClipPlane(__GLXclientState *cl, GLbyte *pc)

Index: singlesize.c
===================================================================
RCS file: /cvs/xorg/xc/programs/Xserver/GL/glx/singlesize.c,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/singlesize.c	26 Nov 2003 22:48:41 -0000	1.1.4.1
+++ b/singlesize.c	23 Feb 2004 21:34:59 -0000	1.1.4.2
@@ -1,4 +1,4 @@
-/* $XFree86: xc/programs/Xserver/GL/glx/singlesize.c,v 1.6 2003/11/06 18:37:56 tsi Exp $ */
+/* $XFree86: xc/programs/Xserver/GL/glx/singlesize.c,v 1.8 2004/02/09 19:51:32 tsi Exp $ */
 /*
 ** License Applicability. Except to the extent portions of this file are
 ** made subject to an alternative license as permitted in the SGI Free
@@ -50,32 +50,48 @@
     return __glXImage3DSize( format, type, w, h, 1, 0, 0, 0, 0, 4 );
 }
 
+/**
+ * Determine the number of data elements that go with the specified \c pname
+ * to a \c glGetTexEnvfv or \c glGetTexEnviv call.
+ * 
+ * \todo
+ * Replace this function with a call to \c __glTexEnvfv_size.  Make that there
+ * aren't any values of \c pname that are valid for one but not the other.
+ */
 GLint __glGetTexEnvfv_size(GLenum pname)
 {
     switch (pname) {
       case GL_TEXTURE_ENV_MODE:
+      case GL_TEXTURE_LOD_BIAS:
+      case GL_COMBINE_RGB:
+      case GL_COMBINE_ALPHA:
+      case GL_SOURCE0_RGB:
+      case GL_SOURCE1_RGB:
+      case GL_SOURCE2_RGB:
+      case GL_SOURCE0_ALPHA:
+      case GL_SOURCE1_ALPHA:
+      case GL_SOURCE2_ALPHA:
+      case GL_OPERAND0_RGB:
+      case GL_OPERAND1_RGB:
+      case GL_OPERAND2_RGB:
+      case GL_OPERAND0_ALPHA:
+      case GL_OPERAND1_ALPHA:
+      case GL_OPERAND2_ALPHA:
+      case GL_RGB_SCALE:
+      case GL_ALPHA_SCALE:
+	
+      /* GL_ARB_point_sprite / GL_NV_point_sprite */
+      case GL_COORD_REPLACE_NV:
+
+      /* GL_NV_texture_env_combine4 */
+      case GL_SOURCE3_RGB_NV:
+      case GL_SOURCE3_ALPHA_NV:
+      case GL_OPERAND3_RGB_NV:
+      case GL_OPERAND3_ALPHA_NV:
 	return 1;
+
       case GL_TEXTURE_ENV_COLOR:
 	return 4;
-      case GL_TEXTURE_LOD_BIAS_EXT:
-	return 1;
-      case GL_COMBINE_RGB_ARB:
-      case GL_COMBINE_ALPHA_ARB:
-      case GL_SOURCE0_RGB_ARB:
-      case GL_SOURCE1_RGB_ARB:
-      case GL_SOURCE2_RGB_ARB:
-      case GL_SOURCE0_ALPHA_ARB:
-      case GL_SOURCE1_ALPHA_ARB:
-      case GL_SOURCE2_ALPHA_ARB:
-      case GL_OPERAND0_RGB_ARB:
-      case GL_OPERAND1_RGB_ARB:
-      case GL_OPERAND2_RGB_ARB:
-      case GL_OPERAND0_ALPHA_ARB:
-      case GL_OPERAND1_ALPHA_ARB:
-      case GL_OPERAND2_ALPHA_ARB:
-      case GL_RGB_SCALE_ARB:
-      case GL_ALPHA_SCALE:
-	return 1;
       default:
 	return -1;
     }
@@ -140,6 +156,15 @@
       case GL_TEXTURE_COMPARE_MODE:
       case GL_TEXTURE_COMPARE_FUNC:
 
+      /* GL_SGIS_generate_mipmap / GL 1.4 */
+      case GL_GENERATE_MIPMAP:
+
+      /* GL_ARB_depth_texture / GL 1.4 */
+      case GL_DEPTH_TEXTURE_MODE:
+
+      /* GL_EXT_texture_lod_bias / GL 1.4 */
+      case GL_TEXTURE_LOD_BIAS:
+
       /* GL_SGIX_shadow_ambient / GL_ARB_shadow_ambient */
       case GL_TEXTURE_COMPARE_FAIL_VALUE_ARB:
 
@@ -151,6 +176,9 @@
       case GL_TEXTURE_MAX_CLAMP_S_SGIX:
       case GL_TEXTURE_MAX_CLAMP_T_SGIX:
       case GL_TEXTURE_MAX_CLAMP_R_SGIX:
+
+      /* GL_EXT_texture_filter_anisotropic */
+      case GL_TEXTURE_MAX_ANISOTROPY_EXT:
 	return 1;
 
       default:
@@ -834,10 +862,6 @@
       case GL_MAX_CONVOLUTION_WIDTH:
       case GL_MAX_CONVOLUTION_HEIGHT:
 	return 1;
-      case GL_TEXTURE_CUBE_MAP_ARB:
-      case GL_TEXTURE_BINDING_CUBE_MAP_ARB:
-      case GL_MAX_CUBE_MAP_TEXTURE_SIZE_ARB:
-	return 1;
       case GL_OCCLUSION_TEST_RESULT_HP:
       case GL_OCCLUSION_TEST_HP:
 	return 1;
@@ -847,6 +871,183 @@
 	return 1;
       case GL_RASTER_POSITION_UNCLIPPED_IBM:
 	return 1;
+
+      /* GL_ARB_texture_cube_map / GL 1.3 */
+      case GL_TEXTURE_CUBE_MAP:
+      case GL_TEXTURE_BINDING_CUBE_MAP:
+      case GL_MAX_CUBE_MAP_TEXTURE_SIZE:
+
+      /* GL_ARB_multisample / GL 1.3 */
+      case GL_MULTISAMPLE:
+      case GL_SAMPLE_ALPHA_TO_COVERAGE:
+      case GL_SAMPLE_ALPHA_TO_ONE:
+      case GL_SAMPLE_COVERAGE:
+      case GL_SAMPLE_BUFFERS:
+      case GL_SAMPLES:
+      case GL_SAMPLE_COVERAGE_VALUE:
+      case GL_SAMPLE_COVERAGE_INVERT:
+
+      /* GL_ARB_texture_comrpession / GL 1.3 */
+      case GL_TEXTURE_COMPRESSION_HINT:
+      case GL_NUM_COMPRESSED_TEXTURE_FORMATS:
+	
+      /* GL_EXT_blend_func_separate / GL 1.4 */
+      case GL_BLEND_DST_RGB:
+      case GL_BLEND_SRC_RGB:
+      case GL_BLEND_DST_ALPHA:
+      case GL_BLEND_SRC_ALPHA:
+
+      /* GL_EXT_fog_coord / GL 1.4 */
+      case GL_CURRENT_FOG_COORDINATE:
+      case GL_FOG_COORDINATE_ARRAY_TYPE:
+      case GL_FOG_COORDINATE_ARRAY_STRIDE:
+      case GL_FOG_COORDINATE_ARRAY:
+      case GL_FOG_COORDINATE_SOURCE:
+
+      /* GL_EXT_secondary_color / GL 1.4 */
+      case GL_COLOR_SUM:
+      case GL_SECONDARY_COLOR_ARRAY_SIZE:
+      case GL_SECONDARY_COLOR_ARRAY_TYPE:
+      case GL_SECONDARY_COLOR_ARRAY_STRIDE:
+      case GL_SECONDARY_COLOR_ARRAY:
+
+      /* GL_EXT_texture_lod_bias / GL 1.4 */
+      case GL_MAX_TEXTURE_LOD_BIAS:
+
+      /* GL_ARB_point_sprite */
+      case GL_POINT_SPRITE_NV:
+
+      /* GL_ARB_vertex_blend */
+      case GL_MAX_VERTEX_UNITS_ARB:
+      case GL_ACTIVE_VERTEX_UNITS_ARB:
+      case GL_WEIGHT_SUM_UNITY_ARB:
+      case GL_VERTEX_BLEND_ARB:
+      case GL_CURRENT_WEIGHT_ARB:
+      case GL_WEIGHT_ARRAY_ARB:
+      case GL_WEIGHT_ARRAY_TYPE_ARB:
+      case GL_WEIGHT_ARRAY_STRIDE_ARB:
+      case GL_WEIGHT_ARRAY_SIZE_ARB:
+
+      /* GL_ARB_matrix_palette */
+      case GL_MATRIX_PALETTE_ARB:
+      case GL_MAX_MATRIX_PALETTE_STACK_DEPTH_ARB:
+      case GL_MAX_PALETTE_MATRICES_ARB:
+      case GL_CURRENT_PALETTE_MATRIX_ARB:
+      case GL_CURRENT_MATRIX_INDEX_ARB:
+      case GL_MATRIX_INDEX_ARRAY_ARB:
+      case GL_MATRIX_INDEX_ARRAY_SIZE_ARB:
+      case GL_MATRIX_INDEX_ARRAY_TYPE_ARB:
+      case GL_MATRIX_INDEX_ARRAY_STRIDE_ARB:
+
+      /* GL_EXT_clip_volume_hint */
+      case GL_CLIP_VOLUME_CLIPPING_HINT_EXT:
+
+      /* GL_EXT_stencil_two_size */
+      case GL_STENCIL_TEST_TWO_SIDE_EXT:
+      case GL_ACTIVE_STENCIL_FACE_EXT:
+
+      /* GL_EXT_vertex_weighting */
+      case GL_VERTEX_WEIGHTING_EXT:
+      case GL_MODELVIEW0_EXT:
+      case GL_MODELVIEW1_EXT:
+      case GL_CURRENT_VERTEX_WEIGHT_EXT:
+      case GL_VERTEX_WEIGHT_ARRAY_EXT:
+      case GL_VERTEX_WEIGHT_ARRAY_SIZE_EXT:
+      case GL_VERTEX_WEIGHT_ARRAY_TYPE_EXT:
+      case GL_VERTEX_WEIGHT_ARRAY_STRIDE_EXT:
+      /* case GL_MODELVIEW0_STACK_DEPTH_EXT: */ /* alias */
+      case GL_MODELVIEW1_STACK_DEPTH_EXT:
+
+      /* GL_ATI_vertex_streams */
+      case GL_MAX_VERTEX_STREAMS_ATI:
+
+      /* GL_NV_depth_clamp */
+      case GL_DEPTH_CLAMP_NV:
+
+      /* GL_NV_fog_distance */
+      case GL_FOG_DISTANCE_MODE_NV:
+
+      /* GL_NV_light_max_exponent */
+      case GL_MAX_SHININESS_NV:
+      case GL_MAX_SPOT_EXPONENT_NV:
+
+      /* GL_NV_multisample_filter_hint */
+      case GL_MULTISAMPLE_FILTER_HINT_NV:
+
+      /* GL_NV_point_sprite */
+      /* case GL_POINT_SPRITE_NV: */ /* alias */
+      case GL_POINT_SPRITE_R_MODE_NV:
+
+      /* GL_NV_register_combiners */
+      case GL_REGISTER_COMBINERS_NV:
+      case GL_NUM_GENERAL_COMBINERS_NV:
+      case GL_COLOR_SUM_CLAMP_NV:
+      case GL_MAX_GENERAL_COMBINERS_NV:
+
+      /* GL_NV_register_combiners2 */
+      case GL_PER_STAGE_CONSTANTS_NV:
+
+      /* GL_NV_texture_rectangle */
+      case GL_TEXTURE_RECTANGLE_NV:
+      case GL_TEXTURE_BINDING_RECTANGLE_NV:
+      case GL_MAX_RECTANGLE_TEXTURE_SIZE_NV:
+	return 1;
+
+      /* GL_EXT_secondary_color / GL 1.4 */
+      case GL_CURRENT_SECONDARY_COLOR:
+
+      /* GL_NV_register_combiners */
+      case GL_CONSTANT_COLOR0_NV:
+      case GL_CONSTANT_COLOR1_NV:
+	return 4;
+
+      /* GL_ARB_vertex_blend */
+      /* case GL_MODELVIEW0_ARB: */ /* alias */
+      /* case GL_MODELVIEW1_ARB: */ /* alias */
+      case GL_MODELVIEW2_ARB:
+      case GL_MODELVIEW3_ARB:
+      case GL_MODELVIEW4_ARB:
+      case GL_MODELVIEW5_ARB:
+      case GL_MODELVIEW6_ARB:
+      case GL_MODELVIEW7_ARB:
+      case GL_MODELVIEW8_ARB:
+      case GL_MODELVIEW9_ARB:
+      case GL_MODELVIEW10_ARB:
+      case GL_MODELVIEW11_ARB:
+      case GL_MODELVIEW12_ARB:
+      case GL_MODELVIEW13_ARB:
+      case GL_MODELVIEW14_ARB:
+      case GL_MODELVIEW15_ARB:
+      case GL_MODELVIEW16_ARB:
+      case GL_MODELVIEW17_ARB:
+      case GL_MODELVIEW18_ARB:
+      case GL_MODELVIEW19_ARB:
+      case GL_MODELVIEW20_ARB:
+      case GL_MODELVIEW21_ARB:
+      case GL_MODELVIEW22_ARB:
+      case GL_MODELVIEW23_ARB:
+      case GL_MODELVIEW24_ARB:
+      case GL_MODELVIEW25_ARB:
+      case GL_MODELVIEW26_ARB:
+      case GL_MODELVIEW27_ARB:
+      case GL_MODELVIEW28_ARB:
+      case GL_MODELVIEW29_ARB:
+      case GL_MODELVIEW30_ARB:
+      case GL_MODELVIEW31_ARB:
+
+      /* GL_EXT_vertex_weighting */
+      /* case GL_MODELVIEW0_MATRIX_EXT: */ /* alias */
+      case GL_MODELVIEW1_MATRIX_EXT:
+	return 32;
+
+      /* GL_ARB_texture_comrpession / GL 1.3 */
+      case GL_COMPRESSED_TEXTURE_FORMATS: {
+	  GLint temp;
+	  
+	  glGetIntegerv( GL_NUM_COMPRESSED_TEXTURE_FORMATS, & temp );
+	  return temp;
+      }
+
       default:
 	return -1;
     }
@@ -886,7 +1087,15 @@
       case GL_TEXTURE_ALPHA_SIZE:
       case GL_TEXTURE_LUMINANCE_SIZE:
       case GL_TEXTURE_INTENSITY_SIZE:
+
+      /* GL_ARB_texture_compression / GL 1.3 */
+      case GL_TEXTURE_COMPRESSED_IMAGE_SIZE:
+      case GL_TEXTURE_COMPRESSED:
+
+      /* GL_ARB_depth_texture / GL 1.4 */
+      case GL_TEXTURE_DEPTH_SIZE:
 	return 1;
+
       default:
 	return -1;
     }





More information about the xorg-commit mailing list