Merge branch 'master' of git://anongit.freedesktop.org/git/xorg/xserver

This commit is contained in:
Matthias Hopf 2006-08-24 20:17:10 +02:00
commit 4ed311cf1c
42 changed files with 2375 additions and 3888 deletions

View File

@ -61,6 +61,8 @@ libglx_la_SOURCES = \
indirect_reqsize.h \
indirect_size_get.c \
indirect_size_get.h \
indirect_table.c \
indirect_table.h \
indirect_util.c \
indirect_util.h \
render2.c \
@ -68,7 +70,6 @@ libglx_la_SOURCES = \
renderpix.c \
renderpixswap.c \
rensize.c \
rensizetab.c \
single2.c \
single2swap.c \
singlepix.c \

View File

@ -37,169 +37,6 @@
#include "g_disptab.h"
#include "indirect_dispatch.h"
__GLXdispatchSingleProcPtr __glXSingleTable[__GLX_SINGLE_TABLE_SIZE] = {
__glXNoSuchSingleOpcode,
__glXRender,
__glXRenderLarge,
__glXCreateContext,
__glXDestroyContext,
__glXMakeCurrent,
__glXIsDirect,
__glXQueryVersion,
__glXWaitGL, /* 0x08 */
__glXWaitX,
__glXCopyContext,
__glXSwapBuffers,
__glXUseXFont,
__glXCreateGLXPixmap,
__glXGetVisualConfigs,
__glXDestroyGLXPixmap,
__glXVendorPrivate, /* 0x10 */
__glXVendorPrivateWithReply,
__glXQueryExtensionsString,
__glXQueryServerString,
__glXClientInfo,
__glXGetFBConfigs,
__glXCreatePixmap,
__glXDestroyPixmap,
__glXCreateNewContext, /* 0x18 */
__glXQueryContext,
__glXMakeContextCurrent,
__glXCreatePbuffer,
__glXDestroyPbuffer,
__glXGetDrawableAttributes,
__glXChangeDrawableAttributes,
__glXCreateWindow,
__glXDestroyWindow, /* 0x20 */
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXDisp_NewList,
__glXDisp_EndList,
__glXDisp_DeleteLists,
__glXDisp_GenLists,
__glXDisp_FeedbackBuffer,
__glXDisp_SelectBuffer,
__glXDisp_RenderMode,
__glXDisp_Finish,
__glXDisp_PixelStoref,
__glXDisp_PixelStorei,
__glXDisp_ReadPixels,
__glXDisp_GetBooleanv,
__glXDisp_GetClipPlane,
__glXDisp_GetDoublev,
__glXDisp_GetError,
__glXDisp_GetFloatv,
__glXDisp_GetIntegerv,
__glXDisp_GetLightfv,
__glXDisp_GetLightiv,
__glXDisp_GetMapdv,
__glXDisp_GetMapfv,
__glXDisp_GetMapiv,
__glXDisp_GetMaterialfv,
__glXDisp_GetMaterialiv,
__glXDisp_GetPixelMapfv,
__glXDisp_GetPixelMapuiv,
__glXDisp_GetPixelMapusv,
__glXDisp_GetPolygonStipple,
__glXDisp_GetString,
__glXDisp_GetTexEnvfv,
__glXDisp_GetTexEnviv,
__glXDisp_GetTexGendv,
__glXDisp_GetTexGenfv,
__glXDisp_GetTexGeniv,
__glXDisp_GetTexImage,
__glXDisp_GetTexParameterfv,
__glXDisp_GetTexParameteriv,
__glXDisp_GetTexLevelParameterfv,
__glXDisp_GetTexLevelParameteriv,
__glXDisp_IsEnabled,
__glXDisp_IsList,
__glXDisp_Flush,
__glXDisp_AreTexturesResident,
__glXDisp_DeleteTextures,
__glXDisp_GenTextures,
__glXDisp_IsTexture,
__glXDisp_GetColorTable,
__glXDisp_GetColorTableParameterfv,
__glXDisp_GetColorTableParameteriv,
__glXDisp_GetConvolutionFilter,
__glXDisp_GetConvolutionParameterfv,
__glXDisp_GetConvolutionParameteriv,
__glXDisp_GetSeparableFilter,
__glXDisp_GetHistogram,
__glXDisp_GetHistogramParameterfv,
__glXDisp_GetHistogramParameteriv,
__glXDisp_GetMinmax,
__glXDisp_GetMinmaxParameterfv,
__glXDisp_GetMinmaxParameteriv,
};
__GLXdispatchRenderProcPtr __glXRenderTable[] = {
__glXNoSuchRenderOpcode,
__glXDisp_CallList,
@ -438,168 +275,6 @@ __GLXdispatchRenderProcPtr __glXRenderTable[] = {
#endif
};
__GLXdispatchSingleProcPtr __glXSwapSingleTable[__GLX_SINGLE_TABLE_SIZE] = {
__glXNoSuchSingleOpcode,
__glXSwapRender,
__glXSwapRenderLarge,
__glXSwapCreateContext,
__glXSwapDestroyContext,
__glXSwapMakeCurrent,
__glXSwapIsDirect,
__glXSwapQueryVersion,
__glXSwapWaitGL, /* 0x08 */
__glXSwapWaitX,
__glXSwapCopyContext,
__glXSwapSwapBuffers,
__glXSwapUseXFont,
__glXSwapCreateGLXPixmap,
__glXSwapGetVisualConfigs,
__glXSwapDestroyGLXPixmap,
__glXSwapVendorPrivate, /* 0x10 */
__glXSwapVendorPrivateWithReply,
__glXSwapQueryExtensionsString,
__glXSwapQueryServerString,
__glXSwapClientInfo,
__glXSwapGetFBConfigs,
__glXSwapCreatePixmap,
__glXSwapDestroyPixmap,
__glXSwapCreateNewContext, /* 0x18 */
__glXSwapQueryContext,
__glXSwapMakeContextCurrent,
__glXSwapCreatePbuffer,
__glXSwapDestroyPbuffer,
__glXSwapGetDrawableAttributes,
__glXSwapChangeDrawableAttributes,
__glXSwapCreateWindow,
__glXSwapDestroyWindow, /* 0x20 */
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXNoSuchSingleOpcode,
__glXDispSwap_NewList,
__glXDispSwap_EndList,
__glXDispSwap_DeleteLists,
__glXDispSwap_GenLists,
__glXDispSwap_FeedbackBuffer,
__glXDispSwap_SelectBuffer,
__glXDispSwap_RenderMode,
__glXDispSwap_Finish,
__glXDispSwap_PixelStoref,
__glXDispSwap_PixelStorei,
__glXDispSwap_ReadPixels,
__glXDispSwap_GetBooleanv,
__glXDispSwap_GetClipPlane,
__glXDispSwap_GetDoublev,
__glXDispSwap_GetError,
__glXDispSwap_GetFloatv,
__glXDispSwap_GetIntegerv,
__glXDispSwap_GetLightfv,
__glXDispSwap_GetLightiv,
__glXDispSwap_GetMapdv,
__glXDispSwap_GetMapfv,
__glXDispSwap_GetMapiv,
__glXDispSwap_GetMaterialfv,
__glXDispSwap_GetMaterialiv,
__glXDispSwap_GetPixelMapfv,
__glXDispSwap_GetPixelMapuiv,
__glXDispSwap_GetPixelMapusv,
__glXDispSwap_GetPolygonStipple,
__glXDispSwap_GetString,
__glXDispSwap_GetTexEnvfv,
__glXDispSwap_GetTexEnviv,
__glXDispSwap_GetTexGendv,
__glXDispSwap_GetTexGenfv,
__glXDispSwap_GetTexGeniv,
__glXDispSwap_GetTexImage,
__glXDispSwap_GetTexParameterfv,
__glXDispSwap_GetTexParameteriv,
__glXDispSwap_GetTexLevelParameterfv,
__glXDispSwap_GetTexLevelParameteriv,
__glXDispSwap_IsEnabled,
__glXDispSwap_IsList,
__glXDispSwap_Flush,
__glXDispSwap_AreTexturesResident,
__glXDispSwap_DeleteTextures,
__glXDispSwap_GenTextures,
__glXDispSwap_IsTexture,
__glXDispSwap_GetColorTable,
__glXDispSwap_GetColorTableParameterfv,
__glXDispSwap_GetColorTableParameteriv,
__glXDispSwap_GetConvolutionFilter,
__glXDispSwap_GetConvolutionParameterfv,
__glXDispSwap_GetConvolutionParameteriv,
__glXDispSwap_GetSeparableFilter,
__glXDispSwap_GetHistogram,
__glXDispSwap_GetHistogramParameterfv,
__glXDispSwap_GetHistogramParameteriv,
__glXDispSwap_GetMinmax,
__glXDispSwap_GetMinmaxParameterfv,
__glXDispSwap_GetMinmaxParameteriv,
};
__GLXdispatchRenderProcPtr __glXSwapRenderTable[__GLX_RENDER_TABLE_SIZE] = {
__glXNoSuchRenderOpcode,

View File

@ -34,97 +34,33 @@
** version 1.2.1 Specification.
*/
extern int __glXRender(__GLXclientState*, GLbyte*);
extern int __glXRenderLarge(__GLXclientState*, GLbyte*);
extern int __glXCreateContext(__GLXclientState*, GLbyte*);
extern int __glXDestroyContext(__GLXclientState*, GLbyte*);
extern int __glXMakeCurrent(__GLXclientState*, GLbyte*);
extern int __glXIsDirect(__GLXclientState*, GLbyte*);
extern int __glXQueryVersion(__GLXclientState*, GLbyte*);
extern int __glXWaitGL(__GLXclientState*, GLbyte*);
extern int __glXWaitX(__GLXclientState*, GLbyte*);
extern int __glXCopyContext(__GLXclientState*, GLbyte*);
extern int __glXSwapBuffers(__GLXclientState*, GLbyte*);
extern int __glXBindTexImageEXT(__GLXclientState *cl, GLbyte *pc);
extern int __glXReleaseTexImageEXT(__GLXclientState *cl, GLbyte *pc);
extern int __glXCopySubBufferMESA(__GLXclientState *cl, GLbyte *pc);
extern int __glXGetDrawableAttributesSGIX(__GLXclientState *cl, GLbyte *pc);
extern int __glXUseXFont(__GLXclientState*, GLbyte*);
extern int __glXCreateGLXPixmap(__GLXclientState*, GLbyte*);
extern int __glXGetVisualConfigs(__GLXclientState*, GLbyte*);
extern int __glXDestroyGLXPixmap(__GLXclientState*, GLbyte*);
extern int __glXVendorPrivate(__GLXclientState*, GLbyte*);
extern int __glXVendorPrivateWithReply(__GLXclientState*, GLbyte*);
extern int __glXQueryExtensionsString(__GLXclientState*, GLbyte*);
extern int __glXQueryServerString(__GLXclientState*, GLbyte*);
extern int __glXClientInfo(__GLXclientState*, GLbyte*);
extern int __glXMakeContextCurrent(__GLXclientState*, GLbyte*);
extern int __glXGetFBConfigs(__GLXclientState*, GLbyte*);
extern int __glXCreatePixmap(__GLXclientState*, GLbyte*);
extern int __glXDestroyPixmap(__GLXclientState*, GLbyte*);
extern int __glXCreateNewContext(__GLXclientState*, GLbyte*);
extern int __glXQueryContext(__GLXclientState*, GLbyte*);
extern int __glXMakeContextCurrent(__GLXclientState*, GLbyte*);
extern int __glXCreatePbuffer(__GLXclientState*, GLbyte*);
extern int __glXDestroyPbuffer(__GLXclientState*, GLbyte*);
extern int __glXGetDrawableAttributes(__GLXclientState*, GLbyte*);
extern int __glXChangeDrawableAttributes(__GLXclientState*, GLbyte*);
extern int __glXCreateWindow(__GLXclientState*, GLbyte*);
extern int __glXDestroyWindow(__GLXclientState*, GLbyte*);
extern int __glXDisp_CopySubBufferMESA(__GLXclientState *cl, GLbyte *pc);
extern int __glXDisp_GetDrawableAttributesSGIX(__GLXclientState *cl, GLbyte *pc);
extern int __glXDisp_BindSwapBarrierSGIX(__GLXclientState *cl, GLbyte *pc);
extern int __glXDisp_QueryMaxSwapBarriersSGIX(__GLXclientState *cl, GLbyte *pc);
extern int __glXDisp_QueryHyperpipeNetworkSGIX(__GLXclientState *cl, GLbyte *pc);
extern int __glXDisp_DestroyHyperpipeConfigSGIX (__GLXclientState *cl, GLbyte *pc);
extern int __glXDisp_QueryHyperpipeConfigSGIX(__GLXclientState *cl, GLbyte *pc);
extern int __glXDisp_HyperpipeConfigSGIX(__GLXclientState *cl, GLbyte *pc);
extern int __glXDispSwap_CopySubBufferMESA(__GLXclientState *cl, GLbyte *pc);
extern int __glXDispSwap_GetDrawableAttributesSGIX(__GLXclientState *cl, GLbyte *pc);
extern int __glXDispSwap_BindSwapBarrierSGIX(__GLXclientState *cl, GLbyte *pc);
extern int __glXDispSwap_QueryMaxSwapBarriersSGIX(__GLXclientState *cl, GLbyte *pc);
extern int __glXDispSwap_QueryHyperpipeNetworkSGIX(__GLXclientState *cl, GLbyte *pc);
extern int __glXDispSwap_DestroyHyperpipeConfigSGIX (__GLXclientState *cl, GLbyte *pc);
extern int __glXDispSwap_QueryHyperpipeConfigSGIX(__GLXclientState *cl, GLbyte *pc);
extern int __glXDispSwap_HyperpipeConfigSGIX(__GLXclientState *cl, GLbyte *pc);
extern int __glXSwapRender(__GLXclientState*, GLbyte*);
extern int __glXSwapRenderLarge(__GLXclientState*, GLbyte*);
extern int __glXSwapCreateContext(__GLXclientState*, GLbyte*);
extern int __glXSwapDestroyContext(__GLXclientState*, GLbyte*);
extern int __glXSwapMakeCurrent(__GLXclientState*, GLbyte*);
extern int __glXSwapIsDirect(__GLXclientState*, GLbyte*);
extern int __glXSwapQueryVersion(__GLXclientState*, GLbyte*);
extern int __glXSwapWaitGL(__GLXclientState*, GLbyte*);
extern int __glXSwapWaitX(__GLXclientState*, GLbyte*);
extern int __glXSwapCopyContext(__GLXclientState*, GLbyte*);
extern int __glXSwapSwapBuffers(__GLXclientState*, GLbyte*);
extern int __glXSwapBindTexImageEXT(__GLXclientState *cl, GLbyte *pc);
extern int __glXSwapReleaseTexImageEXT(__GLXclientState *cl, GLbyte *pc);
extern int __glXSwapReleaseTexImageEXT(__GLXclientState *cl, GLbyte *pc);
extern int __glXSwapGetDrawableAttributesSGIX(__GLXclientState *cl, GLbyte *pc);
extern int __glXSwapUseXFont(__GLXclientState*, GLbyte*);
extern int __glXSwapCreateGLXPixmap(__GLXclientState*, GLbyte*);
extern int __glXSwapGetVisualConfigs(__GLXclientState*, GLbyte*);
extern int __glXSwapDestroyGLXPixmap(__GLXclientState*, GLbyte*);
extern int __glXSwapVendorPrivate(__GLXclientState*, GLbyte*);
extern int __glXSwapVendorPrivateWithReply(__GLXclientState*, GLbyte*);
extern int __glXSwapQueryExtensionsString(__GLXclientState*, GLbyte*);
extern int __glXSwapQueryServerString(__GLXclientState*, GLbyte*);
extern int __glXSwapClientInfo(__GLXclientState*, GLbyte*);
extern int __glXSwapMakeContextCurrent(__GLXclientState*, GLbyte*);
extern int __glXSwapGetFBConfigs(__GLXclientState*, GLbyte*);
extern int __glXSwapCreatePixmap(__GLXclientState*, GLbyte*);
extern int __glXSwapDestroyPixmap(__GLXclientState*, GLbyte*);
extern int __glXSwapCreateNewContext(__GLXclientState*, GLbyte*);
extern int __glXSwapQueryContext(__GLXclientState*, GLbyte*);
extern int __glXSwapMakeContextCurrent(__GLXclientState*, GLbyte*);
extern int __glXSwapCreatePbuffer(__GLXclientState*, GLbyte*);
extern int __glXSwapDestroyPbuffer(__GLXclientState*, GLbyte*);
extern int __glXSwapGetDrawableAttributes(__GLXclientState*, GLbyte*);
extern int __glXSwapChangeDrawableAttributes(__GLXclientState*, GLbyte*);
extern int __glXSwapCreateWindow(__GLXclientState*, GLbyte*);
extern int __glXSwapDestroyWindow(__GLXclientState*, GLbyte*);
#define __GLX_MIN_GLXCMD_OPCODE 1
#define __GLX_MAX_GLXCMD_OPCODE 20
#define __GLX_MIN_RENDER_OPCODE 1
/*#define __GLX_MAX_RENDER_OPCODE 213*/
#define __GLX_MAX_RENDER_OPCODE 230
#define __GLX_MIN_SINGLE_OPCODE 1
#define __GLX_MAX_SINGLE_OPCODE 159
#define __GLX_SINGLE_TABLE_SIZE 160
/*#define __GLX_RENDER_TABLE_SIZE 214*/
#define __GLX_RENDER_TABLE_SIZE 231
extern __GLXdispatchRenderProcPtr __glXRenderTable[__GLX_RENDER_TABLE_SIZE];
extern __GLXdispatchSingleProcPtr __glXSingleTable[__GLX_SINGLE_TABLE_SIZE];
extern __GLXdispatchRenderProcPtr __glXSwapRenderTable[__GLX_RENDER_TABLE_SIZE];
extern __GLXdispatchSingleProcPtr __glXSwapSingleTable[__GLX_SINGLE_TABLE_SIZE];
/* Copied from mesa src/glx/x11/glxcmds.c
*

View File

@ -2338,12 +2338,6 @@ __GLXdispatchRenderProcPtr __glXRenderTable_EXT[__GLX_MAX_RENDER_OPCODE_EXT - __
__glXDisp_FramebufferRenderbufferEXT, /* 4324 */
__glXDisp_GenerateMipmapEXT /* 4325 */
};
__GLXdispatchVendorPrivProcPtr __glXVendorPrivTable_EXT[__GLX_MAX_VENDPRIV_OPCODE_EXT - __GLX_MIN_VENDPRIV_OPCODE_EXT + 1] = {
__glXDisp_AreTexturesResidentEXT, /* 11 */
__glXDisp_DeleteTextures, /* 12 */
__glXDisp_GenTexturesEXT, /* 13 */
__glXDisp_IsTextureEXT, /* 14 */
};
__GLXdispatchRenderProcPtr __glXSwapRenderTable_EXT[__GLX_MAX_RENDER_OPCODE_EXT - __GLX_MIN_RENDER_OPCODE_EXT + 1] = {
@ -4647,10 +4641,3 @@ __GLXdispatchRenderProcPtr __glXSwapRenderTable_EXT[__GLX_MAX_RENDER_OPCODE_EXT
__glXDispSwap_FramebufferRenderbufferEXT, /* 4324 */
__glXDispSwap_GenerateMipmapEXT /* 4325 */
};
__GLXdispatchVendorPrivProcPtr __glXSwapVendorPrivTable_EXT[__GLX_MAX_VENDPRIV_OPCODE_EXT - __GLX_MIN_VENDPRIV_OPCODE_EXT + 1] = {
__glXDispSwap_AreTexturesResidentEXT, /* 11 */
__glXDispSwap_DeleteTextures, /* 12 */
__glXDispSwap_GenTexturesEXT, /* 13 */
__glXDispSwap_IsTextureEXT, /* 14 */
};

View File

@ -36,12 +36,7 @@
#define __GLX_MIN_RENDER_OPCODE_EXT 2053
#define __GLX_MAX_RENDER_OPCODE_EXT 4325
#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)
#define __GLX_RENDER_TABLE_SIZE_EXT (__GLX_MAX_RENDER_OPCODE_EXT - __GLX_MIN_RENDER_OPCODE_EXT + 1)
extern __GLXdispatchRenderProcPtr __glXRenderTable_EXT[__GLX_RENDER_TABLE_SIZE_EXT];
extern __GLXdispatchVendorPrivProcPtr __glXVendorPrivTable_EXT[__GLX_VENDPRIV_TABLE_SIZE_EXT];
extern __GLXdispatchRenderProcPtr __glXSwapRenderTable_EXT[__GLX_RENDER_TABLE_SIZE_EXT];
extern __GLXdispatchVendorPrivProcPtr __glXSwapVendorPrivTable_EXT[__GLX_VENDPRIV_TABLE_SIZE_EXT];
#endif /* _GLX_g_disptab_EXT_h_ */

View File

@ -57,6 +57,8 @@
#include "glthread.h"
#include "dispatch.h"
#include "indirect_dispatch.h"
#include "indirect_table.h"
#include "indirect_util.h"
/************************************************************************/
@ -66,18 +68,6 @@ GlxSetRenderTables (struct _glapi_table *table)
_glapi_set_dispatch (table);
}
static int __glXGetFBConfigsSGIX(__GLXclientState *cl, GLbyte *pc);
static int __glXCreateContextWithConfigSGIX(__GLXclientState *cl, GLbyte *pc);
static int __glXCreateGLXPixmapWithConfigSGIX(__GLXclientState *cl, GLbyte *pc);
static int __glXMakeCurrentReadSGI(__GLXclientState *cl, GLbyte *pc);
static int __glXBindSwapBarrierSGIX(__GLXclientState *cl, GLbyte *pc);
static int __glXQueryMaxSwapBarriersSGIX(__GLXclientState *cl, GLbyte *pc);
static int __glxQueryHyperpipeNetworkSGIX(__GLXclientState *cl, GLbyte *pc);
static int __glxDestroyHyperpipeConfigSGIX (__GLXclientState *cl, GLbyte *pc);
static int __glxQueryHyperpipeConfigSGIX(__GLXclientState *cl, GLbyte *pc);
static int __glxHyperpipeConfigSGIX(__GLXclientState *cl, GLbyte *pc);
/************************************************************************/
@ -254,7 +244,7 @@ int DoCreateContext(__GLXclientState *cl, GLXContextID gcId,
}
int __glXCreateContext(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_CreateContext(__GLXclientState *cl, GLbyte *pc)
{
xGLXCreateContextReq *req = (xGLXCreateContextReq *) pc;
return DoCreateContext( cl, req->context, req->shareList, req->visual,
@ -262,7 +252,7 @@ int __glXCreateContext(__GLXclientState *cl, GLbyte *pc)
}
int __glXCreateNewContext(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_CreateNewContext(__GLXclientState *cl, GLbyte *pc)
{
xGLXCreateNewContextReq *req = (xGLXCreateNewContextReq *) pc;
return DoCreateContext( cl, req->context, req->shareList, req->fbconfig,
@ -270,7 +260,7 @@ int __glXCreateNewContext(__GLXclientState *cl, GLbyte *pc)
}
int __glXCreateContextWithConfigSGIX(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_CreateContextWithConfigSGIX(__GLXclientState *cl, GLbyte *pc)
{
xGLXCreateContextWithConfigSGIXReq *req =
(xGLXCreateContextWithConfigSGIXReq *) pc;
@ -281,7 +271,7 @@ int __glXCreateContextWithConfigSGIX(__GLXclientState *cl, GLbyte *pc)
/*
** Destroy a GL context as an X resource.
*/
int __glXDestroyContext(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_DestroyContext(__GLXclientState *cl, GLbyte *pc)
{
ClientPtr client = cl->client;
xGLXDestroyContextReq *req = (xGLXDestroyContextReq *) pc;
@ -399,7 +389,7 @@ static void StartUsingContext(__GLXclientState *cl, __GLXcontext *glxc)
** Make an OpenGL context and drawable current.
*/
int __glXMakeCurrent(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_MakeCurrent(__GLXclientState *cl, GLbyte *pc)
{
xGLXMakeCurrentReq *req = (xGLXMakeCurrentReq *) pc;
@ -407,7 +397,7 @@ int __glXMakeCurrent(__GLXclientState *cl, GLbyte *pc)
req->context, req->oldContextTag );
}
int __glXMakeContextCurrent(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_MakeContextCurrent(__GLXclientState *cl, GLbyte *pc)
{
xGLXMakeContextCurrentReq *req = (xGLXMakeContextCurrentReq *) pc;
@ -415,7 +405,7 @@ int __glXMakeContextCurrent(__GLXclientState *cl, GLbyte *pc)
req->context, req->oldContextTag );
}
int __glXMakeCurrentReadSGI(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_MakeCurrentReadSGI(__GLXclientState *cl, GLbyte *pc)
{
xGLXMakeCurrentReadSGIReq *req = (xGLXMakeCurrentReadSGIReq *) pc;
@ -750,7 +740,7 @@ int DoMakeCurrent( __GLXclientState *cl,
return Success;
}
int __glXIsDirect(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_IsDirect(__GLXclientState *cl, GLbyte *pc)
{
ClientPtr client = cl->client;
xGLXIsDirectReq *req = (xGLXIsDirectReq *) pc;
@ -780,7 +770,7 @@ int __glXIsDirect(__GLXclientState *cl, GLbyte *pc)
return Success;
}
int __glXQueryVersion(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_QueryVersion(__GLXclientState *cl, GLbyte *pc)
{
ClientPtr client = cl->client;
xGLXQueryVersionReq *req = (xGLXQueryVersionReq *) pc;
@ -811,7 +801,7 @@ int __glXQueryVersion(__GLXclientState *cl, GLbyte *pc)
return Success;
}
int __glXWaitGL(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_WaitGL(__GLXclientState *cl, GLbyte *pc)
{
xGLXWaitGLReq *req = (xGLXWaitGLReq *)pc;
int error;
@ -823,7 +813,7 @@ int __glXWaitGL(__GLXclientState *cl, GLbyte *pc)
return Success;
}
int __glXWaitX(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_WaitX(__GLXclientState *cl, GLbyte *pc)
{
xGLXWaitXReq *req = (xGLXWaitXReq *)pc;
int error;
@ -840,7 +830,7 @@ int __glXWaitX(__GLXclientState *cl, GLbyte *pc)
return Success;
}
int __glXCopyContext(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_CopyContext(__GLXclientState *cl, GLbyte *pc)
{
ClientPtr client = cl->client;
xGLXCopyContextReq *req = (xGLXCopyContextReq *) pc;
@ -1011,7 +1001,7 @@ int DoGetVisualConfigs(__GLXclientState *cl, unsigned screen,
return Success;
}
int __glXGetVisualConfigs(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_GetVisualConfigs(__GLXclientState *cl, GLbyte *pc)
{
xGLXGetVisualConfigsReq *req = (xGLXGetVisualConfigsReq *) pc;
return DoGetVisualConfigs( cl, req->screen, GL_FALSE );
@ -1187,14 +1177,14 @@ int DoGetFBConfigs(__GLXclientState *cl, unsigned screen, GLboolean do_swap)
}
int __glXGetFBConfigs(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_GetFBConfigs(__GLXclientState *cl, GLbyte *pc)
{
xGLXGetFBConfigsReq *req = (xGLXGetFBConfigsReq *) pc;
return DoGetFBConfigs( cl, req->screen, GL_FALSE );
}
int __glXGetFBConfigsSGIX(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_GetFBConfigsSGIX(__GLXclientState *cl, GLbyte *pc)
{
xGLXGetFBConfigsSGIXReq *req = (xGLXGetFBConfigsSGIXReq *) pc;
return DoGetFBConfigs( cl, req->screen, GL_FALSE );
@ -1290,21 +1280,21 @@ int DoCreateGLXPixmap(__GLXclientState *cl, XID fbconfigId,
return Success;
}
int __glXCreateGLXPixmap(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_CreateGLXPixmap(__GLXclientState *cl, GLbyte *pc)
{
xGLXCreateGLXPixmapReq *req = (xGLXCreateGLXPixmapReq *) pc;
return DoCreateGLXPixmap( cl, req->visual, req->screen,
req->pixmap, req->glxpixmap );
}
int __glXCreatePixmap(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_CreatePixmap(__GLXclientState *cl, GLbyte *pc)
{
xGLXCreatePixmapReq *req = (xGLXCreatePixmapReq *) pc;
return DoCreateGLXPixmap( cl, req->fbconfig, req->screen,
req->pixmap, req->glxpixmap );
}
int __glXCreateGLXPixmapWithConfigSGIX(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_CreateGLXPixmapWithConfigSGIX(__GLXclientState *cl, GLbyte *pc)
{
xGLXCreateGLXPixmapWithConfigSGIXReq *req =
(xGLXCreateGLXPixmapWithConfigSGIXReq *) pc;
@ -1329,21 +1319,21 @@ int DoDestroyPixmap(__GLXclientState *cl, XID glxpixmap)
return Success;
}
int __glXDestroyGLXPixmap(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_DestroyGLXPixmap(__GLXclientState *cl, GLbyte *pc)
{
xGLXDestroyGLXPixmapReq *req = (xGLXDestroyGLXPixmapReq *) pc;
return DoDestroyPixmap(cl, req->glxpixmap);
}
int __glXDestroyPixmap(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_DestroyPixmap(__GLXclientState *cl, GLbyte *pc)
{
xGLXDestroyPixmapReq *req = (xGLXDestroyPixmapReq *) pc;
return DoDestroyPixmap(cl, req->glxpixmap);
}
int __glXCreatePbuffer(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_CreatePbuffer(__GLXclientState *cl, GLbyte *pc)
{
xGLXCreatePbufferReq *req = (xGLXCreatePbufferReq *) pc;
@ -1352,7 +1342,7 @@ int __glXCreatePbuffer(__GLXclientState *cl, GLbyte *pc)
return BadRequest;
}
int __glXDestroyPbuffer(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_DestroyPbuffer(__GLXclientState *cl, GLbyte *pc)
{
xGLXDestroyPbufferReq *req = (xGLXDestroyPbufferReq *) pc;
@ -1361,7 +1351,7 @@ int __glXDestroyPbuffer(__GLXclientState *cl, GLbyte *pc)
return BadRequest;
}
int __glXChangeDrawableAttributes(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_ChangeDrawableAttributes(__GLXclientState *cl, GLbyte *pc)
{
xGLXChangeDrawableAttributesReq *req =
(xGLXChangeDrawableAttributesReq *) pc;
@ -1371,7 +1361,7 @@ int __glXChangeDrawableAttributes(__GLXclientState *cl, GLbyte *pc)
return BadRequest;
}
int __glXCreateWindow(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_CreateWindow(__GLXclientState *cl, GLbyte *pc)
{
xGLXCreateWindowReq *req = (xGLXCreateWindowReq *) pc;
ClientPtr client = cl->client;
@ -1403,7 +1393,7 @@ int __glXCreateWindow(__GLXclientState *cl, GLbyte *pc)
return Success;
}
int __glXDestroyWindow(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_DestroyWindow(__GLXclientState *cl, GLbyte *pc)
{
xGLXDestroyWindowReq *req = (xGLXDestroyWindowReq *) pc;
ClientPtr client = cl->client;
@ -1428,7 +1418,7 @@ int __glXDestroyWindow(__GLXclientState *cl, GLbyte *pc)
** this time that is of value. Consequently, this code must be
** implemented by somebody other than SGI.
*/
int __glXSwapBuffers(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_SwapBuffers(__GLXclientState *cl, GLbyte *pc)
{
ClientPtr client = cl->client;
xGLXSwapBuffersReq *req = (xGLXSwapBuffersReq *) pc;
@ -1518,21 +1508,21 @@ int DoQueryContext(__GLXclientState *cl, GLXContextID gcId)
return Success;
}
int __glXQueryContextInfoEXT(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_QueryContextInfoEXT(__GLXclientState *cl, GLbyte *pc)
{
xGLXQueryContextInfoEXTReq *req = (xGLXQueryContextInfoEXTReq *) pc;
return DoQueryContext(cl, req->context);
}
int __glXQueryContext(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_QueryContext(__GLXclientState *cl, GLbyte *pc)
{
xGLXQueryContextReq *req = (xGLXQueryContextReq *) pc;
return DoQueryContext(cl, req->context);
}
int __glXBindTexImageEXT(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_BindTexImageEXT(__GLXclientState *cl, GLbyte *pc)
{
xGLXVendorPrivateReq *req = (xGLXVendorPrivateReq *) pc;
ClientPtr client = cl->client;
@ -1568,7 +1558,7 @@ int __glXBindTexImageEXT(__GLXclientState *cl, GLbyte *pc)
pGlxPixmap);
}
int __glXReleaseTexImageEXT(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_ReleaseTexImageEXT(__GLXclientState *cl, GLbyte *pc)
{
xGLXVendorPrivateReq *req = (xGLXVendorPrivateReq *) pc;
ClientPtr client = cl->client;
@ -1601,7 +1591,7 @@ int __glXReleaseTexImageEXT(__GLXclientState *cl, GLbyte *pc)
pGlxPixmap);
}
int __glXCopySubBufferMESA(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_CopySubBufferMESA(__GLXclientState *cl, GLbyte *pc)
{
xGLXVendorPrivateReq *req = (xGLXVendorPrivateReq *) pc;
GLXContextTag tag = req->contextTag;
@ -1701,7 +1691,7 @@ DoGetDrawableAttributes(__GLXclientState *cl, XID drawId)
return Success;
}
int __glXGetDrawableAttributesSGIX(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_GetDrawableAttributesSGIX(__GLXclientState *cl, GLbyte *pc)
{
xGLXVendorPrivateWithReplyReq *req = (xGLXVendorPrivateWithReplyReq *)pc;
CARD32 *data;
@ -1713,7 +1703,7 @@ int __glXGetDrawableAttributesSGIX(__GLXclientState *cl, GLbyte *pc)
return DoGetDrawableAttributes(cl, drawable);
}
int __glXGetDrawableAttributes(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_GetDrawableAttributes(__GLXclientState *cl, GLbyte *pc)
{
xGLXGetDrawableAttributesReq *req = (xGLXGetDrawableAttributesReq *)pc;
@ -1727,10 +1717,7 @@ int __glXGetDrawableAttributes(__GLXclientState *cl, GLbyte *pc)
** client library to send batches of GL rendering commands.
*/
/*
** Execute all the drawing commands in a request.
*/
int __glXRender(__GLXclientState *cl, GLbyte *pc)
int DoRender(__GLXclientState *cl, GLbyte *pc, int do_swap)
{
xGLXRenderReq *req;
ClientPtr client= cl->client;
@ -1739,14 +1726,15 @@ int __glXRender(__GLXclientState *cl, GLbyte *pc)
CARD16 opcode;
__GLXrenderHeader *hdr;
__GLXcontext *glxc;
__GLX_DECLARE_SWAP_VARIABLES;
/*
** NOTE: much of this code also appears in the byteswapping version of this
** routine, __glXSwapRender(). Any changes made here should also be
** duplicated there.
*/
req = (xGLXRenderReq *) pc;
if (do_swap) {
__GLX_SWAP_SHORT(&req->length);
__GLX_SWAP_INT(&req->contextTag);
}
glxc = __glXForceCurrent(cl, req->contextTag, &error);
if (!glxc) {
return error;
@ -1756,56 +1744,47 @@ int __glXRender(__GLXclientState *cl, GLbyte *pc)
pc += sz_xGLXRenderReq;
left = (req->length << 2) - sz_xGLXRenderReq;
while (left > 0) {
__GLXrenderSizeData *entry;
__GLXrenderSizeData entry;
int extra;
void (* proc)(GLbyte *);
__GLXdispatchRenderProcPtr proc;
int err;
/*
** Verify that the header length and the overall length agree.
** Also, each command must be word aligned.
*/
hdr = (__GLXrenderHeader *) pc;
if (do_swap) {
__GLX_SWAP_SHORT(&hdr->length);
__GLX_SWAP_SHORT(&hdr->opcode);
}
cmdlen = hdr->length;
opcode = hdr->opcode;
/*
** Check for core opcodes and grab entry data.
*/
if ( (opcode >= __GLX_MIN_RENDER_OPCODE) &&
(opcode <= __GLX_MAX_RENDER_OPCODE) ) {
entry = &__glXRenderSizeTable[opcode];
proc = __glXRenderTable[opcode];
#if __GLX_MAX_RENDER_OPCODE_EXT > __GLX_MIN_RENDER_OPCODE_EXT
} else if ( (opcode >= __GLX_MIN_RENDER_OPCODE_EXT) &&
(opcode <= __GLX_MAX_RENDER_OPCODE_EXT) ) {
entry =
&__glXRenderSizeTable_EXT[opcode -
__GLX_MIN_RENDER_OPCODE_EXT];
proc = __glXRenderTable_EXT[opcode -
__GLX_MIN_RENDER_OPCODE_EXT];
#endif /* __GLX_MAX_RENDER_OPCODE_EXT > __GLX_MIN_RENDER_OPCODE_EXT */
} else {
err = __glXGetProtocolSizeData(& Render_dispatch_info, opcode, & entry);
proc = (__GLXdispatchRenderProcPtr)
__glXGetProtocolDecodeFunction(& Render_dispatch_info, opcode, do_swap);
if ((err < 0) || (proc == NULL)) {
client->errorValue = commandsDone;
return __glXError(GLXBadRenderRequest);
}
if (!entry->bytes) {
/* unused opcode */
client->errorValue = commandsDone;
return __glXError(GLXBadRenderRequest);
}
if (entry->varsize) {
if (entry.varsize) {
/* variable size command */
extra = (*entry->varsize)(pc + __GLX_RENDER_HDR_SIZE, False);
extra = (*entry.varsize)(pc + __GLX_RENDER_HDR_SIZE, do_swap);
if (extra < 0) {
extra = 0;
}
if (cmdlen != __GLX_PAD(entry->bytes + extra)) {
if (cmdlen != __GLX_PAD(entry.bytes + extra)) {
return BadLength;
}
} else {
/* constant size command */
if (cmdlen != __GLX_PAD(entry->bytes)) {
if (cmdlen != __GLX_PAD(entry.bytes)) {
return BadLength;
}
}
@ -1830,26 +1809,34 @@ int __glXRender(__GLXclientState *cl, GLbyte *pc)
}
/*
** Execute a large rendering request (one that spans multiple X requests).
** Execute all the drawing commands in a request.
*/
int __glXRenderLarge(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_Render(__GLXclientState *cl, GLbyte *pc)
{
return DoRender(cl, pc, False);
}
int DoRenderLarge(__GLXclientState *cl, GLbyte *pc, int do_swap)
{
xGLXRenderLargeReq *req;
ClientPtr client= cl->client;
GLuint dataBytes;
void (*proc)(GLbyte *);
size_t dataBytes;
__GLXrenderLargeHeader *hdr;
__GLXcontext *glxc;
int error;
CARD16 opcode;
__GLX_DECLARE_SWAP_VARIABLES;
/*
** NOTE: much of this code also appears in the byteswapping version of this
** routine, __glXSwapRenderLarge(). Any changes made here should also be
** duplicated there.
*/
req = (xGLXRenderLargeReq *) pc;
if (do_swap) {
__GLX_SWAP_SHORT(&req->length);
__GLX_SWAP_INT(&req->contextTag);
__GLX_SWAP_INT(&req->dataBytes);
__GLX_SWAP_SHORT(&req->requestNumber);
__GLX_SWAP_SHORT(&req->requestTotal);
}
glxc = __glXForceCurrent(cl, req->contextTag, &error);
if (!glxc) {
/* Reset in case this isn't 1st request. */
@ -1870,8 +1857,11 @@ int __glXRenderLarge(__GLXclientState *cl, GLbyte *pc)
pc += sz_xGLXRenderLargeReq;
if (cl->largeCmdRequestsSoFar == 0) {
__GLXrenderSizeData *entry;
int extra, cmdlen;
__GLXrenderSizeData entry;
int extra;
size_t cmdlen;
int err;
/*
** This is the first request of a multi request command.
** Make enough space in the buffer, then copy the entire request.
@ -1882,48 +1872,39 @@ int __glXRenderLarge(__GLXclientState *cl, GLbyte *pc)
}
hdr = (__GLXrenderLargeHeader *) pc;
if (do_swap) {
__GLX_SWAP_INT(&hdr->length);
__GLX_SWAP_INT(&hdr->opcode);
}
cmdlen = hdr->length;
opcode = hdr->opcode;
/*
** Check for core opcodes and grab entry data.
*/
if ( (opcode >= __GLX_MIN_RENDER_OPCODE) &&
(opcode <= __GLX_MAX_RENDER_OPCODE) ) {
entry = &__glXRenderSizeTable[opcode];
#if __GLX_MAX_RENDER_OPCODE_EXT > __GLX_MIN_RENDER_OPCODE_EXT
} else if ( (opcode >= __GLX_MIN_RENDER_OPCODE_EXT) &&
(opcode <= __GLX_MAX_RENDER_OPCODE_EXT) ) {
opcode -= __GLX_MIN_RENDER_OPCODE_EXT;
entry = &__glXRenderSizeTable_EXT[opcode];
#endif /* __GLX_MAX_RENDER_OPCODE_EXT > __GLX_MIN_RENDER_OPCODE_EXT */
} else {
err = __glXGetProtocolSizeData(& Render_dispatch_info, opcode, & entry);
if (err < 0) {
client->errorValue = opcode;
return __glXError(GLXBadLargeRequest);
}
if (!entry->bytes) {
/* unused opcode */
client->errorValue = opcode;
return __glXError(GLXBadLargeRequest);
}
if (entry->varsize) {
if (entry.varsize) {
/*
** If it's a variable-size command (a command whose length must
** be computed from its parameters), all the parameters needed
** will be in the 1st request, so it's okay to do this.
*/
extra = (*entry->varsize)(pc + __GLX_RENDER_LARGE_HDR_SIZE, False);
extra = (*entry.varsize)(pc + __GLX_RENDER_LARGE_HDR_SIZE, do_swap);
if (extra < 0) {
extra = 0;
}
/* large command's header is 4 bytes longer, so add 4 */
if (cmdlen != __GLX_PAD(entry->bytes + 4 + extra)) {
if (cmdlen != __GLX_PAD(entry.bytes + 4 + extra)) {
return BadLength;
}
} else {
/* constant size command */
if (cmdlen != __GLX_PAD(entry->bytes + 4)) {
if (cmdlen != __GLX_PAD(entry.bytes + 4)) {
return BadLength;
}
}
@ -1932,10 +1913,9 @@ int __glXRenderLarge(__GLXclientState *cl, GLbyte *pc)
*/
if (cl->largeCmdBufSize < cmdlen) {
if (!cl->largeCmdBuf) {
cl->largeCmdBuf = (GLbyte *) xalloc((size_t)cmdlen);
cl->largeCmdBuf = (GLbyte *) xalloc(cmdlen);
} else {
cl->largeCmdBuf = (GLbyte *) xrealloc(cl->largeCmdBuf,
(size_t)cmdlen);
cl->largeCmdBuf = (GLbyte *) xrealloc(cl->largeCmdBuf, cmdlen);
}
if (!cl->largeCmdBuf) {
return BadAlloc;
@ -1983,6 +1963,8 @@ int __glXRenderLarge(__GLXclientState *cl, GLbyte *pc)
cl->largeCmdRequestsSoFar++;
if (req->requestNumber == cl->largeCmdRequestsTotal) {
__GLXdispatchRenderProcPtr proc;
/*
** This is the last request; it must have enough bytes to complete
** the command.
@ -2003,21 +1985,17 @@ int __glXRenderLarge(__GLXclientState *cl, GLbyte *pc)
return __glXError(GLXBadLargeRequest);
}
hdr = (__GLXrenderLargeHeader *) cl->largeCmdBuf;
opcode = hdr->opcode;
/*
** The opcode and length field in the header had already been
** swapped when the first request was received.
**
** Use the opcode to index into the procedure table.
*/
if ( (opcode >= __GLX_MIN_RENDER_OPCODE) &&
(opcode <= __GLX_MAX_RENDER_OPCODE) ) {
proc = __glXRenderTable[opcode];
#if __GLX_MAX_RENDER_OPCODE_EXT > __GLX_MIN_RENDER_OPCODE_EXT
} else if ( (opcode >= __GLX_MIN_RENDER_OPCODE_EXT) &&
(opcode <= __GLX_MAX_RENDER_OPCODE_EXT) ) {
opcode -= __GLX_MIN_RENDER_OPCODE_EXT;
proc = __glXRenderTable_EXT[opcode];
#endif /* __GLX_MAX_RENDER_OPCODE_EXT > __GLX_MIN_RENDER_OPCODE_EXT */
} else {
opcode = hdr->opcode;
proc = (__GLXdispatchRenderProcPtr)
__glXGetProtocolDecodeFunction(& Render_dispatch_info, opcode, do_swap);
if (proc == NULL) {
client->errorValue = opcode;
return __glXError(GLXBadLargeRequest);
}
@ -2041,9 +2019,17 @@ int __glXRenderLarge(__GLXclientState *cl, GLbyte *pc)
}
}
/*
** Execute a large rendering request (one that spans multiple X requests).
*/
int __glXDisp_RenderLarge(__GLXclientState *cl, GLbyte *pc)
{
return DoRenderLarge(cl, pc, False);
}
extern RESTYPE __glXSwapBarrierRes;
static int __glXBindSwapBarrierSGIX(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_BindSwapBarrierSGIX(__GLXclientState *cl, GLbyte *pc)
{
ClientPtr client = cl->client;
xGLXBindSwapBarrierSGIXReq *req = (xGLXBindSwapBarrierSGIXReq *) pc;
@ -2073,7 +2059,7 @@ static int __glXBindSwapBarrierSGIX(__GLXclientState *cl, GLbyte *pc)
}
static int __glXQueryMaxSwapBarriersSGIX(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_QueryMaxSwapBarriersSGIX(__GLXclientState *cl, GLbyte *pc)
{
ClientPtr client = cl->client;
xGLXQueryMaxSwapBarriersSGIXReq *req =
@ -2104,7 +2090,7 @@ static int __glXQueryMaxSwapBarriersSGIX(__GLXclientState *cl, GLbyte *pc)
#define GLX_BAD_HYPERPIPE_SGIX 92
static int __glxQueryHyperpipeNetworkSGIX(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_QueryHyperpipeNetworkSGIX(__GLXclientState *cl, GLbyte *pc)
{
ClientPtr client = cl->client;
xGLXQueryHyperpipeNetworkSGIXReq * req = (xGLXQueryHyperpipeNetworkSGIXReq *) pc;
@ -2144,7 +2130,7 @@ static int __glxQueryHyperpipeNetworkSGIX(__GLXclientState *cl, GLbyte *pc)
return Success;
}
static int __glxDestroyHyperpipeConfigSGIX (__GLXclientState *cl, GLbyte *pc)
int __glXDisp_DestroyHyperpipeConfigSGIX (__GLXclientState *cl, GLbyte *pc)
{
ClientPtr client = cl->client;
xGLXDestroyHyperpipeConfigSGIXReq * req =
@ -2179,7 +2165,7 @@ static int __glxDestroyHyperpipeConfigSGIX (__GLXclientState *cl, GLbyte *pc)
return Success;
}
static int __glxQueryHyperpipeConfigSGIX(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_QueryHyperpipeConfigSGIX(__GLXclientState *cl, GLbyte *pc)
{
ClientPtr client = cl->client;
xGLXQueryHyperpipeConfigSGIXReq * req =
@ -2223,7 +2209,7 @@ static int __glxQueryHyperpipeConfigSGIX(__GLXclientState *cl, GLbyte *pc)
return Success;
}
static int __glxHyperpipeConfigSGIX(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_HyperpipeConfigSGIX(__GLXclientState *cl, GLbyte *pc)
{
ClientPtr client = cl->client;
xGLXHyperpipeConfigSGIXReq * req =
@ -2274,40 +2260,21 @@ static int __glxHyperpipeConfigSGIX(__GLXclientState *cl, GLbyte *pc)
** allocating the entry points in the dispatch table.
*/
int __glXVendorPrivate(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_VendorPrivate(__GLXclientState *cl, GLbyte *pc)
{
xGLXVendorPrivateReq *req;
GLint vendorcode;
xGLXVendorPrivateReq *req = (xGLXVendorPrivateReq *) pc;
GLint vendorcode = req->vendorCode;
__GLXdispatchVendorPrivProcPtr proc;
req = (xGLXVendorPrivateReq *) pc;
vendorcode = req->vendorCode;
#ifndef __DARWIN__
switch( vendorcode ) {
case X_GLvop_SampleMaskSGIS:
CALL_SampleMaskSGIS( GET_DISPATCH(),
(*(GLfloat *)(pc + 4), *(GLboolean *)(pc + 8)) );
return Success;
case X_GLvop_SamplePatternSGIS:
CALL_SamplePatternSGIS( GET_DISPATCH(), (*(GLenum *)(pc + 4)) );
return Success;
case X_GLXvop_BindSwapBarrierSGIX:
return __glXBindSwapBarrierSGIX(cl, pc);
case X_GLXvop_BindTexImageEXT:
return __glXBindTexImageEXT(cl, pc);
case X_GLXvop_ReleaseTexImageEXT:
return __glXReleaseTexImageEXT(cl, pc);
case X_GLXvop_CopySubBufferMESA:
return __glXCopySubBufferMESA(cl, pc);
}
#endif
if ((vendorcode >= __GLX_MIN_VENDPRIV_OPCODE_EXT) &&
(vendorcode <= __GLX_MAX_VENDPRIV_OPCODE_EXT)) {
(*__glXVendorPrivTable_EXT[vendorcode-__GLX_MIN_VENDPRIV_OPCODE_EXT])
(cl, (GLbyte*)req);
proc = (__GLXdispatchVendorPrivProcPtr)
__glXGetProtocolDecodeFunction(& VendorPriv_dispatch_info,
vendorcode, 0);
if (proc != NULL) {
(*proc)(cl, (GLbyte*)req);
return Success;
}
/*
** This sample implemention does not support any private requests.
*/
@ -2315,67 +2282,25 @@ int __glXVendorPrivate(__GLXclientState *cl, GLbyte *pc)
return __glXError(GLXUnsupportedPrivateRequest);
}
int __glXVendorPrivateWithReply(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_VendorPrivateWithReply(__GLXclientState *cl, GLbyte *pc)
{
xGLXVendorPrivateWithReplyReq *req;
GLint vendorcode;
xGLXVendorPrivateReq *req = (xGLXVendorPrivateReq *) pc;
GLint vendorcode = req->vendorCode;
__GLXdispatchVendorPrivProcPtr proc;
req = (xGLXVendorPrivateWithReplyReq *) pc;
vendorcode = req->vendorCode;
switch (vendorcode) {
case X_GLXvop_QueryContextInfoEXT:
return __glXQueryContextInfoEXT(cl, pc);
case X_GLXvop_MakeCurrentReadSGI:
return __glXMakeCurrentReadSGI(cl, pc);
case X_GLXvop_QueryMaxSwapBarriersSGIX:
return __glXQueryMaxSwapBarriersSGIX(cl, pc);
case X_GLXvop_QueryHyperpipeNetworkSGIX:
return __glxQueryHyperpipeNetworkSGIX(cl, pc);
case X_GLXvop_QueryHyperpipeConfigSGIX:
return __glxQueryHyperpipeConfigSGIX(cl, pc);
case X_GLXvop_DestroyHyperpipeConfigSGIX:
return __glxDestroyHyperpipeConfigSGIX(cl, pc);
case X_GLXvop_HyperpipeConfigSGIX:
return __glxHyperpipeConfigSGIX(cl, pc);
case X_GLXvop_GetFBConfigsSGIX:
return __glXGetFBConfigsSGIX(cl, pc);
case X_GLXvop_CreateContextWithConfigSGIX:
return __glXCreateContextWithConfigSGIX(cl, pc);
case X_GLXvop_CreateGLXPixmapWithConfigSGIX:
return __glXCreateGLXPixmapWithConfigSGIX(cl, pc);
case X_GLXvop_GetDrawableAttributesSGIX:
return __glXGetDrawableAttributesSGIX(cl, pc);
case X_GLvop_IsRenderbufferEXT:
return __glXDisp_IsRenderbufferEXT(cl, pc);
case X_GLvop_GenRenderbuffersEXT:
return __glXDisp_GenRenderbuffersEXT(cl, pc);
case X_GLvop_GetRenderbufferParameterivEXT:
return __glXDisp_GetRenderbufferParameterivEXT(cl, pc);
case X_GLvop_IsFramebufferEXT:
return __glXDisp_IsFramebufferEXT(cl, pc);
case X_GLvop_GenFramebuffersEXT:
return __glXDisp_GenFramebuffersEXT(cl, pc);
case X_GLvop_CheckFramebufferStatusEXT:
return __glXDisp_CheckFramebufferStatusEXT(cl, pc);
case X_GLvop_GetFramebufferAttachmentParameterivEXT:
return __glXDisp_GetFramebufferAttachmentParameterivEXT(cl, pc);
default:
break;
}
if ((vendorcode >= __GLX_MIN_VENDPRIV_OPCODE_EXT) &&
(vendorcode <= __GLX_MAX_VENDPRIV_OPCODE_EXT)) {
return
(*__glXVendorPrivTable_EXT[vendorcode-__GLX_MIN_VENDPRIV_OPCODE_EXT])
(cl, (GLbyte*)req);
proc = (__GLXdispatchVendorPrivProcPtr)
__glXGetProtocolDecodeFunction(& VendorPriv_dispatch_info,
vendorcode, 0);
if (proc != NULL) {
return (*proc)(cl, (GLbyte*)req);
}
cl->client->errorValue = vendorcode;
return __glXError(GLXUnsupportedPrivateRequest);
}
int __glXQueryExtensionsString(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_QueryExtensionsString(__GLXclientState *cl, GLbyte *pc)
{
ClientPtr client = cl->client;
xGLXQueryExtensionsStringReq *req = (xGLXQueryExtensionsStringReq *) pc;
@ -2420,7 +2345,7 @@ int __glXQueryExtensionsString(__GLXclientState *cl, GLbyte *pc)
return Success;
}
int __glXQueryServerString(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_QueryServerString(__GLXclientState *cl, GLbyte *pc)
{
ClientPtr client = cl->client;
xGLXQueryServerStringReq *req = (xGLXQueryServerStringReq *) pc;
@ -2478,7 +2403,7 @@ int __glXQueryServerString(__GLXclientState *cl, GLbyte *pc)
return Success;
}
int __glXClientInfo(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_ClientInfo(__GLXclientState *cl, GLbyte *pc)
{
xGLXClientInfoReq *req = (xGLXClientInfoReq *) pc;
const char *buf;
@ -2492,4 +2417,3 @@ int __glXClientInfo(__GLXclientState *cl, GLbyte *pc)
return Success;
}

View File

@ -54,11 +54,9 @@
#include "glthread.h"
#include "dispatch.h"
#include "indirect_dispatch.h"
#include "indirect_table.h"
#include "indirect_util.h"
static int __glXSwapGetFBConfigsSGIX(__GLXclientState *cl, GLbyte *pc);
static int __glXSwapCreateContextWithConfigSGIX(__GLXclientState *cl, GLbyte *pc);
static int __glXSwapCreateGLXPixmapWithConfigSGIX(__GLXclientState *cl, GLbyte *pc);
static int __glXSwapMakeCurrentReadSGI(__GLXclientState *cl, GLbyte *pc);
/************************************************************************/
@ -69,7 +67,7 @@ static int __glXSwapMakeCurrentReadSGI(__GLXclientState *cl, GLbyte *pc);
** it is called at the end of the unswapped routine.
*/
int __glXSwapCreateContext(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_CreateContext(__GLXclientState *cl, GLbyte *pc)
{
xGLXCreateContextReq *req = (xGLXCreateContextReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -84,7 +82,7 @@ int __glXSwapCreateContext(__GLXclientState *cl, GLbyte *pc)
req->screen, req->isDirect );
}
int __glXSwapCreateNewContext(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_CreateNewContext(__GLXclientState *cl, GLbyte *pc)
{
xGLXCreateNewContextReq *req = (xGLXCreateNewContextReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -100,7 +98,7 @@ int __glXSwapCreateNewContext(__GLXclientState *cl, GLbyte *pc)
req->screen, req->isDirect );
}
int __glXSwapCreateContextWithConfigSGIX(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_CreateContextWithConfigSGIX(__GLXclientState *cl, GLbyte *pc)
{
xGLXCreateContextWithConfigSGIXReq *req =
(xGLXCreateContextWithConfigSGIXReq *) pc;
@ -117,7 +115,7 @@ int __glXSwapCreateContextWithConfigSGIX(__GLXclientState *cl, GLbyte *pc)
req->screen, req->isDirect );
}
int __glXSwapDestroyContext(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_DestroyContext(__GLXclientState *cl, GLbyte *pc)
{
xGLXDestroyContextReq *req = (xGLXDestroyContextReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -125,10 +123,10 @@ int __glXSwapDestroyContext(__GLXclientState *cl, GLbyte *pc)
__GLX_SWAP_SHORT(&req->length);
__GLX_SWAP_INT(&req->context);
return __glXDestroyContext(cl, pc);
return __glXDisp_DestroyContext(cl, pc);
}
int __glXSwapMakeCurrent(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_MakeCurrent(__GLXclientState *cl, GLbyte *pc)
{
xGLXMakeCurrentReq *req = (xGLXMakeCurrentReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -142,7 +140,7 @@ int __glXSwapMakeCurrent(__GLXclientState *cl, GLbyte *pc)
req->context, req->oldContextTag );
}
int __glXSwapMakeContextCurrent(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_MakeContextCurrent(__GLXclientState *cl, GLbyte *pc)
{
xGLXMakeContextCurrentReq *req = (xGLXMakeContextCurrentReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -157,7 +155,7 @@ int __glXSwapMakeContextCurrent(__GLXclientState *cl, GLbyte *pc)
req->context, req->oldContextTag );
}
int __glXSwapMakeCurrentReadSGI(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_MakeCurrentReadSGI(__GLXclientState *cl, GLbyte *pc)
{
xGLXMakeCurrentReadSGIReq *req = (xGLXMakeCurrentReadSGIReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -172,7 +170,7 @@ int __glXSwapMakeCurrentReadSGI(__GLXclientState *cl, GLbyte *pc)
req->context, req->oldContextTag );
}
int __glXSwapIsDirect(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_IsDirect(__GLXclientState *cl, GLbyte *pc)
{
xGLXIsDirectReq *req = (xGLXIsDirectReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -180,10 +178,10 @@ int __glXSwapIsDirect(__GLXclientState *cl, GLbyte *pc)
__GLX_SWAP_SHORT(&req->length);
__GLX_SWAP_INT(&req->context);
return __glXIsDirect(cl, pc);
return __glXDisp_IsDirect(cl, pc);
}
int __glXSwapQueryVersion(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_QueryVersion(__GLXclientState *cl, GLbyte *pc)
{
xGLXQueryVersionReq *req = (xGLXQueryVersionReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -192,10 +190,10 @@ int __glXSwapQueryVersion(__GLXclientState *cl, GLbyte *pc)
__GLX_SWAP_INT(&req->majorVersion);
__GLX_SWAP_INT(&req->minorVersion);
return __glXQueryVersion(cl, pc);
return __glXDisp_QueryVersion(cl, pc);
}
int __glXSwapWaitGL(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_WaitGL(__GLXclientState *cl, GLbyte *pc)
{
xGLXWaitGLReq *req = (xGLXWaitGLReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -203,10 +201,10 @@ int __glXSwapWaitGL(__GLXclientState *cl, GLbyte *pc)
__GLX_SWAP_SHORT(&req->length);
__GLX_SWAP_INT(&req->contextTag);
return __glXWaitGL(cl, pc);
return __glXDisp_WaitGL(cl, pc);
}
int __glXSwapWaitX(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_WaitX(__GLXclientState *cl, GLbyte *pc)
{
xGLXWaitXReq *req = (xGLXWaitXReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -214,10 +212,10 @@ int __glXSwapWaitX(__GLXclientState *cl, GLbyte *pc)
__GLX_SWAP_SHORT(&req->length);
__GLX_SWAP_INT(&req->contextTag);
return __glXWaitX(cl, pc);
return __glXDisp_WaitX(cl, pc);
}
int __glXSwapCopyContext(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_CopyContext(__GLXclientState *cl, GLbyte *pc)
{
xGLXCopyContextReq *req = (xGLXCopyContextReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -227,10 +225,10 @@ int __glXSwapCopyContext(__GLXclientState *cl, GLbyte *pc)
__GLX_SWAP_INT(&req->dest);
__GLX_SWAP_INT(&req->mask);
return __glXCopyContext(cl, pc);
return __glXDisp_CopyContext(cl, pc);
}
int __glXSwapGetVisualConfigs(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_GetVisualConfigs(__GLXclientState *cl, GLbyte *pc)
{
xGLXGetVisualConfigsReq *req = (xGLXGetVisualConfigsReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -239,7 +237,7 @@ int __glXSwapGetVisualConfigs(__GLXclientState *cl, GLbyte *pc)
return DoGetVisualConfigs( cl, req->screen, GL_TRUE );
}
int __glXSwapGetFBConfigs(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_GetFBConfigs(__GLXclientState *cl, GLbyte *pc)
{
xGLXGetFBConfigsReq *req = (xGLXGetFBConfigsReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -248,7 +246,7 @@ int __glXSwapGetFBConfigs(__GLXclientState *cl, GLbyte *pc)
return DoGetFBConfigs( cl, req->screen, GL_TRUE );
}
int __glXSwapGetFBConfigsSGIX(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_GetFBConfigsSGIX(__GLXclientState *cl, GLbyte *pc)
{
xGLXGetFBConfigsSGIXReq *req = (xGLXGetFBConfigsSGIXReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -257,7 +255,7 @@ int __glXSwapGetFBConfigsSGIX(__GLXclientState *cl, GLbyte *pc)
return DoGetFBConfigs( cl, req->screen, GL_TRUE );
}
int __glXSwapCreateGLXPixmap(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_CreateGLXPixmap(__GLXclientState *cl, GLbyte *pc)
{
xGLXCreateGLXPixmapReq *req = (xGLXCreateGLXPixmapReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -272,7 +270,7 @@ int __glXSwapCreateGLXPixmap(__GLXclientState *cl, GLbyte *pc)
req->pixmap, req->glxpixmap );
}
int __glXSwapCreatePixmap(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_CreatePixmap(__GLXclientState *cl, GLbyte *pc)
{
xGLXCreatePixmapReq *req = (xGLXCreatePixmapReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -287,7 +285,7 @@ int __glXSwapCreatePixmap(__GLXclientState *cl, GLbyte *pc)
req->pixmap, req->glxpixmap );
}
int __glXSwapCreateGLXPixmapWithConfigSGIX(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_CreateGLXPixmapWithConfigSGIX(__GLXclientState *cl, GLbyte *pc)
{
xGLXCreateGLXPixmapWithConfigSGIXReq *req =
(xGLXCreateGLXPixmapWithConfigSGIXReq *) pc;
@ -303,7 +301,7 @@ int __glXSwapCreateGLXPixmapWithConfigSGIX(__GLXclientState *cl, GLbyte *pc)
req->pixmap, req->glxpixmap );
}
int __glXSwapDestroyGLXPixmap(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_DestroyGLXPixmap(__GLXclientState *cl, GLbyte *pc)
{
xGLXDestroyGLXPixmapReq *req = (xGLXDestroyGLXPixmapReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -311,10 +309,10 @@ int __glXSwapDestroyGLXPixmap(__GLXclientState *cl, GLbyte *pc)
__GLX_SWAP_SHORT(&req->length);
__GLX_SWAP_INT(&req->glxpixmap);
return __glXDestroyGLXPixmap(cl, pc);
return __glXDisp_DestroyGLXPixmap(cl, pc);
}
int __glXSwapDestroyPixmap(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_DestroyPixmap(__GLXclientState *cl, GLbyte *pc)
{
xGLXDestroyGLXPixmapReq *req = (xGLXDestroyGLXPixmapReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -322,10 +320,10 @@ int __glXSwapDestroyPixmap(__GLXclientState *cl, GLbyte *pc)
__GLX_SWAP_SHORT(&req->length);
__GLX_SWAP_INT(&req->glxpixmap);
return __glXDestroyGLXPixmap(cl, pc);
return __glXDisp_DestroyGLXPixmap(cl, pc);
}
int __glXSwapQueryContext(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_QueryContext(__GLXclientState *cl, GLbyte *pc)
{
xGLXQueryContextReq *req = (xGLXQueryContextReq *) pc;
@ -334,7 +332,7 @@ int __glXSwapQueryContext(__GLXclientState *cl, GLbyte *pc)
return BadRequest;
}
int __glXSwapCreatePbuffer(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_CreatePbuffer(__GLXclientState *cl, GLbyte *pc)
{
xGLXCreatePbufferReq *req = (xGLXCreatePbufferReq *) pc;
@ -343,14 +341,14 @@ int __glXSwapCreatePbuffer(__GLXclientState *cl, GLbyte *pc)
return BadRequest;
}
int __glXSwapDestroyPbuffer(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_DestroyPbuffer(__GLXclientState *cl, GLbyte *pc)
{
xGLXDestroyPbufferReq *req = (xGLXDestroyPbufferReq *) req;
return BadRequest;
}
int __glXSwapChangeDrawableAttributes(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_ChangeDrawableAttributes(__GLXclientState *cl, GLbyte *pc)
{
xGLXChangeDrawableAttributesReq *req =
(xGLXChangeDrawableAttributesReq *) req;
@ -358,7 +356,7 @@ int __glXSwapChangeDrawableAttributes(__GLXclientState *cl, GLbyte *pc)
return BadRequest;
}
int __glXSwapCreateWindow(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_CreateWindow(__GLXclientState *cl, GLbyte *pc)
{
xGLXCreateWindowReq *req = (xGLXCreateWindowReq *) pc;
@ -367,7 +365,7 @@ int __glXSwapCreateWindow(__GLXclientState *cl, GLbyte *pc)
return BadRequest;
}
int __glXSwapDestroyWindow(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_DestroyWindow(__GLXclientState *cl, GLbyte *pc)
{
xGLXDestroyWindowReq *req = (xGLXDestroyWindowReq *) pc;
@ -376,7 +374,7 @@ int __glXSwapDestroyWindow(__GLXclientState *cl, GLbyte *pc)
return BadRequest;
}
int __glXSwapSwapBuffers(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_SwapBuffers(__GLXclientState *cl, GLbyte *pc)
{
xGLXSwapBuffersReq *req = (xGLXSwapBuffersReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -385,10 +383,10 @@ int __glXSwapSwapBuffers(__GLXclientState *cl, GLbyte *pc)
__GLX_SWAP_INT(&req->contextTag);
__GLX_SWAP_INT(&req->drawable);
return __glXSwapBuffers(cl, pc);
return __glXDisp_SwapBuffers(cl, pc);
}
int __glXSwapUseXFont(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_UseXFont(__GLXclientState *cl, GLbyte *pc)
{
xGLXUseXFontReq *req = (xGLXUseXFontReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -400,11 +398,11 @@ int __glXSwapUseXFont(__GLXclientState *cl, GLbyte *pc)
__GLX_SWAP_INT(&req->count);
__GLX_SWAP_INT(&req->listBase);
return __glXUseXFont(cl, pc);
return __glXDisp_UseXFont(cl, pc);
}
int __glXSwapQueryExtensionsString(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_QueryExtensionsString(__GLXclientState *cl, GLbyte *pc)
{
xGLXQueryExtensionsStringReq *req = (xGLXQueryExtensionsStringReq *)pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -412,10 +410,10 @@ int __glXSwapQueryExtensionsString(__GLXclientState *cl, GLbyte *pc)
__GLX_SWAP_SHORT(&req->length);
__GLX_SWAP_INT(&req->screen);
return __glXQueryExtensionsString(cl, pc);
return __glXDisp_QueryExtensionsString(cl, pc);
}
int __glXSwapQueryServerString(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_QueryServerString(__GLXclientState *cl, GLbyte *pc)
{
xGLXQueryServerStringReq *req = (xGLXQueryServerStringReq *)pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -424,10 +422,10 @@ int __glXSwapQueryServerString(__GLXclientState *cl, GLbyte *pc)
__GLX_SWAP_INT(&req->screen);
__GLX_SWAP_INT(&req->name);
return __glXQueryServerString(cl, pc);
return __glXDisp_QueryServerString(cl, pc);
}
int __glXSwapClientInfo(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_ClientInfo(__GLXclientState *cl, GLbyte *pc)
{
xGLXClientInfoReq *req = (xGLXClientInfoReq *)pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -437,10 +435,10 @@ int __glXSwapClientInfo(__GLXclientState *cl, GLbyte *pc)
__GLX_SWAP_INT(&req->minor);
__GLX_SWAP_INT(&req->numbytes);
return __glXClientInfo(cl, pc);
return __glXDisp_ClientInfo(cl, pc);
}
int __glXSwapQueryContextInfoEXT(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_QueryContextInfoEXT(__GLXclientState *cl, GLbyte *pc)
{
xGLXQueryContextInfoEXTReq *req = (xGLXQueryContextInfoEXTReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -448,10 +446,10 @@ int __glXSwapQueryContextInfoEXT(__GLXclientState *cl, GLbyte *pc)
__GLX_SWAP_SHORT(&req->length);
__GLX_SWAP_INT(&req->context);
return __glXQueryContextInfoEXT(cl, pc);
return __glXDisp_QueryContextInfoEXT(cl, pc);
}
int __glXSwapBindTexImageEXT(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_BindTexImageEXT(__GLXclientState *cl, GLbyte *pc)
{
xGLXVendorPrivateReq *req = (xGLXVendorPrivateReq *) pc;
GLXDrawable *drawId;
@ -469,10 +467,10 @@ int __glXSwapBindTexImageEXT(__GLXclientState *cl, GLbyte *pc)
__GLX_SWAP_INT(drawId);
__GLX_SWAP_INT(buffer);
return __glXBindTexImageEXT(cl, (GLbyte *)pc);
return __glXDisp_BindTexImageEXT(cl, (GLbyte *)pc);
}
int __glXSwapReleaseTexImageEXT(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_ReleaseTexImageEXT(__GLXclientState *cl, GLbyte *pc)
{
xGLXVendorPrivateReq *req = (xGLXVendorPrivateReq *) pc;
GLXDrawable *drawId;
@ -490,10 +488,10 @@ int __glXSwapReleaseTexImageEXT(__GLXclientState *cl, GLbyte *pc)
__GLX_SWAP_INT(drawId);
__GLX_SWAP_INT(buffer);
return __glXReleaseTexImageEXT(cl, (GLbyte *)pc);
return __glXDisp_ReleaseTexImageEXT(cl, (GLbyte *)pc);
}
int __glXSwapCopySubBufferMESA(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_CopySubBufferMESA(__GLXclientState *cl, GLbyte *pc)
{
xGLXVendorPrivateReq *req = (xGLXVendorPrivateReq *) pc;
GLXDrawable *drawId;
@ -514,11 +512,11 @@ int __glXSwapCopySubBufferMESA(__GLXclientState *cl, GLbyte *pc)
__GLX_SWAP_INT(pc + 12);
__GLX_SWAP_INT(pc + 16);
return __glXCopySubBufferMESA(cl, pc);
return __glXDisp_CopySubBufferMESA(cl, pc);
}
int __glXSwapGetDrawableAttributesSGIX(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_GetDrawableAttributesSGIX(__GLXclientState *cl, GLbyte *pc)
{
xGLXVendorPrivateWithReplyReq *req = (xGLXVendorPrivateWithReplyReq *)pc;
CARD32 *data;
@ -530,10 +528,10 @@ int __glXSwapGetDrawableAttributesSGIX(__GLXclientState *cl, GLbyte *pc)
__GLX_SWAP_INT(&req->contextTag);
__GLX_SWAP_INT(data);
return __glXGetDrawableAttributesSGIX(cl, pc);
return __glXDisp_GetDrawableAttributesSGIX(cl, pc);
}
int __glXSwapGetDrawableAttributes(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_GetDrawableAttributes(__GLXclientState *cl, GLbyte *pc)
{
xGLXGetDrawableAttributesReq *req = (xGLXGetDrawableAttributesReq *)pc;
@ -542,7 +540,7 @@ int __glXSwapGetDrawableAttributes(__GLXclientState *cl, GLbyte *pc)
__GLX_SWAP_SHORT(&req->length);
__GLX_SWAP_INT(&req->drawable);
return __glXGetDrawableAttributes(cl, pc);
return __glXDisp_GetDrawableAttributes(cl, pc);
}
@ -641,325 +639,17 @@ void __glXSwapGetDrawableAttributesReply(ClientPtr client,
** client library to send batches of GL rendering commands.
*/
int __glXSwapRender(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_Render(__GLXclientState *cl, GLbyte *pc)
{
xGLXRenderReq *req;
ClientPtr client= cl->client;
int left, cmdlen, error;
int commandsDone;
CARD16 opcode;
__GLXrenderHeader *hdr;
__GLXcontext *cx;
__GLX_DECLARE_SWAP_VARIABLES;
/*
** NOTE: much of this code also appears in the nonswapping version of this
** routine, __glXRender(). Any changes made here should also be
** duplicated there.
*/
req = (xGLXRenderReq *) pc;
__GLX_SWAP_SHORT(&req->length);
__GLX_SWAP_INT(&req->contextTag);
cx = __glXForceCurrent(cl, req->contextTag, &error);
if (!cx) {
return error;
}
commandsDone = 0;
pc += sz_xGLXRenderReq;
left = (req->length << 2) - sz_xGLXRenderReq;
while (left > 0) {
__GLXrenderSizeData *entry;
int extra;
void (* proc)(GLbyte *);
/*
** Verify that the header length and the overall length agree.
** Also, each command must be word aligned.
*/
hdr = (__GLXrenderHeader *) pc;
__GLX_SWAP_SHORT(&hdr->length);
__GLX_SWAP_SHORT(&hdr->opcode);
cmdlen = hdr->length;
opcode = hdr->opcode;
if ( (opcode >= __GLX_MIN_RENDER_OPCODE) &&
(opcode <= __GLX_MAX_RENDER_OPCODE) ) {
entry = &__glXRenderSizeTable[opcode];
proc = __glXSwapRenderTable[opcode];
#if __GLX_MAX_RENDER_OPCODE_EXT > __GLX_MIN_RENDER_OPCODE_EXT
} else if ( (opcode >= __GLX_MIN_RENDER_OPCODE_EXT) &&
(opcode <= __GLX_MAX_RENDER_OPCODE_EXT) ) {
int index = opcode - __GLX_MIN_RENDER_OPCODE_EXT;
entry = &__glXRenderSizeTable_EXT[index];
proc = __glXSwapRenderTable_EXT[index];
#endif /* __GLX_MAX_RENDER_OPCODE_EXT > __GLX_MIN_RENDER_OPCODE_EXT */
} else {
client->errorValue = commandsDone;
return __glXError(GLXBadRenderRequest);
}
if (!entry->bytes) {
/* unused opcode */
client->errorValue = commandsDone;
return __glXError(GLXBadRenderRequest);
}
if (entry->varsize) {
/* variable size command */
extra = (*entry->varsize)(pc + __GLX_RENDER_HDR_SIZE, True);
if (extra < 0) {
extra = 0;
}
if (cmdlen != __GLX_PAD(entry->bytes + extra)) {
return BadLength;
}
} else {
/* constant size command */
if (cmdlen != __GLX_PAD(entry->bytes)) {
return BadLength;
}
}
if (left < cmdlen) {
return BadLength;
}
/*
** Skip over the header and execute the command. We allow the
** caller to trash the command memory. This is useful especially
** for things that require double alignment - they can just shift
** the data towards lower memory (trashing the header) by 4 bytes
** and achieve the required alignment.
*/
(*proc)(pc + __GLX_RENDER_HDR_SIZE);
pc += cmdlen;
left -= cmdlen;
commandsDone++;
}
__GLX_NOTE_UNFLUSHED_CMDS(cx);
return Success;
return DoRender(cl, pc, True);
}
/*
** Execute a large rendering request (one that spans multiple X requests).
*/
int __glXSwapRenderLarge(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_RenderLarge(__GLXclientState *cl, GLbyte *pc)
{
xGLXRenderLargeReq *req;
ClientPtr client= cl->client;
size_t dataBytes;
void (*proc)(GLbyte *);
__GLXrenderLargeHeader *hdr;
__GLXcontext *cx;
int error;
CARD16 opcode;
__GLX_DECLARE_SWAP_VARIABLES;
/*
** NOTE: much of this code also appears in the nonswapping version of this
** routine, __glXRenderLarge(). Any changes made here should also be
** duplicated there.
*/
req = (xGLXRenderLargeReq *) pc;
__GLX_SWAP_SHORT(&req->length);
__GLX_SWAP_INT(&req->contextTag);
__GLX_SWAP_INT(&req->dataBytes);
__GLX_SWAP_SHORT(&req->requestNumber);
__GLX_SWAP_SHORT(&req->requestTotal);
cx = __glXForceCurrent(cl, req->contextTag, &error);
if (!cx) {
/* Reset in case this isn't 1st request. */
__glXResetLargeCommandStatus(cl);
return error;
}
dataBytes = req->dataBytes;
/*
** Check the request length.
*/
if ((req->length << 2) != __GLX_PAD(dataBytes) + sz_xGLXRenderLargeReq) {
client->errorValue = req->length;
/* Reset in case this isn't 1st request. */
__glXResetLargeCommandStatus(cl);
return BadLength;
}
pc += sz_xGLXRenderLargeReq;
if (cl->largeCmdRequestsSoFar == 0) {
__GLXrenderSizeData *entry;
int extra;
size_t cmdlen;
/*
** This is the first request of a multi request command.
** Make enough space in the buffer, then copy the entire request.
*/
if (req->requestNumber != 1) {
client->errorValue = req->requestNumber;
return __glXError(GLXBadLargeRequest);
}
hdr = (__GLXrenderLargeHeader *) pc;
__GLX_SWAP_INT(&hdr->length);
__GLX_SWAP_INT(&hdr->opcode);
cmdlen = hdr->length;
opcode = hdr->opcode;
if ( (opcode >= __GLX_MIN_RENDER_OPCODE) &&
(opcode <= __GLX_MAX_RENDER_OPCODE) ) {
entry = &__glXRenderSizeTable[opcode];
proc = __glXSwapRenderTable[opcode];
#if __GLX_MAX_RENDER_OPCODE_EXT > __GLX_MIN_RENDER_OPCODE_EXT
} else if ( (opcode >= __GLX_MIN_RENDER_OPCODE_EXT) &&
(opcode <= __GLX_MAX_RENDER_OPCODE_EXT) ) {
int index = opcode - __GLX_MIN_RENDER_OPCODE_EXT;
entry = &__glXRenderSizeTable_EXT[index];
proc = __glXSwapRenderTable_EXT[index];
#endif /* __GLX_MAX_RENDER_OPCODE_EXT > __GLX_MIN_RENDER_OPCODE_EXT */
} else {
client->errorValue = opcode;
return __glXError(GLXBadLargeRequest);
}
if (!entry->bytes) {
/* unused opcode */
client->errorValue = opcode;
return __glXError(GLXBadLargeRequest);
}
if (entry->varsize) {
/*
** If it's a variable-size command (a command whose length must
** be computed from its parameters), all the parameters needed
** will be in the 1st request, so it's okay to do this.
*/
extra = (*entry->varsize)(pc + __GLX_RENDER_LARGE_HDR_SIZE, True);
if (extra < 0) {
extra = 0;
}
/* large command's header is 4 bytes longer, so add 4 */
if (cmdlen != __GLX_PAD(entry->bytes + 4 + extra)) {
return BadLength;
}
} else {
/* constant size command */
if (cmdlen != __GLX_PAD(entry->bytes + 4)) {
return BadLength;
}
}
/*
** Make enough space in the buffer, then copy the entire request.
*/
if (cl->largeCmdBufSize < cmdlen) {
if (!cl->largeCmdBuf) {
cl->largeCmdBuf = (GLbyte *) xalloc(cmdlen);
} else {
cl->largeCmdBuf = (GLbyte *) xrealloc(cl->largeCmdBuf, cmdlen);
}
if (!cl->largeCmdBuf) {
return BadAlloc;
}
cl->largeCmdBufSize = cmdlen;
}
memcpy(cl->largeCmdBuf, pc, dataBytes);
cl->largeCmdBytesSoFar = dataBytes;
cl->largeCmdBytesTotal = cmdlen;
cl->largeCmdRequestsSoFar = 1;
cl->largeCmdRequestsTotal = req->requestTotal;
return Success;
} else {
/*
** We are receiving subsequent (i.e. not the first) requests of a
** multi request command.
*/
/*
** Check the request number and the total request count.
*/
if (req->requestNumber != cl->largeCmdRequestsSoFar + 1) {
client->errorValue = req->requestNumber;
__glXResetLargeCommandStatus(cl);
return __glXError(GLXBadLargeRequest);
}
if (req->requestTotal != cl->largeCmdRequestsTotal) {
client->errorValue = req->requestTotal;
__glXResetLargeCommandStatus(cl);
return __glXError(GLXBadLargeRequest);
}
/*
** Check that we didn't get too much data.
*/
if ((cl->largeCmdBytesSoFar + dataBytes) > cl->largeCmdBytesTotal) {
client->errorValue = dataBytes;
__glXResetLargeCommandStatus(cl);
return __glXError(GLXBadLargeRequest);
}
memcpy(cl->largeCmdBuf + cl->largeCmdBytesSoFar, pc, dataBytes);
cl->largeCmdBytesSoFar += dataBytes;
cl->largeCmdRequestsSoFar++;
if (req->requestNumber == cl->largeCmdRequestsTotal) {
/*
** This is the last request; it must have enough bytes to complete
** the command.
*/
/* NOTE: the two pad macros have been added below; they are needed
** because the client library pads the total byte count, but not
** the per-request byte counts. The Protocol Encoding says the
** total byte count should not be padded, so a proposal will be
** made to the ARB to relax the padding constraint on the total
** byte count, thus preserving backward compatibility. Meanwhile,
** the padding done below fixes a bug that did not allow
** large commands of odd sizes to be accepted by the server.
*/
if (__GLX_PAD(cl->largeCmdBytesSoFar) !=
__GLX_PAD(cl->largeCmdBytesTotal)) {
client->errorValue = dataBytes;
__glXResetLargeCommandStatus(cl);
return __glXError(GLXBadLargeRequest);
}
hdr = (__GLXrenderLargeHeader *) cl->largeCmdBuf;
/*
** The opcode and length field in the header had already been
** swapped when the first request was received.
*/
/*
** Use the opcode to index into the procedure table.
*/
opcode = hdr->opcode;
if ( (opcode >= __GLX_MIN_RENDER_OPCODE) &&
(opcode <= __GLX_MAX_RENDER_OPCODE) ) {
proc = __glXSwapRenderTable[opcode];
#if __GLX_MAX_RENDER_OPCODE_EXT > __GLX_MIN_RENDER_OPCODE_EXT
} else if ( (opcode >= __GLX_MIN_RENDER_OPCODE_EXT) &&
(opcode <= __GLX_MAX_RENDER_OPCODE_EXT) ) {
int index = opcode - __GLX_MIN_RENDER_OPCODE_EXT;
proc = __glXSwapRenderTable_EXT[index];
#endif /* __GLX_MAX_RENDER_OPCODE_EXT > __GLX_MIN_RENDER_OPCODE_EXT */
} else {
client->errorValue = opcode;
return __glXError(GLXBadLargeRequest);
}
/*
** Skip over the header and execute the command.
*/
(*proc)(cl->largeCmdBuf + __GLX_RENDER_LARGE_HDR_SIZE);
__GLX_NOTE_UNFLUSHED_CMDS(cx);
/*
** Reset for the next RenderLarge series.
*/
__glXResetLargeCommandStatus(cl);
} else {
/*
** This is neither the first nor the last request.
*/
}
return Success;
}
return DoRenderLarge(cl, pc, True);
}
/************************************************************************/
@ -969,10 +659,11 @@ int __glXSwapRenderLarge(__GLXclientState *cl, GLbyte *pc)
** allocating these entry points in the dispatch table.
*/
int __glXSwapVendorPrivate(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_VendorPrivate(__GLXclientState *cl, GLbyte *pc)
{
xGLXVendorPrivateReq *req;
GLint vendorcode;
__GLXdispatchVendorPrivProcPtr proc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -982,41 +673,24 @@ int __glXSwapVendorPrivate(__GLXclientState *cl, GLbyte *pc)
vendorcode = req->vendorCode;
#ifndef __DARWIN__
switch( vendorcode ) {
case X_GLvop_SampleMaskSGIS:
__GLX_SWAP_FLOAT(pc + 4);
__GLX_SWAP_INT(pc + 8);
CALL_SampleMaskSGIS( GET_DISPATCH(),
(*(GLfloat *)(pc + 4), *(GLboolean *)(pc + 8)) );
return Success;
case X_GLvop_SamplePatternSGIS:
__GLX_SWAP_INT(pc + 4);
CALL_SamplePatternSGIS( GET_DISPATCH(), (*(GLenum *)(pc + 4)) );
return Success;
case X_GLXvop_BindTexImageEXT:
return __glXSwapBindTexImageEXT(cl, pc);
case X_GLXvop_ReleaseTexImageEXT:
return __glXSwapReleaseTexImageEXT(cl, pc);
case X_GLXvop_CopySubBufferMESA:
return __glXSwapCopySubBufferMESA(cl, pc);
}
#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);
proc = (__GLXdispatchVendorPrivProcPtr)
__glXGetProtocolDecodeFunction(& VendorPriv_dispatch_info,
vendorcode, 1);
if (proc != NULL) {
(*proc)(cl, (GLbyte*)req);
return Success;
}
cl->client->errorValue = req->vendorCode;
return __glXError(GLXUnsupportedPrivateRequest);
}
int __glXSwapVendorPrivateWithReply(__GLXclientState *cl, GLbyte *pc)
int __glXDispSwap_VendorPrivateWithReply(__GLXclientState *cl, GLbyte *pc)
{
xGLXVendorPrivateWithReplyReq *req;
GLint vendorcode;
__GLXdispatchVendorPrivProcPtr proc;
__GLX_DECLARE_SWAP_VARIABLES;
@ -1026,42 +700,13 @@ int __glXSwapVendorPrivateWithReply(__GLXclientState *cl, GLbyte *pc)
vendorcode = req->vendorCode;
switch (vendorcode) {
case X_GLXvop_QueryContextInfoEXT:
return __glXSwapQueryContextInfoEXT(cl, pc);
case X_GLXvop_MakeCurrentReadSGI:
return __glXSwapMakeCurrentReadSGI(cl, pc);
case X_GLXvop_GetFBConfigsSGIX:
return __glXSwapGetFBConfigsSGIX(cl, pc);
case X_GLXvop_CreateContextWithConfigSGIX:
return __glXSwapCreateContextWithConfigSGIX(cl, pc);
case X_GLXvop_CreateGLXPixmapWithConfigSGIX:
return __glXSwapCreateGLXPixmapWithConfigSGIX(cl, pc);
case X_GLXvop_GetDrawableAttributesSGIX:
return __glXSwapGetDrawableAttributesSGIX(cl, pc);
case X_GLvop_IsRenderbufferEXT:
return __glXDispSwap_IsRenderbufferEXT(cl, pc);
case X_GLvop_GenRenderbuffersEXT:
return __glXDispSwap_GenRenderbuffersEXT(cl, pc);
case X_GLvop_GetRenderbufferParameterivEXT:
return __glXDispSwap_GetRenderbufferParameterivEXT(cl, pc);
case X_GLvop_IsFramebufferEXT:
return __glXDispSwap_IsFramebufferEXT(cl, pc);
case X_GLvop_GenFramebuffersEXT:
return __glXDispSwap_GenFramebuffersEXT(cl, pc);
case X_GLvop_CheckFramebufferStatusEXT:
return __glXDispSwap_CheckFramebufferStatusEXT(cl, pc);
case X_GLvop_GetFramebufferAttachmentParameterivEXT:
return __glXDispSwap_GetFramebufferAttachmentParameterivEXT(cl, pc);
default:
break;
proc = (__GLXdispatchVendorPrivProcPtr)
__glXGetProtocolDecodeFunction(& VendorPriv_dispatch_info,
vendorcode, 1);
if (proc != NULL) {
return (*proc)(cl, (GLbyte*)req);
}
if ((vendorcode >= __GLX_MIN_VENDPRIV_OPCODE_EXT) &&
(vendorcode <= __GLX_MAX_VENDPRIV_OPCODE_EXT)) {
return (*__glXSwapVendorPrivTable_EXT[vendorcode-__GLX_MIN_VENDPRIV_OPCODE_EXT])(cl, (GLbyte*)req);
}
cl->client->errorValue = req->vendorCode;
return __glXError(GLXUnsupportedPrivateRequest);
}

View File

@ -32,6 +32,8 @@
#include "unpack.h"
#include "glxutil.h"
#include "glxext.h"
#include "indirect_table.h"
#include "indirect_util.h"
/*
** The last context used by the server. It is the context that is current
@ -452,7 +454,7 @@ static int __glXDispatch(ClientPtr client)
{
REQUEST(xGLXSingleReq);
CARD8 opcode;
int (*proc)(__GLXclientState *cl, GLbyte *pc);
__GLXdispatchSingleProcPtr proc;
__GLXclientState *cl;
int retval;
@ -481,13 +483,6 @@ static int __glXDispatch(ClientPtr client)
cl->client = client;
}
/*
** Check for valid opcode.
*/
if (opcode >= __GLX_SINGLE_TABLE_SIZE) {
return BadRequest;
}
/*
** If we're expecting a glXRenderLarge request, this better be one.
*/
@ -499,29 +494,27 @@ static int __glXDispatch(ClientPtr client)
/*
** Use the opcode to index into the procedure table.
*/
if (client->swapped)
proc = __glXSwapSingleTable[opcode];
else
proc = __glXSingleTable[opcode];
proc = (__GLXdispatchSingleProcPtr) __glXGetProtocolDecodeFunction(& Single_dispatch_info,
opcode,
client->swapped);
if (proc != NULL) {
__glXleaveServer();
__glXleaveServer();
inDispatch = True;
inDispatch = True;
retval = (*proc)(cl, (GLbyte *) stuff);
retval = proc(cl, (GLbyte *) stuff);
inDispatch = False;
inDispatch = False;
__glXenterServer();
__glXenterServer();
}
else {
retval = BadRequest;
}
return retval;
}
int __glXNoSuchSingleOpcode(__GLXclientState *cl, GLbyte *pc)
{
return BadRequest;
}
void __glXNoSuchRenderOpcode(GLbyte *pc)
{
return;

View File

@ -67,7 +67,6 @@ extern GLboolean __glXFreeContext(__GLXcontext *glxc);
extern void __glXFlushContextCache(void);
extern void __glXNoSuchRenderOpcode(GLbyte*);
extern int __glXNoSuchSingleOpcode(__GLXclientState*, GLbyte*);
extern void __glXErrorCallBack(__GLinterface *gc, GLenum code);
extern void __glXClearErrorOccured(void);
extern GLboolean __glXErrorOccured(void);
@ -90,6 +89,9 @@ extern int DoDestroyPixmap(__GLXclientState *cl, XID glxpixmapId);
extern int DoQueryContext(__GLXclientState *cl, GLXContextID gcId);
extern int DoRender(__GLXclientState *cl, GLbyte *pc, int do_swap);
extern int DoRenderLarge(__GLXclientState *cl, GLbyte *pc, int do_swap);
extern void GlxExtensionInit(void);
extern Bool __glXCoreType(void);

View File

@ -48,8 +48,11 @@
const char GLServerVersion[] = "1.2";
static const char GLServerExtensions[] =
"GL_ARB_depth_texture "
"GL_ARB_draw_buffers "
"GL_ARB_imaging "
"GL_ARB_multisample "
"GL_ARB_multitexture "
"GL_ARB_occlusion_query "
"GL_ARB_point_parameters "
"GL_ARB_point_sprite "
"GL_ARB_shadow "
@ -61,9 +64,9 @@ static const char GLServerExtensions[] =
"GL_ARB_texture_env_crossbar "
"GL_ARB_texture_env_dot3 "
"GL_ARB_texture_mirrored_repeat "
"GL_ARB_texture_non_power_of_two "
"GL_ARB_transpose_matrix "
"GL_ARB_window_pos "
"GL_ARB_texture_non_power_of_two "
"GL_EXT_abgr "
"GL_EXT_bgra "
"GL_EXT_blend_color "
@ -75,8 +78,10 @@ static const char GLServerExtensions[] =
"GL_EXT_copy_texture "
"GL_EXT_draw_range_elements "
"GL_EXT_fog_coord "
"GL_EXT_framebuffer_object "
"GL_EXT_multi_draw_arrays "
"GL_EXT_packed_pixels "
"GL_EXT_point_parameters "
"GL_EXT_polygon_offset "
"GL_EXT_rescale_normal "
"GL_EXT_secondary_color "
@ -93,29 +98,40 @@ static const char GLServerExtensions[] =
"GL_EXT_texture_env_dot3 "
"GL_EXT_texture_lod "
"GL_EXT_texture_lod_bias "
"GL_EXT_texture_mirror_clamp "
"GL_EXT_texture_object "
"GL_EXT_texture_rectangle "
"GL_EXT_vertex_array "
"GL_EXT_framebuffer_object "
"GL_APPLE_packed_pixels "
"GL_ATI_texture_mirror_once "
"GL_ATI_draw_buffers "
"GL_ATI_texture_env_combine3 "
"GL_ATI_texture_mirror_once "
"GL_HP_occlusion_test "
"GL_IBM_texture_mirrored_repeat "
"GL_INGR_blend_func_separate "
"GL_MESA_pack_invert "
"GL_MESA_ycbcr_texture "
"GL_NV_blend_square "
"GL_NV_depth_clamp "
"GL_NV_fog_distance "
"GL_NV_light_max_exponent "
"GL_NV_multisample_filter_hint "
"GL_NV_point_sprite "
"GL_NV_texgen_reflection "
"GL_NV_texture_rectangle "
"GL_NV_texture_env_combine4 "
"GL_NV_texture_expand_normal "
"GL_NV_texture_rectangle "
"GL_SGI_color_matrix "
"GL_SGIS_generate_mipmap "
"GL_SGIS_multisample "
"GL_SGIS_point_parameters "
"GL_SGIS_texture_border_clamp "
"GL_SGIS_texture_edge_clamp "
"GL_SGIS_texture_lod "
"GL_SGIX_depth_texture "
"GL_SGIX_shadow "
"GL_SGIX_shadow_ambient "
"GL_SUN_slice_accum "
;
/*

View File

@ -196,12 +196,12 @@ extern __GLXprocPtr __glXProcTable[];
/*
* Tables for computing the size of each rendering command.
*/
typedef int (*gl_proto_size_func)(const GLbyte *, Bool);
typedef struct {
int bytes;
int (*varsize)(const GLbyte *pc, Bool swap);
gl_proto_size_func varsize;
} __GLXrenderSizeData;
extern __GLXrenderSizeData __glXRenderSizeTable[];
extern __GLXrenderSizeData __glXRenderSizeTable_EXT[];
/************************************************************************/
@ -252,6 +252,6 @@ extern int __glXImageSize(GLenum format, GLenum type,
GLint imageHeight, GLint rowLength, GLint skipImages, GLint skipRows,
GLint alignment);
extern int __glXDrawArraysSize(const GLbyte *pc, Bool swap);
extern int __glXDrawArraysReqSize(const GLbyte *pc, Bool swap);
#endif /* !__GLX_server_h__ */

View File

@ -67,6 +67,8 @@ extern HIDDEN void __glXDisp_Histogram(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Histogram(GLbyte * pc);
extern HIDDEN int __glXDisp_GetMapfv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetMapfv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_RasterPos4dv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_RasterPos4dv(GLbyte * pc);
extern HIDDEN void __glXDisp_PolygonStipple(GLbyte * pc);
extern HIDDEN void __glXDispSwap_PolygonStipple(GLbyte * pc);
extern HIDDEN int __glXDisp_GetPixelMapfv(struct __GLXclientStateRec *, GLbyte *);
@ -79,16 +81,26 @@ extern HIDDEN void __glXDisp_VertexAttrib4svNV(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttrib4svNV(GLbyte * pc);
extern HIDDEN void __glXDisp_EvalCoord2fv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_EvalCoord2fv(GLbyte * pc);
extern HIDDEN int __glXDisp_DestroyPixmap(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_DestroyPixmap(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_ProgramEnvParameter4dvARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_ProgramEnvParameter4dvARB(GLbyte * pc);
extern HIDDEN int __glXDisp_GetMapiv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetMapiv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_SwapBuffers(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_SwapBuffers(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_Indexubv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Indexubv(GLbyte * pc);
extern HIDDEN int __glXDisp_Render(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_Render(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_GetQueryivARB(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetQueryivARB(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_TexImage3D(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexImage3D(GLbyte * pc);
extern HIDDEN int __glXDisp_MakeContextCurrent(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_MakeContextCurrent(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_GetFBConfigs(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetFBConfigs(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_Color3ubv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Color3ubv(GLbyte * pc);
extern HIDDEN int __glXDisp_GetQueryObjectivARB(struct __GLXclientStateRec *, GLbyte *);
@ -105,16 +117,18 @@ extern HIDDEN void __glXDisp_VertexAttribs1dvNV(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttribs1dvNV(GLbyte * pc);
extern HIDDEN void __glXDisp_Normal3bv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Normal3bv(GLbyte * pc);
extern HIDDEN void __glXDisp_TexGeniv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexGeniv(GLbyte * pc);
extern HIDDEN int __glXDisp_VendorPrivate(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_VendorPrivate(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_CreateGLXPixmapWithConfigSGIX(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_CreateGLXPixmapWithConfigSGIX(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_Vertex3iv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Vertex3iv(GLbyte * pc);
extern HIDDEN void __glXDisp_CopyConvolutionFilter1D(GLbyte * pc);
extern HIDDEN void __glXDispSwap_CopyConvolutionFilter1D(GLbyte * pc);
extern HIDDEN void __glXDisp_BlendColor(GLbyte * pc);
extern HIDDEN void __glXDispSwap_BlendColor(GLbyte * pc);
extern HIDDEN void __glXDisp_CallLists(GLbyte * pc);
extern HIDDEN void __glXDispSwap_CallLists(GLbyte * pc);
extern HIDDEN void __glXDisp_Scalef(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Scalef(GLbyte * pc);
extern HIDDEN void __glXDisp_Normal3iv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Normal3iv(GLbyte * pc);
extern HIDDEN void __glXDisp_PassThrough(GLbyte * pc);
@ -123,8 +137,10 @@ extern HIDDEN void __glXDisp_Viewport(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Viewport(GLbyte * pc);
extern HIDDEN void __glXDisp_VertexAttrib4NusvARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttrib4NusvARB(GLbyte * pc);
extern HIDDEN void __glXDisp_PrioritizeTextures(GLbyte * pc);
extern HIDDEN void __glXDispSwap_PrioritizeTextures(GLbyte * pc);
extern HIDDEN void __glXDisp_CopyTexSubImage2D(GLbyte * pc);
extern HIDDEN void __glXDispSwap_CopyTexSubImage2D(GLbyte * pc);
extern HIDDEN void __glXDisp_DepthRange(GLbyte * pc);
extern HIDDEN void __glXDispSwap_DepthRange(GLbyte * pc);
extern HIDDEN void __glXDisp_ResetHistogram(GLbyte * pc);
extern HIDDEN void __glXDispSwap_ResetHistogram(GLbyte * pc);
extern HIDDEN int __glXDisp_GetProgramNamedParameterfvNV(struct __GLXclientStateRec *, GLbyte *);
@ -145,10 +161,14 @@ extern HIDDEN int __glXDisp_GetConvolutionParameteriv(struct __GLXclientStateRec
extern HIDDEN int __glXDispSwap_GetConvolutionParameteriv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_Vertex2dv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Vertex2dv(GLbyte * pc);
extern HIDDEN int __glXDisp_GetVisualConfigs(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetVisualConfigs(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_MultiTexCoord1fvARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_MultiTexCoord1fvARB(GLbyte * pc);
extern HIDDEN void __glXDisp_TexCoord3iv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexCoord3iv(GLbyte * pc);
extern HIDDEN int __glXDisp_CopyContext(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_CopyContext(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_Color3fv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Color3fv(GLbyte * pc);
extern HIDDEN void __glXDisp_PointSize(GLbyte * pc);
@ -161,36 +181,40 @@ extern HIDDEN void __glXDisp_Vertex4sv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Vertex4sv(GLbyte * pc);
extern HIDDEN int __glXDisp_GetTexEnvfv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetTexEnvfv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_LineStipple(GLbyte * pc);
extern HIDDEN void __glXDispSwap_LineStipple(GLbyte * pc);
extern HIDDEN void __glXDisp_TexEnvi(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexEnvi(GLbyte * pc);
extern HIDDEN int __glXDisp_GetClipPlane(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetClipPlane(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_VertexAttribs3dvNV(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttribs3dvNV(GLbyte * pc);
extern HIDDEN void __glXDisp_LightModeli(GLbyte * pc);
extern HIDDEN void __glXDispSwap_LightModeli(GLbyte * pc);
extern HIDDEN void __glXDisp_VertexAttribs4fvNV(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttribs4fvNV(GLbyte * pc);
extern HIDDEN void __glXDisp_Scaled(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Scaled(GLbyte * pc);
extern HIDDEN void __glXDisp_Scalef(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Scalef(GLbyte * pc);
extern HIDDEN void __glXDisp_CallLists(GLbyte * pc);
extern HIDDEN void __glXDispSwap_CallLists(GLbyte * pc);
extern HIDDEN void __glXDisp_AlphaFunc(GLbyte * pc);
extern HIDDEN void __glXDispSwap_AlphaFunc(GLbyte * pc);
extern HIDDEN void __glXDisp_TexCoord2iv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexCoord2iv(GLbyte * pc);
extern HIDDEN void __glXDisp_CompressedTexImage1DARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_CompressedTexImage1DARB(GLbyte * pc);
extern HIDDEN void __glXDisp_Rotated(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Rotated(GLbyte * pc);
extern HIDDEN int __glXDisp_ReadPixels(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_ReadPixels(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_EdgeFlagv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_EdgeFlagv(GLbyte * pc);
extern HIDDEN void __glXDisp_Color4iv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Color4iv(GLbyte * pc);
extern HIDDEN void __glXDisp_Rotatef(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Rotatef(GLbyte * pc);
extern HIDDEN void __glXDisp_TexParameterf(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexParameterf(GLbyte * pc);
extern HIDDEN void __glXDisp_TexParameteri(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexParameteri(GLbyte * pc);
extern HIDDEN int __glXDisp_DestroyContext(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_DestroyContext(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_DrawPixels(GLbyte * pc);
extern HIDDEN void __glXDispSwap_DrawPixels(GLbyte * pc);
extern HIDDEN void __glXDisp_MultiTexCoord2svARB(GLbyte * pc);
@ -215,8 +239,6 @@ extern HIDDEN void __glXDisp_Color4usv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Color4usv(GLbyte * pc);
extern HIDDEN void __glXDisp_Fogi(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Fogi(GLbyte * pc);
extern HIDDEN void __glXDisp_DepthRange(GLbyte * pc);
extern HIDDEN void __glXDispSwap_DepthRange(GLbyte * pc);
extern HIDDEN void __glXDisp_RasterPos3iv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_RasterPos3iv(GLbyte * pc);
extern HIDDEN void __glXDisp_PixelMapfv(GLbyte * pc);
@ -229,8 +251,6 @@ extern HIDDEN int __glXDisp_AreTexturesResident(struct __GLXclientStateRec *, GL
extern HIDDEN int __glXDispSwap_AreTexturesResident(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_IsRenderbufferEXT(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_IsRenderbufferEXT(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_ColorTableParameteriv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_ColorTableParameteriv(GLbyte * pc);
extern HIDDEN void __glXDisp_PointParameterfvEXT(GLbyte * pc);
extern HIDDEN void __glXDispSwap_PointParameterfvEXT(GLbyte * pc);
extern HIDDEN void __glXDisp_Color3bv(GLbyte * pc);
@ -291,8 +311,14 @@ extern HIDDEN int __glXDisp_CheckFramebufferStatusEXT(struct __GLXclientStateRec
extern HIDDEN int __glXDispSwap_CheckFramebufferStatusEXT(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_GetVertexAttribivARB(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetVertexAttribivARB(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_GetFBConfigsSGIX(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetFBConfigsSGIX(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_CreateNewContext(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_CreateNewContext(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_GetMinmax(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetMinmax(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_GetVertexAttribdvNV(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetVertexAttribdvNV(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_Normal3fv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Normal3fv(GLbyte * pc);
extern HIDDEN void __glXDisp_VertexAttrib4ivARB(GLbyte * pc);
@ -305,6 +331,8 @@ extern HIDDEN void __glXDisp_MultiTexCoord3fvARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_MultiTexCoord3fvARB(GLbyte * pc);
extern HIDDEN int __glXDisp_GetProgramParameterfvNV(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetProgramParameterfvNV(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_BindTexture(GLbyte * pc);
extern HIDDEN void __glXDispSwap_BindTexture(GLbyte * pc);
extern HIDDEN void __glXDisp_TexSubImage2D(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexSubImage2D(GLbyte * pc);
extern HIDDEN void __glXDisp_DeleteRenderbuffersEXT(GLbyte * pc);
@ -313,8 +341,12 @@ extern HIDDEN void __glXDisp_TexGenfv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexGenfv(GLbyte * pc);
extern HIDDEN void __glXDisp_VertexAttrib4bvARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttrib4bvARB(GLbyte * pc);
extern HIDDEN int __glXDisp_CreateContextWithConfigSGIX(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_CreateContextWithConfigSGIX(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_FramebufferTexture3DEXT(GLbyte * pc);
extern HIDDEN void __glXDispSwap_FramebufferTexture3DEXT(GLbyte * pc);
extern HIDDEN int __glXDisp_CopySubBufferMESA(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_CopySubBufferMESA(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_BlendEquation(GLbyte * pc);
extern HIDDEN void __glXDispSwap_BlendEquation(GLbyte * pc);
extern HIDDEN int __glXDisp_GetError(struct __GLXclientStateRec *, GLbyte *);
@ -337,6 +369,8 @@ extern HIDDEN void __glXDisp_EndQueryARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_EndQueryARB(GLbyte * pc);
extern HIDDEN void __glXDisp_DepthMask(GLbyte * pc);
extern HIDDEN void __glXDispSwap_DepthMask(GLbyte * pc);
extern HIDDEN void __glXDisp_Rotated(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Rotated(GLbyte * pc);
extern HIDDEN int __glXDisp_GetMaterialiv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetMaterialiv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_StencilOp(GLbyte * pc);
@ -345,6 +379,8 @@ extern HIDDEN void __glXDisp_MultiTexCoord3svARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_MultiTexCoord3svARB(GLbyte * pc);
extern HIDDEN void __glXDisp_TexEnvfv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexEnvfv(GLbyte * pc);
extern HIDDEN int __glXDisp_QueryServerString(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_QueryServerString(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_LoadMatrixf(GLbyte * pc);
extern HIDDEN void __glXDispSwap_LoadMatrixf(GLbyte * pc);
extern HIDDEN void __glXDisp_Color4bv(GLbyte * pc);
@ -361,6 +397,8 @@ extern HIDDEN void __glXDisp_LogicOp(GLbyte * pc);
extern HIDDEN void __glXDispSwap_LogicOp(GLbyte * pc);
extern HIDDEN void __glXDisp_TexCoord4fv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexCoord4fv(GLbyte * pc);
extern HIDDEN int __glXDisp_WaitX(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_WaitX(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_VertexAttrib2dvNV(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttrib2dvNV(GLbyte * pc);
extern HIDDEN void __glXDisp_FramebufferRenderbufferEXT(GLbyte * pc);
@ -371,6 +409,8 @@ extern HIDDEN int __glXDisp_GenTextures(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GenTextures(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_FramebufferTexture1DEXT(GLbyte * pc);
extern HIDDEN void __glXDispSwap_FramebufferTexture1DEXT(GLbyte * pc);
extern HIDDEN int __glXDisp_GetDrawableAttributes(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetDrawableAttributes(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_ProgramParameter4fvNV(GLbyte * pc);
extern HIDDEN void __glXDispSwap_ProgramParameter4fvNV(GLbyte * pc);
extern HIDDEN void __glXDisp_RasterPos2sv(GLbyte * pc);
@ -383,6 +423,8 @@ extern HIDDEN void __glXDisp_TexCoord2fv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexCoord2fv(GLbyte * pc);
extern HIDDEN void __glXDisp_TexCoord1sv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexCoord1sv(GLbyte * pc);
extern HIDDEN void __glXDisp_TexGeniv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexGeniv(GLbyte * pc);
extern HIDDEN void __glXDisp_DepthFunc(GLbyte * pc);
extern HIDDEN void __glXDispSwap_DepthFunc(GLbyte * pc);
extern HIDDEN void __glXDisp_PixelMapusv(GLbyte * pc);
@ -391,6 +433,8 @@ extern HIDDEN void __glXDisp_PointParameterivNV(GLbyte * pc);
extern HIDDEN void __glXDispSwap_PointParameterivNV(GLbyte * pc);
extern HIDDEN void __glXDisp_BlendFunc(GLbyte * pc);
extern HIDDEN void __glXDispSwap_BlendFunc(GLbyte * pc);
extern HIDDEN int __glXDisp_WaitGL(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_WaitGL(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_MultiTexCoord3dvARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_MultiTexCoord3dvARB(GLbyte * pc);
extern HIDDEN void __glXDisp_ProgramNamedParameter4dvNV(GLbyte * pc);
@ -407,22 +451,26 @@ extern HIDDEN void __glXDisp_PushAttrib(GLbyte * pc);
extern HIDDEN void __glXDispSwap_PushAttrib(GLbyte * pc);
extern HIDDEN void __glXDisp_VertexAttrib4usvARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttrib4usvARB(GLbyte * pc);
extern HIDDEN int __glXDisp_DestroyPbuffer(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_DestroyPbuffer(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_TexParameteriv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexParameteriv(GLbyte * pc);
extern HIDDEN void __glXDisp_WindowPos3fvMESA(GLbyte * pc);
extern HIDDEN void __glXDispSwap_WindowPos3fvMESA(GLbyte * pc);
extern HIDDEN void __glXDisp_VertexAttrib1svNV(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttrib1svNV(GLbyte * pc);
extern HIDDEN int __glXDisp_QueryExtensionsString(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_QueryExtensionsString(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_RasterPos3fv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_RasterPos3fv(GLbyte * pc);
extern HIDDEN void __glXDisp_CopyTexSubImage3D(GLbyte * pc);
extern HIDDEN void __glXDispSwap_CopyTexSubImage3D(GLbyte * pc);
extern HIDDEN int __glXDisp_GetColorTable(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetColorTable(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_SelectBuffer(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_SelectBuffer(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_Indexiv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Indexiv(GLbyte * pc);
extern HIDDEN int __glXDisp_CreateContext(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_CreateContext(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_CopyColorTable(GLbyte * pc);
extern HIDDEN void __glXDispSwap_CopyColorTable(GLbyte * pc);
extern HIDDEN int __glXDisp_GetHistogramParameterfv(struct __GLXclientStateRec *, GLbyte *);
@ -431,8 +479,12 @@ extern HIDDEN void __glXDisp_Frustum(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Frustum(GLbyte * pc);
extern HIDDEN int __glXDisp_GetString(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetString(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_CreateGLXPixmap(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_CreateGLXPixmap(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_TexEnvf(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexEnvf(GLbyte * pc);
extern HIDDEN int __glXDisp_GetProgramStringARB(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetProgramStringARB(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_MultiTexCoord3ivARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_MultiTexCoord3ivARB(GLbyte * pc);
extern HIDDEN void __glXDisp_VertexAttrib1dvARB(GLbyte * pc);
@ -443,16 +495,18 @@ extern HIDDEN int __glXDisp_GetTexLevelParameteriv(struct __GLXclientStateRec *,
extern HIDDEN int __glXDispSwap_GetTexLevelParameteriv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_ClearAccum(GLbyte * pc);
extern HIDDEN void __glXDispSwap_ClearAccum(GLbyte * pc);
extern HIDDEN int __glXDisp_QueryVersion(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_QueryVersion(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_GetVertexAttribfvARB(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetVertexAttribfvARB(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_SecondaryColor3ivEXT(GLbyte * pc);
extern HIDDEN void __glXDispSwap_SecondaryColor3ivEXT(GLbyte * pc);
extern HIDDEN void __glXDisp_TexCoord4iv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexCoord4iv(GLbyte * pc);
extern HIDDEN void __glXDisp_PolygonOffset(GLbyte * pc);
extern HIDDEN void __glXDispSwap_PolygonOffset(GLbyte * pc);
extern HIDDEN void __glXDisp_SampleMaskSGIS(GLbyte * pc);
extern HIDDEN void __glXDispSwap_SampleMaskSGIS(GLbyte * pc);
extern HIDDEN void __glXDisp_ColorTableParameteriv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_ColorTableParameteriv(GLbyte * pc);
extern HIDDEN void __glXDisp_VertexAttrib4ubvARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttrib4ubvARB(GLbyte * pc);
extern HIDDEN void __glXDisp_CopyTexImage2D(GLbyte * pc);
@ -467,6 +521,8 @@ extern HIDDEN void __glXDisp_Color4fv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Color4fv(GLbyte * pc);
extern HIDDEN void __glXDisp_MultiTexCoord4ivARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_MultiTexCoord4ivARB(GLbyte * pc);
extern HIDDEN int __glXDisp_CreatePixmap(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_CreatePixmap(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_Lightiv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Lightiv(GLbyte * pc);
extern HIDDEN int __glXDisp_GetQueryObjectuivARB(struct __GLXclientStateRec *, GLbyte *);
@ -479,8 +535,6 @@ extern HIDDEN void __glXDisp_VertexAttrib2dvARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttrib2dvARB(GLbyte * pc);
extern HIDDEN void __glXDisp_VertexAttribs2svNV(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttribs2svNV(GLbyte * pc);
extern HIDDEN void __glXDisp_VertexAttrib2fvARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttrib2fvARB(GLbyte * pc);
extern HIDDEN void __glXDisp_Rectdv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Rectdv(GLbyte * pc);
extern HIDDEN void __glXDisp_VertexAttrib4NivARB(GLbyte * pc);
@ -495,8 +549,8 @@ extern HIDDEN void __glXDisp_CompressedTexSubImage1DARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_CompressedTexSubImage1DARB(GLbyte * pc);
extern HIDDEN int __glXDisp_GetVertexAttribivNV(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetVertexAttribivNV(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_GetProgramStringARB(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetProgramStringARB(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_IsQueryARB(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_IsQueryARB(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_TexGeni(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexGeni(GLbyte * pc);
extern HIDDEN void __glXDisp_TexGenf(GLbyte * pc);
@ -513,6 +567,8 @@ extern HIDDEN void __glXDisp_VertexAttribs1fvNV(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttribs1fvNV(GLbyte * pc);
extern HIDDEN void __glXDisp_VertexAttrib4NuivARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttrib4NuivARB(GLbyte * pc);
extern HIDDEN int __glXDisp_DestroyWindow(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_DestroyWindow(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_Color4sv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Color4sv(GLbyte * pc);
extern HIDDEN int __glXDisp_IsProgramNV(struct __GLXclientStateRec *, GLbyte *);
@ -531,14 +587,18 @@ extern HIDDEN int __glXDisp_DeleteQueriesARB(struct __GLXclientStateRec *, GLbyt
extern HIDDEN int __glXDispSwap_DeleteQueriesARB(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_GetMapdv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetMapdv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_DestroyGLXPixmap(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_DestroyGLXPixmap(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_SamplePatternSGIS(GLbyte * pc);
extern HIDDEN void __glXDispSwap_SamplePatternSGIS(GLbyte * pc);
extern HIDDEN int __glXDisp_PixelStoref(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_PixelStoref(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_IsQueryARB(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_IsQueryARB(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_PrioritizeTextures(GLbyte * pc);
extern HIDDEN void __glXDispSwap_PrioritizeTextures(GLbyte * pc);
extern HIDDEN int __glXDisp_PixelStorei(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_PixelStorei(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_Color4iv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Color4iv(GLbyte * pc);
extern HIDDEN void __glXDisp_EvalCoord2dv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_EvalCoord2dv(GLbyte * pc);
extern HIDDEN void __glXDisp_VertexAttrib3svARB(GLbyte * pc);
@ -563,10 +623,12 @@ extern HIDDEN void __glXDisp_TexImage1D(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexImage1D(GLbyte * pc);
extern HIDDEN void __glXDisp_FrontFace(GLbyte * pc);
extern HIDDEN void __glXDispSwap_FrontFace(GLbyte * pc);
extern HIDDEN void __glXDisp_SecondaryColor3ubvEXT(GLbyte * pc);
extern HIDDEN void __glXDispSwap_SecondaryColor3ubvEXT(GLbyte * pc);
extern HIDDEN int __glXDisp_RenderLarge(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_RenderLarge(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_VertexAttrib4dvARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttrib4dvARB(GLbyte * pc);
extern HIDDEN void __glXDisp_PolygonOffset(GLbyte * pc);
extern HIDDEN void __glXDispSwap_PolygonOffset(GLbyte * pc);
extern HIDDEN void __glXDisp_ExecuteProgramNV(GLbyte * pc);
extern HIDDEN void __glXDispSwap_ExecuteProgramNV(GLbyte * pc);
extern HIDDEN void __glXDisp_Normal3dv(GLbyte * pc);
@ -585,6 +647,8 @@ extern HIDDEN int __glXDisp_GetFramebufferAttachmentParameterivEXT(struct __GLXc
extern HIDDEN int __glXDispSwap_GetFramebufferAttachmentParameterivEXT(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_MultiTexCoord4dvARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_MultiTexCoord4dvARB(GLbyte * pc);
extern HIDDEN int __glXDisp_CreatePbuffer(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_CreatePbuffer(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_GetDoublev(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetDoublev(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_MultMatrixd(GLbyte * pc);
@ -603,6 +667,8 @@ extern HIDDEN void __glXDisp_VertexAttrib3fvARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttrib3fvARB(GLbyte * pc);
extern HIDDEN void __glXDisp_ClearColor(GLbyte * pc);
extern HIDDEN void __glXDispSwap_ClearColor(GLbyte * pc);
extern HIDDEN int __glXDisp_IsDirect(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_IsDirect(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_DeleteFramebuffersEXT(GLbyte * pc);
extern HIDDEN void __glXDispSwap_DeleteFramebuffersEXT(GLbyte * pc);
extern HIDDEN void __glXDisp_TexEnviv(GLbyte * pc);
@ -633,6 +699,8 @@ extern HIDDEN void __glXDisp_VertexAttrib3svNV(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttrib3svNV(GLbyte * pc);
extern HIDDEN int __glXDisp_GetTexEnviv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetTexEnviv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_VendorPrivateWithReply(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_VendorPrivateWithReply(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_SeparableFilter2D(GLbyte * pc);
extern HIDDEN void __glXDispSwap_SeparableFilter2D(GLbyte * pc);
extern HIDDEN void __glXDisp_Map1d(GLbyte * pc);
@ -647,6 +715,8 @@ extern HIDDEN void __glXDisp_ProgramParameters4fvNV(GLbyte * pc);
extern HIDDEN void __glXDispSwap_ProgramParameters4fvNV(GLbyte * pc);
extern HIDDEN int __glXDisp_GetProgramivNV(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetProgramivNV(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_ChangeDrawableAttributes(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_ChangeDrawableAttributes(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_GetMinmaxParameteriv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetMinmaxParameteriv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_PixelTransferf(GLbyte * pc);
@ -661,12 +731,10 @@ extern HIDDEN void __glXDisp_TexCoord1dv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexCoord1dv(GLbyte * pc);
extern HIDDEN void __glXDisp_PixelTransferi(GLbyte * pc);
extern HIDDEN void __glXDispSwap_PixelTransferi(GLbyte * pc);
extern HIDDEN int __glXDisp_GetVertexAttribdvNV(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetVertexAttribdvNV(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_SecondaryColor3ubvEXT(GLbyte * pc);
extern HIDDEN void __glXDispSwap_SecondaryColor3ubvEXT(GLbyte * pc);
extern HIDDEN void __glXDisp_VertexAttrib3fvNV(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttrib3fvNV(GLbyte * pc);
extern HIDDEN void __glXDisp_Rotatef(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Rotatef(GLbyte * pc);
extern HIDDEN void __glXDisp_Clear(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Clear(GLbyte * pc);
extern HIDDEN void __glXDisp_ReadBuffer(GLbyte * pc);
@ -681,8 +749,10 @@ extern HIDDEN void __glXDisp_ConvolutionParameterf(GLbyte * pc);
extern HIDDEN void __glXDispSwap_ConvolutionParameterf(GLbyte * pc);
extern HIDDEN int __glXDisp_GetColorTableParameteriv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetColorTableParameteriv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_ShadeModel(GLbyte * pc);
extern HIDDEN void __glXDispSwap_ShadeModel(GLbyte * pc);
extern HIDDEN int __glXDisp_ReleaseTexImageEXT(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_ReleaseTexImageEXT(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_CallList(GLbyte * pc);
extern HIDDEN void __glXDispSwap_CallList(GLbyte * pc);
extern HIDDEN void __glXDisp_VertexAttribs2fvNV(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttribs2fvNV(GLbyte * pc);
extern HIDDEN void __glXDisp_Rectiv(GLbyte * pc);
@ -697,6 +767,8 @@ extern HIDDEN void __glXDisp_BindRenderbufferEXT(GLbyte * pc);
extern HIDDEN void __glXDispSwap_BindRenderbufferEXT(GLbyte * pc);
extern HIDDEN void __glXDisp_Vertex3sv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Vertex3sv(GLbyte * pc);
extern HIDDEN int __glXDisp_BindTexImageEXT(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_BindTexImageEXT(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_ProgramLocalParameter4fvARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_ProgramLocalParameter4fvARB(GLbyte * pc);
extern HIDDEN int __glXDisp_DeleteProgramsNV(struct __GLXclientStateRec *, GLbyte *);
@ -711,6 +783,8 @@ extern HIDDEN int __glXDisp_GetProgramStringNV(struct __GLXclientStateRec *, GLb
extern HIDDEN int __glXDispSwap_GetProgramStringNV(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_LineWidth(GLbyte * pc);
extern HIDDEN void __glXDispSwap_LineWidth(GLbyte * pc);
extern HIDDEN void __glXDisp_VertexAttrib2fvARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttrib2fvARB(GLbyte * pc);
extern HIDDEN void __glXDisp_TexGendv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexGendv(GLbyte * pc);
extern HIDDEN void __glXDisp_ResetMinmax(GLbyte * pc);
@ -723,8 +797,10 @@ extern HIDDEN void __glXDisp_VertexAttribs4dvNV(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttribs4dvNV(GLbyte * pc);
extern HIDDEN int __glXDisp_GetMaterialfv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetMaterialfv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_CallList(GLbyte * pc);
extern HIDDEN void __glXDispSwap_CallList(GLbyte * pc);
extern HIDDEN int __glXDisp_UseXFont(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_UseXFont(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_ShadeModel(GLbyte * pc);
extern HIDDEN void __glXDispSwap_ShadeModel(GLbyte * pc);
extern HIDDEN void __glXDisp_Materialfv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Materialfv(GLbyte * pc);
extern HIDDEN void __glXDisp_TexCoord3fv(GLbyte * pc);
@ -735,8 +811,8 @@ extern HIDDEN void __glXDisp_MultiTexCoord1ivARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_MultiTexCoord1ivARB(GLbyte * pc);
extern HIDDEN void __glXDisp_MultiTexCoord2ivARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_MultiTexCoord2ivARB(GLbyte * pc);
extern HIDDEN void __glXDisp_CopyTexSubImage2D(GLbyte * pc);
extern HIDDEN void __glXDispSwap_CopyTexSubImage2D(GLbyte * pc);
extern HIDDEN void __glXDisp_DrawArrays(GLbyte * pc);
extern HIDDEN void __glXDispSwap_DrawArrays(GLbyte * pc);
extern HIDDEN void __glXDisp_Color3iv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Color3iv(GLbyte * pc);
extern HIDDEN int __glXDisp_GetProgramLocalParameterdvARB(struct __GLXclientStateRec *, GLbyte *);
@ -759,16 +835,18 @@ extern HIDDEN void __glXDisp_PopMatrix(GLbyte * pc);
extern HIDDEN void __glXDispSwap_PopMatrix(GLbyte * pc);
extern HIDDEN int __glXDisp_AreTexturesResidentEXT(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_AreTexturesResidentEXT(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_MakeCurrentReadSGI(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_MakeCurrentReadSGI(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_GetTexGeniv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetTexGeniv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_MakeCurrent(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_MakeCurrent(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_Map2d(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Map2d(GLbyte * pc);
extern HIDDEN void __glXDisp_Map2f(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Map2f(GLbyte * pc);
extern HIDDEN void __glXDisp_ProgramStringARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_ProgramStringARB(GLbyte * pc);
extern HIDDEN void __glXDisp_RasterPos4dv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_RasterPos4dv(GLbyte * pc);
extern HIDDEN int __glXDisp_GetCompressedTexImageARB(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetCompressedTexImageARB(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_GetTexGenfv(struct __GLXclientStateRec *, GLbyte *);
@ -799,6 +877,8 @@ extern HIDDEN void __glXDisp_Translatef(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Translatef(GLbyte * pc);
extern HIDDEN void __glXDisp_StencilMask(GLbyte * pc);
extern HIDDEN void __glXDispSwap_StencilMask(GLbyte * pc);
extern HIDDEN int __glXDisp_CreateWindow(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_CreateWindow(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_GetLightiv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetLightiv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_IsList(struct __GLXclientStateRec *, GLbyte *);
@ -813,8 +893,8 @@ extern HIDDEN void __glXDisp_CopyTexSubImage1D(GLbyte * pc);
extern HIDDEN void __glXDispSwap_CopyTexSubImage1D(GLbyte * pc);
extern HIDDEN void __glXDisp_CullFace(GLbyte * pc);
extern HIDDEN void __glXDispSwap_CullFace(GLbyte * pc);
extern HIDDEN void __glXDisp_BindTexture(GLbyte * pc);
extern HIDDEN void __glXDispSwap_BindTexture(GLbyte * pc);
extern HIDDEN int __glXDisp_QueryContextInfoEXT(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_QueryContextInfoEXT(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_VertexAttribs3svNV(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttribs3svNV(GLbyte * pc);
extern HIDDEN void __glXDisp_StencilFunc(GLbyte * pc);
@ -837,6 +917,8 @@ extern HIDDEN int __glXDisp_GetPixelMapuiv(struct __GLXclientStateRec *, GLbyte
extern HIDDEN int __glXDispSwap_GetPixelMapuiv(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_Indexfv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Indexfv(GLbyte * pc);
extern HIDDEN int __glXDisp_QueryContext(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_QueryContext(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_SecondaryColor3svEXT(GLbyte * pc);
extern HIDDEN void __glXDispSwap_SecondaryColor3svEXT(GLbyte * pc);
extern HIDDEN void __glXDisp_IndexMask(GLbyte * pc);
@ -885,8 +967,8 @@ extern HIDDEN void __glXDisp_TexCoord4dv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_TexCoord4dv(GLbyte * pc);
extern HIDDEN void __glXDisp_Begin(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Begin(GLbyte * pc);
extern HIDDEN void __glXDisp_LightModeli(GLbyte * pc);
extern HIDDEN void __glXDispSwap_LightModeli(GLbyte * pc);
extern HIDDEN int __glXDisp_ClientInfo(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_ClientInfo(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_Rectfv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Rectfv(GLbyte * pc);
extern HIDDEN void __glXDisp_LightModelf(GLbyte * pc);
@ -901,16 +983,14 @@ extern HIDDEN void __glXDisp_MultiTexCoord2fvARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_MultiTexCoord2fvARB(GLbyte * pc);
extern HIDDEN int __glXDisp_GetRenderbufferParameterivEXT(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetRenderbufferParameterivEXT(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_DrawArrays(GLbyte * pc);
extern HIDDEN void __glXDispSwap_DrawArrays(GLbyte * pc);
extern HIDDEN int __glXDisp_SelectBuffer(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_SelectBuffer(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_ColorMask(GLbyte * pc);
extern HIDDEN void __glXDispSwap_ColorMask(GLbyte * pc);
extern HIDDEN void __glXDisp_RasterPos4iv(GLbyte * pc);
extern HIDDEN void __glXDispSwap_RasterPos4iv(GLbyte * pc);
extern HIDDEN void __glXDisp_Enable(GLbyte * pc);
extern HIDDEN void __glXDispSwap_Enable(GLbyte * pc);
extern HIDDEN void __glXDisp_LineStipple(GLbyte * pc);
extern HIDDEN void __glXDispSwap_LineStipple(GLbyte * pc);
extern HIDDEN void __glXDisp_VertexAttribs4svNV(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttribs4svNV(GLbyte * pc);
extern HIDDEN int __glXDisp_GetMinmaxParameterfv(struct __GLXclientStateRec *, GLbyte *);

1517
GL/glx/indirect_table.c Normal file

File diff suppressed because it is too large Load Diff

106
GL/glx/indirect_table.h Normal file
View File

@ -0,0 +1,106 @@
/*
* (C) Copyright IBM Corporation 2005, 2006
* All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
* the rights to use, copy, modify, merge, publish, distribute, sub license,
* and/or sell copies of the Software, and to permit persons to whom the
* Software is furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice (including the next
* paragraph) shall be included in all copies or substantial portions of the
* Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL
* IBM,
* AND/OR THEIR SUPPLIERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
* OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*/
/**
* \file indirect_table.h
*
* \author Ian Romanick <idr@us.ibm.com>
*/
#ifndef INDIRECT_TABLE_H
#define INDIRECT_TABLE_H
#include <inttypes.h>
/**
*/
struct __glXDispatchInfo {
/**
* Number of significant bits in the protocol opcode. Opcodes with values
* larger than ((1 << bits) - 1) are invalid.
*/
unsigned bits;
/**
*/
const int_fast16_t * dispatch_tree;
/**
* Array of protocol decode and dispatch functions index by the opcode
* search tree (i.e., \c dispatch_tree). The first element in each pair
* is the non-byte-swapped version, and the second element is the
* byte-swapped version.
*/
const void *(*dispatch_functions)[2];
/**
* Pointer to size validation data. This table is indexed with the same
* value as ::dispatch_functions.
*
* The first element in the pair is the size, in bytes, of the fixed-size
* portion of the protocol.
*
* For opcodes that have a variable-size portion, the second value is an
* index in \c size_func_table to calculate that size. If there is no
* variable-size portion, this index will be ~0.
*
* \note
* If size checking is not to be performed on this type of protocol
* data, this pointer will be \c NULL.
*/
const int_fast16_t (*size_table)[2];
/**
* Array of functions used to calculate the variable-size portion of
* protocol messages. Indexed by the second element of the entries
* in \c ::size_table.
*
* \note
* If size checking is not to be performed on this type of protocol
* data, this pointer will be \c NULL.
*/
const gl_proto_size_func *size_func_table;
};
/**
* Sentinel value for an empty leaf in the \c dispatch_tree.
*/
#define EMPTY_LEAF INT_FAST16_MIN
/**
* Declare the index \c x as a leaf index.
*/
#define LEAF(x) -x
/**
* Determine if an index is a leaf index.
*/
#define IS_LEAF_INDEX(x) ((x) <= 0)
extern const struct __glXDispatchInfo Single_dispatch_info;
extern const struct __glXDispatchInfo Render_dispatch_info;
extern const struct __glXDispatchInfo VendorPriv_dispatch_info;
#endif /* INDIRECT_TABLE_H */

View File

@ -52,6 +52,7 @@
#include "glthread.h"
#include "dispatch.h"
#include "glxext.h"
#include "indirect_table.h"
#include "indirect_util.h"
@ -204,3 +205,114 @@ __glXSendReplySwap( ClientPtr client, const void * data, size_t elements,
WriteToClient( client, reply_ints * 4, (char *) data );
}
}
static int
get_decode_index(const struct __glXDispatchInfo *dispatch_info,
unsigned opcode)
{
int remaining_bits;
int next_remain;
const int_fast16_t * const tree = dispatch_info->dispatch_tree;
int_fast16_t index;
remaining_bits = dispatch_info->bits;
if (opcode >= (1U << remaining_bits)) {
return -1;
}
index = 0;
for (/* empty */; remaining_bits > 0; remaining_bits = next_remain) {
unsigned mask;
unsigned child_index;
/* Calculate the slice of bits used by this node.
*
* If remaining_bits = 8 and tree[index] = 3, the mask of just the
* remaining bits is 0x00ff and the mask for the remaining bits after
* this node is 0x001f. By taking 0x00ff & ~0x001f, we get 0x00e0.
* This masks the 3 bits that we would want for this node.
*/
next_remain = remaining_bits - tree[index];
mask = ((1 << remaining_bits) - 1) &
~((1 << next_remain) - 1);
/* Using the mask, calculate the index of the opcode in the node.
* With that index, fetch the index of the next node.
*/
child_index = (opcode & mask) >> next_remain;
index = tree[index + 1 + child_index];
/* If the next node is an empty leaf, the opcode is for a non-existant
* function. We're done.
*
* If the next node is a non-empty leaf, look up the function pointer
* and return it.
*/
if (index == EMPTY_LEAF) {
return -1;
}
else if (IS_LEAF_INDEX(index)) {
unsigned func_index;
/* The value stored in the tree for a leaf node is the base of
* the function pointers for that leaf node. The offset for the
* function for a particular opcode is the remaining bits in the
* opcode.
*/
func_index = -index;
func_index += opcode & ((1 << next_remain) - 1);
return func_index;
}
}
/* We should *never* get here!!!
*/
return -1;
}
void *
__glXGetProtocolDecodeFunction(const struct __glXDispatchInfo *dispatch_info,
int opcode, int swapped_version)
{
const int func_index = get_decode_index(dispatch_info, opcode);
return (func_index < 0)
? NULL
: (void *) dispatch_info->dispatch_functions[func_index][swapped_version];
}
int
__glXGetProtocolSizeData(const struct __glXDispatchInfo *dispatch_info,
int opcode, __GLXrenderSizeData *data)
{
if (dispatch_info->size_table != NULL) {
const int func_index = get_decode_index(dispatch_info, opcode);
if ((func_index >= 0)
&& (dispatch_info->size_table[func_index][0] != 0)) {
const int var_offset =
dispatch_info->size_table[func_index][1];
data->bytes = dispatch_info->size_table[func_index][0];
data->varsize = (var_offset != ~0)
? dispatch_info->size_func_table[var_offset]
: NULL;
return 0;
}
}
return -1;
}

View File

@ -40,4 +40,14 @@ extern void __glXSendReplySwap( ClientPtr client, const void * data,
size_t elements, size_t element_size, GLboolean always_array,
CARD32 retval );
struct __glXDispatchInfo;
extern void *__glXGetProtocolDecodeFunction(
const struct __glXDispatchInfo *dispatch_info, int opcode,
int swapped_version);
extern int __glXGetProtocolSizeData(
const struct __glXDispatchInfo *dispatch_info, int opcode,
__GLXrenderSizeData *data);
#endif /* __GLX_INDIRECT_UTIL_H__ */

View File

@ -323,7 +323,7 @@ int __glXTypeSize(GLenum enm)
}
}
int __glXDrawArraysSize( const GLbyte *pc, Bool swap )
int __glXDrawArraysReqSize( const GLbyte *pc, Bool swap )
{
__GLXdispatchDrawArraysHeader *hdr = (__GLXdispatchDrawArraysHeader *) pc;
__GLXdispatchDrawArraysComponentHeader *compHeader;

File diff suppressed because it is too large Load Diff

View File

@ -392,3 +392,13 @@ int __glXDisp_GetString(__GLXclientState *cl, GLbyte *pc)
{
return DoGetString(cl, pc, GL_FALSE);
}
int __glXDisp_GetProgramStringARB(__GLXclientState *cl, GLbyte *pc)
{
return BadRequest;
}
int __glXDisp_GetProgramStringNV(__GLXclientState *cl, GLbyte *pc)
{
return BadRequest;
}

View File

@ -270,3 +270,13 @@ int __glXDispSwap_GetString(__GLXclientState *cl, GLbyte *pc)
{
return DoGetString(cl, pc, GL_TRUE);
}
int __glXDispSwap_GetProgramStringARB(__GLXclientState *cl, GLbyte *pc)
{
return BadRequest;
}
int __glXDispSwap_GetProgramStringNV(__GLXclientState *cl, GLbyte *pc)
{
return BadRequest;
}

View File

@ -462,3 +462,8 @@ int __glXDisp_GetColorTable(__GLXclientState *cl, GLbyte *pc)
return Success;
}
int __glXDisp_GetCompressedTexImageARB(__GLXclientState *cl, GLbyte *pc)
{
return BadRequest;
}

View File

@ -517,3 +517,8 @@ int __glXDispSwap_GetColorTable(__GLXclientState *cl, GLbyte *pc)
return Success;
}
int __glXDispSwap_GetCompressedTexImageARB(__GLXclientState *cl, GLbyte *pc)
{
return BadRequest;
}

View File

@ -47,6 +47,7 @@
#include "glapi.h"
#include "glthread.h"
#include "dispatch.h"
#include "indirect_dispatch.h"
#include <GL/gl.h>
#include <pixmapstr.h>
#include <windowstr.h>
@ -156,7 +157,7 @@ MakeBitmapsFromFont(FontPtr pFont, int first, int count, int list_base)
/************************************************************************/
int __glXUseXFont(__GLXclientState *cl, GLbyte *pc)
int __glXDisp_UseXFont(__GLXclientState *cl, GLbyte *pc)
{
ClientPtr client = cl->client;
xGLXUseXFontReq *req;

View File

@ -468,7 +468,7 @@ symlink_mesa_shader_slang_library() {
action slang_core_gc.h
action slang_fragment_builtin_gc.h
action slang_shader_syn.h
action slang_version_syn.h
action slang_pp_version_syn.h
action slang_vertex_builtin_gc.h
}

View File

@ -458,13 +458,7 @@ XineramaCheckVirtualMotion(
if (qe)
{
sprite.hot.pScreen = qe->pScreen; /* should always be Screen 0 */
#ifdef XEVIE
xeviehot.x =
#endif
sprite.hot.x = qe->event->u.keyButtonPointer.rootX;
#ifdef XEVIE
xeviehot.y =
#endif
sprite.hot.y = qe->event->u.keyButtonPointer.rootY;
pWin = inputInfo.pointer->grab ? inputInfo.pointer->grab->confineTo :
NullWindow;
@ -501,24 +495,12 @@ XineramaCheckVirtualMotion(
lims = *REGION_EXTENTS(sprite.screen, &sprite.Reg2);
if (sprite.hot.x < lims.x1)
#ifdef XEVIE
xeviehot.x =
#endif
sprite.hot.x = lims.x1;
else if (sprite.hot.x >= lims.x2)
#ifdef XEVIE
xeviehot.x =
#endif
sprite.hot.x = lims.x2 - 1;
if (sprite.hot.y < lims.y1)
#ifdef XEVIE
xeviehot.y =
#endif
sprite.hot.y = lims.y1;
else if (sprite.hot.y >= lims.y2)
#ifdef XEVIE
xeviehot.y =
#endif
sprite.hot.y = lims.y2 - 1;
if (REGION_NUM_RECTS(&sprite.Reg2) > 1)
@ -531,6 +513,10 @@ XineramaCheckVirtualMotion(
qe->event->u.keyButtonPointer.rootY = sprite.hot.y;
}
}
#ifdef XEVIE
xeviehot.x = sprite.hot.x;
xeviehot.y = sprite.hot.y;
#endif
}
@ -548,33 +534,15 @@ XineramaCheckMotion(xEvent *xE)
panoramiXdataPtr[0].x;
XE_KBPTR.rootY += panoramiXdataPtr[sprite.screen->myNum].y -
panoramiXdataPtr[0].y;
#ifdef XEVIE
xeviehot.x =
#endif
sprite.hot.x = XE_KBPTR.rootX;
#ifdef XEVIE
xeviehot.y =
#endif
sprite.hot.y = XE_KBPTR.rootY;
if (sprite.hot.x < sprite.physLimits.x1)
#ifdef XEVIE
xeviehot.x =
#endif
sprite.hot.x = sprite.physLimits.x1;
else if (sprite.hot.x >= sprite.physLimits.x2)
#ifdef XEVIE
xeviehot.x =
#endif
sprite.hot.x = sprite.physLimits.x2 - 1;
if (sprite.hot.y < sprite.physLimits.y1)
#ifdef XEVIE
xeviehot.y =
#endif
sprite.hot.y = sprite.physLimits.y1;
else if (sprite.hot.y >= sprite.physLimits.y2)
#ifdef XEVIE
xeviehot.y =
#endif
sprite.hot.y = sprite.physLimits.y2 - 1;
if (sprite.hotShape)
@ -592,6 +560,8 @@ XineramaCheckMotion(xEvent *xE)
}
#ifdef XEVIE
xeviehot.x = sprite.hot.x;
xeviehot.y = sprite.hot.y;
xeviewin =
#endif
sprite.win = XYToWindow(sprite.hot.x, sprite.hot.y);
@ -817,13 +787,7 @@ CheckVirtualMotion(
if (qe)
{
sprite.hot.pScreen = qe->pScreen;
#ifdef XEVIE
xeviehot.x =
#endif
sprite.hot.x = qe->event->u.keyButtonPointer.rootX;
#ifdef XEVIE
xeviehot.y =
#endif
sprite.hot.y = qe->event->u.keyButtonPointer.rootY;
pWin = inputInfo.pointer->grab ? inputInfo.pointer->grab->confineTo :
NullWindow;
@ -835,31 +799,16 @@ CheckVirtualMotion(
if (sprite.hot.pScreen != pWin->drawable.pScreen)
{
sprite.hot.pScreen = pWin->drawable.pScreen;
#ifdef XEVIE
xeviehot.x = xeviehot.y = 0;
#endif
sprite.hot.x = sprite.hot.y = 0;
}
lims = *REGION_EXTENTS(pWin->drawable.pScreen, &pWin->borderSize);
if (sprite.hot.x < lims.x1)
#ifdef XEVIE
xeviehot.x =
#endif
sprite.hot.x = lims.x1;
else if (sprite.hot.x >= lims.x2)
#ifdef XEVIE
xeviehot.x =
#endif
sprite.hot.x = lims.x2 - 1;
if (sprite.hot.y < lims.y1)
#ifdef XEVIE
xeviehot.y =
#endif
sprite.hot.y = lims.y1;
else if (sprite.hot.y >= lims.y2)
#ifdef XEVIE
xeviehot.y =
#endif
sprite.hot.y = lims.y2 - 1;
#ifdef SHAPE
if (wBoundingShape(pWin))
@ -872,6 +821,10 @@ CheckVirtualMotion(
qe->event->u.keyButtonPointer.rootY = sprite.hot.y;
}
}
#ifdef XEVIE
xeviehot.x = sprite.hot.x;
xeviehot.y = sprite.hot.y;
#endif
ROOT = WindowTable[sprite.hot.pScreen->myNum];
}
@ -2053,37 +2006,23 @@ CheckMotion(xEvent *xE)
sprite.hot.pScreen = sprite.hotPhys.pScreen;
ROOT = WindowTable[sprite.hot.pScreen->myNum];
}
#ifdef XEVIE
xeviehot.x =
#endif
sprite.hot.x = XE_KBPTR.rootX;
#ifdef XEVIE
xeviehot.y =
#endif
sprite.hot.y = XE_KBPTR.rootY;
if (sprite.hot.x < sprite.physLimits.x1)
#ifdef XEVIE
xeviehot.x =
#endif
sprite.hot.x = sprite.physLimits.x1;
else if (sprite.hot.x >= sprite.physLimits.x2)
#ifdef XEVIE
xeviehot.x =
#endif
sprite.hot.x = sprite.physLimits.x2 - 1;
if (sprite.hot.y < sprite.physLimits.y1)
#ifdef XEVIE
xeviehot.y =
#endif
sprite.hot.y = sprite.physLimits.y1;
else if (sprite.hot.y >= sprite.physLimits.y2)
#ifdef XEVIE
xeviehot.y =
#endif
sprite.hot.y = sprite.physLimits.y2 - 1;
#ifdef SHAPE
if (sprite.hotShape)
ConfineToShape(sprite.hotShape, &sprite.hot.x, &sprite.hot.y);
#endif
#ifdef XEVIE
xeviehot.x = sprite.hot.x;
xeviehot.y = sprite.hot.y;
#endif
sprite.hotPhys = sprite.hot;
if ((sprite.hotPhys.x != XE_KBPTR.rootX) ||

View File

@ -143,6 +143,7 @@ FontPtr defaultFont; /* not declared in dix.h to avoid including font.h in
Bool loadableFonts = FALSE;
CursorPtr rootCursor;
Bool blackRoot=FALSE;
Bool whiteRoot=FALSE;
ClientPtr requestingClient; /* XXX this should be obsolete now, remove? */
_X_EXPORT TimeStamp currentTime;

View File

@ -343,9 +343,6 @@ MakeRootTile(WindowPtr pWin)
for (j = len; j > 0; j--)
*to++ = *from;
if (blackRoot)
bzero(back, sizeof(back));
(*pGC->ops->PutImage)((DrawablePtr)pWin->background.pixmap, pGC, 1,
0, 0, len, 4, 0, XYBitmap, (char *)back);
@ -506,6 +503,7 @@ void
InitRootWindow(WindowPtr pWin)
{
ScreenPtr pScreen = pWin->drawable.pScreen;
int backFlag = CWBorderPixel | CWCursor | CWBackingStore;
if (!(*pScreen->CreateWindow)(pWin))
return; /* XXX */
@ -514,12 +512,23 @@ InitRootWindow(WindowPtr pWin)
pWin->cursorIsNone = FALSE;
pWin->optional->cursor = rootCursor;
rootCursor->refcnt++;
MakeRootTile(pWin);
if (!blackRoot && !whiteRoot) {
MakeRootTile(pWin);
backFlag |= CWBackPixmap;
}
else {
if (blackRoot)
pWin->background.pixel = pScreen->blackPixel;
else
pWin->background.pixel = pScreen->whitePixel;
backFlag |= CWBackPixel;
}
pWin->backingStore = defaultBackingStore;
pWin->forcedBS = (defaultBackingStore != NotUseful);
/* We SHOULD check for an error value here XXX */
(*pScreen->ChangeWindowAttributes)(pWin,
CWBackPixmap|CWBorderPixel|CWCursor|CWBackingStore);
(*pScreen->ChangeWindowAttributes)(pWin, backFlag);
MapWindow(pWin, serverClient);
}

View File

@ -364,6 +364,9 @@ ddxProcessArgument(int argc, char *argv[], int i)
if (strcmp (argv[i], "-render") == 0) /* -render */
{
Render = FALSE;
#ifdef COMPOSITE
noCompositeExtension = TRUE;
#endif
return 1;
}

View File

@ -761,7 +761,8 @@ typedef enum {
FLAG_RENDER_COLORMAP_MODE,
FLAG_HANDLE_SPECIAL_KEYS,
FLAG_RANDR,
FLAG_AIGLX
FLAG_AIGLX,
FLAG_IGNORE_ABI
} FlagValues;
static OptionInfoRec FlagOptions[] = {
@ -833,6 +834,8 @@ static OptionInfoRec FlagOptions[] = {
{0}, FALSE },
{ FLAG_AIGLX, "AIGLX", OPTV_BOOLEAN,
{0}, FALSE },
{ FLAG_IGNORE_ABI, "IgnoreABI", OPTV_BOOLEAN,
{0}, FALSE },
{ -1, NULL, OPTV_NONE,
{0}, FALSE },
};
@ -891,6 +894,10 @@ configServerFlags(XF86ConfFlagsPtr flagsconf, XF86OptionPtr layoutopts)
&(xf86Info.grabInfo.allowDeactivate));
xf86GetOptValBool(FlagOptions, FLAG_ALLOW_CLOSEDOWN_GRABS,
&(xf86Info.grabInfo.allowClosedown));
xf86GetOptValBool(FlagOptions, FLAG_IGNORE_ABI, &xf86Info.ignoreABI);
if (&xf86Info.ignoreABI) {
xf86Msg(X_CONFIG, "Ignoring ABI Version\n");
}
/*
* Set things up based on the config file information. Some of these

View File

@ -87,6 +87,9 @@ static char *DFLT_MOUSE_DEV = "/dev/devi/mouse0";
#elif defined(__FreeBSD__) || defined(__FreeBSD_kernel__) || defined(__DragonFly__)
static char *DFLT_MOUSE_DEV = "/dev/sysmouse";
static char *DFLT_MOUSE_PROTO = "auto";
#elif defined(linux)
static char DFLT_MOUSE_DEV[] = "/dev/input/mice";
static char DFLT_MOUSE_PROTO[] = "auto";
#else
static char *DFLT_MOUSE_DEV = "/dev/mouse";
static char *DFLT_MOUSE_PROTO = "auto";

View File

@ -331,6 +331,10 @@ InitOutput(ScreenInfo *pScreenInfo, int argc, char **argv)
/* Tell the loader the default module search path */
LoaderSetPath(xf86ModulePath);
if (xf86Info.ignoreABI) {
LoaderSetOptions(LDR_OPT_ABI_MISMATCH_NONFATAL);
}
#ifdef TESTING
{
char **list, **l;

View File

@ -47,6 +47,22 @@
#include "xf86Priv.h"
#include "xf86DDC.h"
static void
printModeRejectMessage(int index, DisplayModePtr p, int status)
{
char *type;
if (p->type & M_T_BUILTIN)
type = "built-in ";
else if (p->type & M_T_DEFAULT)
type = "default ";
else
type = "";
xf86DrvMsg(index, X_INFO, "Not using %smode \"%s\" (%s)\n", type, p->name,
xf86ModeStatusToString(status));
}
/*
* xf86GetNearestClock --
* Find closest clock to given frequency (in kHz). This assumes the
@ -1644,18 +1660,7 @@ xf86ValidateModes(ScrnInfoPtr scrp, DisplayModePtr availModes,
q->name = xnfstrdup(p->name);
q->status = MODE_OK;
} else {
if (p->type & M_T_BUILTIN)
xf86DrvMsg(scrp->scrnIndex, X_INFO,
"Not using built-in mode \"%s\" (%s)\n",
p->name, xf86ModeStatusToString(status));
else if (p->type & M_T_DEFAULT)
xf86DrvMsg(scrp->scrnIndex, X_INFO,
"Not using default mode \"%s\" (%s)\n", p->name,
xf86ModeStatusToString(status));
else
xf86DrvMsg(scrp->scrnIndex, X_INFO,
"Not using mode \"%s\" (%s)\n", p->name,
xf86ModeStatusToString(status));
printModeRejectMessage(scrp->scrnIndex, p, status);
}
}
@ -1796,39 +1801,14 @@ xf86ValidateModes(ScrnInfoPtr scrp, DisplayModePtr availModes,
repeat = FALSE;
lookupNext:
if (repeat && ((status = p->status) != MODE_OK)) {
if (p->type & M_T_BUILTIN)
xf86DrvMsg(scrp->scrnIndex, X_INFO,
"Not using built-in mode \"%s\" (%s)\n",
p->name, xf86ModeStatusToString(status));
else if (p->type & M_T_DEFAULT)
xf86DrvMsg(scrp->scrnIndex, X_INFO,
"Not using default mode \"%s\" (%s)\n", p->name,
xf86ModeStatusToString(status));
else
xf86DrvMsg(scrp->scrnIndex, X_INFO,
"Not using mode \"%s\" (%s)\n", p->name,
xf86ModeStatusToString(status));
}
if (repeat && ((status = p->status) != MODE_OK))
printModeRejectMessage(scrp->scrnIndex, p, status);
saveType = p->type;
status = xf86LookupMode(scrp, p, clockRanges, strategy);
if (repeat && status == MODE_NOMODE) {
if (repeat && status == MODE_NOMODE)
continue;
}
if (status != MODE_OK) {
if (p->type & M_T_BUILTIN)
xf86DrvMsg(scrp->scrnIndex, X_INFO,
"Not using built-in mode \"%s\" (%s)\n",
p->name, xf86ModeStatusToString(status));
else if (p->type & M_T_DEFAULT)
xf86DrvMsg(scrp->scrnIndex, X_INFO,
"Not using default mode \"%s\" (%s)\n", p->name,
xf86ModeStatusToString(status));
else
xf86DrvMsg(scrp->scrnIndex, X_INFO,
"Not using mode \"%s\" (%s)\n", p->name,
xf86ModeStatusToString(status));
}
if (status != MODE_OK)
printModeRejectMessage(scrp->scrnIndex, p, status);
if (status == MODE_ERROR) {
ErrorF("xf86ValidateModes: "
"unexpected result from xf86LookupMode()\n");
@ -2023,20 +2003,6 @@ xf86PruneDriverModes(ScrnInfoPtr scrp)
return;
n = p->next;
if (p->status != MODE_OK) {
#if 0
if (p->type & M_T_BUILTIN)
xf86DrvMsg(scrp->scrnIndex, X_INFO,
"Not using built-in mode \"%s\" (%s)\n", p->name,
xf86ModeStatusToString(p->status));
else if (p->type & M_T_DEFAULT)
xf86DrvMsg(scrp->scrnIndex, X_INFO,
"Not using default mode \"%s\" (%s)\n", p->name,
xf86ModeStatusToString(p->status));
else
xf86DrvMsg(scrp->scrnIndex, X_INFO,
"Not using mode \"%s\" (%s)\n", p->name,
xf86ModeStatusToString(p->status));
#endif
xf86DeleteMode(&(scrp->modes), p);
}
p = n;

View File

@ -166,6 +166,7 @@ typedef struct {
MessageType randRFrom;
Bool aiglx;
MessageType aiglxFrom;
Bool ignoreABI;
struct {
Bool disabled; /* enable/disable deactivating
* grabs or closing the

View File

@ -605,6 +605,10 @@ the builtin handler will be used.
.TP 7
.BI "Option \*qAIGLX\*q \*q" boolean \*q
enable or disable AIGLX. AIGLX is enabled by default.
.TP 7
.BI "Option \*qIgnoreABI\*q \*q" boolean \*q
Allow modules built for a different, potentially incompatible version of
the X server to load. Disabled by default.
.SH MODULE SECTION
The
.B Module

View File

@ -58,6 +58,13 @@ void ddxInitGlobals(void)
int
ddxProcessArgument (int argc, char *argv[], int i)
{
#ifdef COMPOSITE
/* XXX terrible hack */
extern Bool noCompositeExtension;
noCompositeExtension = TRUE;
#endif
if (!strcmp(argv[i], "-display")) {
if (++i < argc) {
xnestDisplayName = argv[i];

View File

@ -56,6 +56,8 @@ extern void *g_pClipboardDisplay;
extern Window g_iClipboardWindow;
extern Atom g_atomLastOwnedSelection;
/* BPS - g_hwndClipboard needed for X app->Windows paste fix */
extern HWND g_hwndClipboard;
/*
* Local function prototypes
@ -141,6 +143,12 @@ winProcessXEventsTimeout (HWND hwnd, int iWindow, Display *pDisplay,
* Process a given Windows message
*/
/* BPS - Define our own message, which we'll post to ourselves to facilitate
* resetting the delayed rendering mechanism after each paste from X app to
* Windows app. TODO - Perhaps move to win.h with the other WM_USER messages.
*/
#define WM_USER_PASTE_COMPLETE (WM_USER + 1003)
LRESULT CALLBACK
winClipboardWindowProc (HWND hwnd, UINT message,
WPARAM wParam, LPARAM lParam)
@ -167,16 +175,19 @@ winClipboardWindowProc (HWND hwnd, UINT message,
case WM_CREATE:
{
HWND first, next;
DWORD error_code = 0;
winDebug ("winClipboardWindowProc - WM_CREATE\n");
first = GetClipboardViewer(); /* Get handle to first viewer in chain. */
if (first == hwnd) return 0; /* Make sure it's not us! */
/* Add ourselves to the clipboard viewer chain */
s_hwndNextViewer = SetClipboardViewer (hwnd);
if (s_hwndNextViewer == hwnd)
{
s_hwndNextViewer = NULL;
winErrorFVerb (1, "winClipboardWindowProc - WM_CREATE: "
"attempted to set next window to ourselves.");
}
next = SetClipboardViewer (hwnd);
error_code = GetLastError();
if (SUCCEEDED(error_code) && (next == first)) /* SetClipboardViewer must have succeeded, and the handle */
s_hwndNextViewer = next; /* it returned must have been the first window in the chain */
else
s_fCBCInitialized = FALSE;
}
return 0;
@ -220,28 +231,27 @@ winClipboardWindowProc (HWND hwnd, UINT message,
* expensive than just putting ourselves back into the chain.
*/
HWND first, next;
DWORD error_code = 0;
winDebug ("winClipboardWindowProc - WM_WM_REINIT: Enter\n");
if (hwnd != GetClipboardViewer ())
{
winDebug (" WM_WM_REINIT: Replacing us(%x) with %x at head "
"of chain\n", hwnd, s_hwndNextViewer);
s_fCBCInitialized = FALSE;
ChangeClipboardChain (hwnd, s_hwndNextViewer);
s_hwndNextViewer = NULL;
s_fCBCInitialized = FALSE;
winDebug (" WM_WM_REINIT: Putting us back at head of chain.\n");
s_hwndNextViewer = SetClipboardViewer (hwnd);
if (s_hwndNextViewer == hwnd)
{
s_hwndNextViewer = NULL;
winErrorFVerb (1, "winClipboardWindowProc - WM_WM_REINIT: "
"attempted to set next window to ourselves.\n");
}
}
first = GetClipboardViewer(); /* Get handle to first viewer in chain. */
if (first == hwnd) return 0; /* Make sure it's not us! */
winDebug (" WM_WM_REINIT: Replacing us(%x) with %x at head "
"of chain\n", hwnd, s_hwndNextViewer);
s_fCBCInitialized = FALSE;
ChangeClipboardChain (hwnd, s_hwndNextViewer);
s_hwndNextViewer = NULL;
s_fCBCInitialized = FALSE;
winDebug (" WM_WM_REINIT: Putting us back at head of chain.\n");
first = GetClipboardViewer(); /* Get handle to first viewer in chain. */
if (first == hwnd) return 0; /* Make sure it's not us! */
next = SetClipboardViewer (hwnd);
error_code = GetLastError();
if (SUCCEEDED(error_code) && (next == first)) /* SetClipboardViewer must have succeeded, and the handle */
s_hwndNextViewer = next; /* it returned must have been the first window in the chain */
else
{
winDebug (" WM_WM_REINIT: already at head of viewer chain.\n");
}
s_fCBCInitialized = FALSE;
}
winDebug ("winClipboardWindowProc - WM_WM_REINIT: Exit\n");
return 0;
@ -325,8 +335,6 @@ winClipboardWindowProc (HWND hwnd, UINT message,
* previous XSetSelectionOwner messages.
*/
XSync (pDisplay, FALSE);
winDebug("winClipboardWindowProc - XSync done.\n");
/* Release PRIMARY selection if owned */
iReturn = XGetSelectionOwner (pDisplay, XA_PRIMARY);
@ -525,6 +533,13 @@ winClipboardWindowProc (HWND hwnd, UINT message,
SetClipboardData (CF_TEXT, NULL);
}
/* BPS - Post ourselves a user message whose handler will reset the
* delayed rendering mechanism after the paste is complete. This is
* necessary because calling SetClipboardData() with a NULL argument
* here will cause the data we just put on the clipboard to be lost!
*/
PostMessage(g_hwndClipboard, WM_USER_PASTE_COMPLETE, 0, 0);
/* Special handling for WM_RENDERALLFORMATS */
if (message == WM_RENDERALLFORMATS)
{
@ -542,6 +557,37 @@ winClipboardWindowProc (HWND hwnd, UINT message,
winDebug ("winClipboardWindowProc - WM_RENDER*FORMAT - Returning.\n");
return 0;
}
/* BPS - This WM_USER message is posted by us. It gives us the opportunity
* to reset the delayed rendering mechanism after each and every paste
* from an X app to a Windows app. Without such a mechanism, subsequent
* changes of selection in the X app owning the selection are not
* reflected in pastes into Windows apps, since Windows won't send us the
* WM_RENDERFORMAT message unless someone has set changed data (or NULL)
* on the clipboard. */
case WM_USER_PASTE_COMPLETE:
{
if (hwnd != GetClipboardOwner ())
/* In case we've lost the selection since posting the message */
return 0;
winDebug ("winClipboardWindowProc - WM_USER_PASTE_COMPLETE\n");
/* Set up for another delayed rendering callback */
OpenClipboard (g_hwndClipboard);
/* Take ownership of the Windows clipboard */
EmptyClipboard ();
/* Advertise Unicode if we support it */
if (g_fUnicodeSupport)
SetClipboardData (CF_UNICODETEXT, NULL);
/* Always advertise regular text */
SetClipboardData (CF_TEXT, NULL);
/* Release the clipboard */
CloseClipboard ();
}
return 0;
}
/* Let Windows perform default processing for unhandled messages */

View File

@ -304,7 +304,6 @@ winTopLevelWindowProc (HWND hwnd, UINT message,
winScreenInfo *s_pScreenInfo = NULL;
HWND hwndScreen = NULL;
DrawablePtr pDraw = NULL;
int iX, iY, iWidth, iHeight, iBorder;
winWMMessageRec wmMsg;
Bool fWMMsgInitialized = FALSE;
static Bool s_fTracking = FALSE;
@ -394,6 +393,15 @@ winTopLevelWindowProc (HWND hwnd, UINT message,
* currently being created.
*/
winReorderWindowsMultiWindow ();
/* Fix a 'round title bar corner background should be transparent not black' problem when first painted */
RECT rWindow;
HRGN hRgnWindow;
GetWindowRect(hwnd, &rWindow);
hRgnWindow = CreateRectRgnIndirect(&rWindow);
SetWindowRgn (hwnd, hRgnWindow, TRUE);
DeleteObject(hRgnWindow);
return 0;
case WM_INIT_SYS_MENU:
@ -433,20 +441,19 @@ winTopLevelWindowProc (HWND hwnd, UINT message,
/* BeginPaint gives us an hdc that clips to the invalidated region */
hdcUpdate = BeginPaint (hwnd, &ps);
/* Get the position and dimensions of the window */
iBorder = wBorderWidth (pWin);
iX = pWin->drawable.x;
iY = pWin->drawable.y;
iWidth = pWin->drawable.width;
iHeight = pWin->drawable.height;
/* Avoid the BitBlt's if the PAINTSTRUCT is bogus */
if (ps.rcPaint.right==0 && ps.rcPaint.bottom==0 && ps.rcPaint.left==0 && ps.rcPaint.top==0)
{
EndPaint (hwndScreen, &ps);
return 0;
}
/* Try to copy from the shadow buffer */
if (!BitBlt (hdcUpdate,
0, 0,
iWidth, iHeight,
ps.rcPaint.left, ps.rcPaint.top,
ps.rcPaint.right - ps.rcPaint.left, ps.rcPaint.bottom - ps.rcPaint.top,
s_pScreenPriv->hdcShadow,
iX, iY,
ps.rcPaint.left + pWin->drawable.x, ps.rcPaint.top + pWin->drawable.y,
SRCCOPY))
{
LPVOID lpMsgBuf;

View File

@ -540,8 +540,9 @@ winShadowUpdateGDI (ScreenPtr pScreen,
* handle large regions by creating a clipping region and
* doing a single blit constrained to that clipping region.
*/
if (pScreenInfo->dwClipUpdatesNBoxes == 0
|| dwBox < pScreenInfo->dwClipUpdatesNBoxes)
if (!pScreenInfo->fMultiWindow &&
(pScreenInfo->dwClipUpdatesNBoxes == 0 ||
dwBox < pScreenInfo->dwClipUpdatesNBoxes))
{
/* Loop through all boxes in the damaged region */
while (dwBox--)
@ -566,7 +567,7 @@ winShadowUpdateGDI (ScreenPtr pScreen,
++pBox;
}
}
else
else if (!pScreenInfo->fMultiWindow)
{
/* Compute a GDI region from the damaged region */
hrgnCombined = CreateRectRgn (pBox->x1, pBox->y1, pBox->x2, pBox->y2);

View File

@ -222,6 +222,9 @@
/* Support IPv6 for TCP connections */
#undef IPv6
/* Support os-specific local connections */
#undef LOCALCONN
/* Support MIT Misc extension */
#undef MITMISC

View File

@ -73,6 +73,7 @@ extern int limitNoFile;
extern Bool defeatAccessControl;
extern long maxBigRequestSize;
extern Bool blackRoot;
extern Bool whiteRoot;
extern Bool CoreDump;

View File

@ -1188,7 +1188,11 @@ ResetHosts (char *display)
FreeHost (host);
}
#if defined WIN32 && defined __MINGW32__
#define ETC_HOST_PREFIX "X"
#else
#define ETC_HOST_PREFIX "/etc/X"
#endif
#define ETC_HOST_SUFFIX ".hosts"
fnamelen = strlen(ETC_HOST_PREFIX) + strlen(ETC_HOST_SUFFIX) +
strlen(display) + 1;

View File

@ -642,6 +642,7 @@ void UseMsg(void)
ErrorF("v video blanking for screen-saver\n");
ErrorF("-v screen-saver without video blanking\n");
ErrorF("-wm WhenMapped default backing-store\n");
ErrorF("-wr create root window with white background\n");
ErrorF("-x string loads named extension at init time \n");
ErrorF("-maxbigreqsize set maximal bigrequest size \n");
#ifdef PANORAMIX
@ -983,6 +984,8 @@ ProcessCommandLine(int argc, char *argv[])
defaultScreenSaverBlanking = DontPreferBlanking;
else if ( strcmp( argv[i], "-wm") == 0)
defaultBackingStore = WhenMapped;
else if ( strcmp( argv[i], "-wr") == 0)
whiteRoot = TRUE;
else if ( strcmp( argv[i], "-maxbigreqsize") == 0) {
if(++i < argc) {
long reqSizeArg = atol(argv[i]);