summaryrefslogtreecommitdiff
path: root/xserver/hw/dmx
diff options
context:
space:
mode:
authorMatthieu Herrb <matthieu@cvs.openbsd.org>2015-11-07 16:48:54 +0000
committerMatthieu Herrb <matthieu@cvs.openbsd.org>2015-11-07 16:48:54 +0000
commit6c07b8ab53c2bbf0feb0afbbe98b33171c7b7872 (patch)
tree35eb85f0db40ffe6e6614d780b3de61b93edb3bc /xserver/hw/dmx
parentf4e01ac5608a8dfd9a4ee2f7aa43d28cc1710d81 (diff)
Update to xserver 1.17.4.
tested by naddy@
Diffstat (limited to 'xserver/hw/dmx')
-rw-r--r--xserver/hw/dmx/config/dmxparse.h3
-rw-r--r--xserver/hw/dmx/config/dmxprint.c20
-rw-r--r--xserver/hw/dmx/dmx.c1
-rw-r--r--xserver/hw/dmx/dmxcb.c3
-rw-r--r--xserver/hw/dmx/dmxfont.h2
-rw-r--r--xserver/hw/dmx/dmxgc.c4
-rw-r--r--xserver/hw/dmx/dmxgc.h4
-rw-r--r--xserver/hw/dmx/dmxinit.c42
-rw-r--r--xserver/hw/dmx/dmxpict.c1
-rw-r--r--xserver/hw/dmx/dmxprop.c6
-rw-r--r--xserver/hw/dmx/dmxscrinit.c1
-rw-r--r--xserver/hw/dmx/dmxwindow.c4
-rw-r--r--xserver/hw/dmx/glxProxy/compsize.h7
-rw-r--r--xserver/hw/dmx/glxProxy/g_disptab.h21
-rw-r--r--xserver/hw/dmx/glxProxy/glxcmds.c7
-rw-r--r--xserver/hw/dmx/glxProxy/glxcmds.h6
-rw-r--r--xserver/hw/dmx/glxProxy/glxcmdsswap.c4
-rw-r--r--xserver/hw/dmx/glxProxy/glxext.h1
-rw-r--r--xserver/hw/dmx/glxProxy/glxscreens.c6
-rw-r--r--xserver/hw/dmx/glxProxy/glxscreens.h2
-rw-r--r--xserver/hw/dmx/glxProxy/glxserver.h8
-rw-r--r--xserver/hw/dmx/glxProxy/glxsingle.c6
-rw-r--r--xserver/hw/dmx/glxProxy/glxsingle.h4
-rw-r--r--xserver/hw/dmx/glxProxy/glxswap.c4
-rw-r--r--xserver/hw/dmx/glxProxy/glxvendor.c6
-rw-r--r--xserver/hw/dmx/input/dmxinputinit.c10
26 files changed, 88 insertions, 95 deletions
diff --git a/xserver/hw/dmx/config/dmxparse.h b/xserver/hw/dmx/config/dmxparse.h
index 7d31b6309..cc2f0eb71 100644
--- a/xserver/hw/dmx/config/dmxparse.h
+++ b/xserver/hw/dmx/config/dmxparse.h
@@ -38,6 +38,7 @@
#define _DMXPARSE_H_
#include <stdio.h> /* For FILE */
+#include <X11/Xfuncproto.h> /* For _X_ATTRIBUTE_PRINTF */
/** Stores tokens not stored in other structures (e.g., keywords and ;) */
typedef struct _DMXConfigToken {
@@ -203,7 +204,7 @@ extern int yylex(void);
extern int yydebug;
extern void yyerror(const char *message);
-extern void dmxConfigLog(const char *format, ...);
+extern void dmxConfigLog(const char *format, ...) _X_ATTRIBUTE_PRINTF(1,0);
extern void *dmxConfigAlloc(unsigned long bytes);
extern void *dmxConfigRealloc(void *orig,
unsigned long orig_bytes, unsigned long bytes);
diff --git a/xserver/hw/dmx/config/dmxprint.c b/xserver/hw/dmx/config/dmxprint.c
index 9dec52b5c..c80e830e4 100644
--- a/xserver/hw/dmx/config/dmxprint.c
+++ b/xserver/hw/dmx/config/dmxprint.c
@@ -130,7 +130,7 @@ dmxConfigPopState(void)
dmxConfigNewline();
}
-static void
+static void _X_ATTRIBUTE_PRINTF(4, 5)
dmxConfigOutput(int addSpace, int doNewline, const char *comment,
const char *format, ...)
{
@@ -261,32 +261,20 @@ dmxConfigPrintString(DMXConfigStringPtr p, int quote)
static int
dmxConfigPrintPair(DMXConfigPairPtr p, int addSpace)
{
- const char *format = NULL;
-
if (!p)
return 0;
- switch (p->token) {
- case T_ORIGIN:
- format = "@%dx%d";
- break;
- case T_DIMENSION:
- format = "%dx%d";
- break;
- case T_OFFSET:
- format = "%c%d%c%d";
- break;
- }
if (p->token == T_OFFSET) {
if (!p->comment && !p->x && !p->y && p->xsign >= 0 && p->ysign >= 0)
return 0;
- dmxConfigOutput(addSpace, 0, p->comment, format,
+ dmxConfigOutput(addSpace, 0, p->comment, "%c%d%c%d",
p->xsign < 0 ? '-' : '+', p->x,
p->ysign < 0 ? '-' : '+', p->y);
}
else {
if (!p->comment && !p->x && !p->y)
return 0;
- dmxConfigOutput(addSpace, 0, p->comment, format, p->x, p->y);
+ dmxConfigOutput(addSpace, 0, p->comment, "%s%dx%d",
+ (p->token == T_ORIGIN) ? "@" : "", p->x, p->y);
}
return 1;
}
diff --git a/xserver/hw/dmx/dmx.c b/xserver/hw/dmx/dmx.c
index 99e970cb9..2988df33a 100644
--- a/xserver/hw/dmx/dmx.c
+++ b/xserver/hw/dmx/dmx.c
@@ -55,6 +55,7 @@
#include "extinit.h"
#include "opaque.h"
+#include "dmx.h"
#include "dmxextension.h"
#include <X11/extensions/dmxproto.h>
#include <X11/extensions/dmx.h>
diff --git a/xserver/hw/dmx/dmxcb.c b/xserver/hw/dmx/dmxcb.c
index 86015f395..cca5702ee 100644
--- a/xserver/hw/dmx/dmxcb.c
+++ b/xserver/hw/dmx/dmxcb.c
@@ -47,9 +47,6 @@ extern int connBlockScreenStart;
#ifdef PANORAMIX
#include "panoramiXsrv.h"
-extern int PanoramiXPixWidth;
-extern int PanoramiXPixHeight;
-extern int PanoramiXNumScreens;
#endif
int dmxGlobalWidth, dmxGlobalHeight;
diff --git a/xserver/hw/dmx/dmxfont.h b/xserver/hw/dmx/dmxfont.h
index 8575ca953..66c663377 100644
--- a/xserver/hw/dmx/dmxfont.h
+++ b/xserver/hw/dmx/dmxfont.h
@@ -54,6 +54,4 @@ extern Bool dmxUnrealizeFont(ScreenPtr pScreen, FontPtr pFont);
extern Bool dmxBELoadFont(ScreenPtr pScreen, FontPtr pFont);
extern Bool dmxBEFreeFont(ScreenPtr pScreen, FontPtr pFont);
-extern int dmxFontPrivateIndex;
-
#endif /* DMXFONT_H */
diff --git a/xserver/hw/dmx/dmxgc.c b/xserver/hw/dmx/dmxgc.c
index 234316797..ec15d27aa 100644
--- a/xserver/hw/dmx/dmxgc.c
+++ b/xserver/hw/dmx/dmxgc.c
@@ -49,7 +49,7 @@
#include "pixmapstr.h"
#include "migc.h"
-static GCFuncs dmxGCFuncs = {
+static const GCFuncs dmxGCFuncs = {
dmxValidateGC,
dmxChangeGC,
dmxCopyGC,
@@ -59,7 +59,7 @@ static GCFuncs dmxGCFuncs = {
dmxCopyClip,
};
-static GCOps dmxGCOps = {
+static const GCOps dmxGCOps = {
dmxFillSpans,
dmxSetSpans,
dmxPutImage,
diff --git a/xserver/hw/dmx/dmxgc.h b/xserver/hw/dmx/dmxgc.h
index c8ecb53a0..c5c6b7732 100644
--- a/xserver/hw/dmx/dmxgc.h
+++ b/xserver/hw/dmx/dmxgc.h
@@ -41,8 +41,8 @@
/** GC private area. */
typedef struct _dmxGCPriv {
- GCOps *ops;
- GCFuncs *funcs;
+ const GCOps *ops;
+ const GCFuncs *funcs;
XlibGC gc;
Bool msc;
} dmxGCPrivRec, *dmxGCPrivPtr;
diff --git a/xserver/hw/dmx/dmxinit.c b/xserver/hw/dmx/dmxinit.c
index fd2ade0ef..025dc8637 100644
--- a/xserver/hw/dmx/dmxinit.c
+++ b/xserver/hw/dmx/dmxinit.c
@@ -164,23 +164,23 @@ dmxErrorHandler(Display * dpy, XErrorEvent * ev)
switch (ev->error_code) {
case BadValue:
dmxLog(dmxWarning, " Value: 0x%x\n",
- ev->resourceid);
+ (unsigned int) ev->resourceid);
break;
case BadAtom:
dmxLog(dmxWarning, " AtomID: 0x%x\n",
- ev->resourceid);
+ (unsigned int) ev->resourceid);
break;
default:
dmxLog(dmxWarning, " ResourceID: 0x%x\n",
- ev->resourceid);
+ (unsigned int) ev->resourceid);
break;
}
/* Provide serial number information */
dmxLog(dmxWarning, " Failed serial number: %d\n",
- ev->serial);
+ (unsigned int) ev->serial);
dmxLog(dmxWarning, " Current serial number: %d\n",
- dpy->request);
+ (unsigned int) dpy->request);
return 0;
}
@@ -634,7 +634,7 @@ InitOutput(ScreenInfo * pScreenInfo, int argc, char *argv[])
if (major > 0 && minor > 0)
year += 2000;
- dmxLog(dmxInfo, "Generation: %d\n", dmxGeneration);
+ dmxLog(dmxInfo, "Generation: %lu\n", dmxGeneration);
dmxLog(dmxInfo, "DMX version: %d.%d.%02d%02d%02d (%s)\n",
major, minor, year, month, day, VENDOR_STRING);
@@ -762,7 +762,6 @@ InitOutput(ScreenInfo * pScreenInfo, int argc, char *argv[])
dmxGlxVisualPrivate **configprivs = NULL;
int nconfigs = 0;
int (*oldErrorHandler) (Display *, XErrorEvent *);
- int i;
/* Catch errors if when using an older GLX w/o FBconfigs */
oldErrorHandler = XSetErrorHandler(dmxNOPErrorHandler);
@@ -797,28 +796,29 @@ InitOutput(ScreenInfo * pScreenInfo, int argc, char *argv[])
configprivs = malloc(nconfigs * sizeof(dmxGlxVisualPrivate *));
if (configs != NULL && configprivs != NULL) {
+ int j;
/* Initialize our private info for each visual
* (currently only x_visual_depth and x_visual_class)
*/
- for (i = 0; i < nconfigs; i++) {
+ for (j = 0; j < nconfigs; j++) {
- configprivs[i] = (dmxGlxVisualPrivate *)
+ configprivs[j] = (dmxGlxVisualPrivate *)
malloc(sizeof(dmxGlxVisualPrivate));
- configprivs[i]->x_visual_depth = 0;
- configprivs[i]->x_visual_class = 0;
+ configprivs[j]->x_visual_depth = 0;
+ configprivs[j]->x_visual_class = 0;
/* Find the visual depth */
- if (configs[i].vid > 0) {
- int j;
-
- for (j = 0; j < dmxScreen->beNumVisuals; j++) {
- if (dmxScreen->beVisuals[j].visualid ==
- configs[i].vid) {
- configprivs[i]->x_visual_depth =
- dmxScreen->beVisuals[j].depth;
- configprivs[i]->x_visual_class =
- dmxScreen->beVisuals[j].class;
+ if (configs[j].vid > 0) {
+ int k;
+
+ for (k = 0; k < dmxScreen->beNumVisuals; k++) {
+ if (dmxScreen->beVisuals[k].visualid ==
+ configs[j].vid) {
+ configprivs[j]->x_visual_depth =
+ dmxScreen->beVisuals[k].depth;
+ configprivs[j]->x_visual_class =
+ dmxScreen->beVisuals[k].class;
break;
}
}
diff --git a/xserver/hw/dmx/dmxpict.c b/xserver/hw/dmx/dmxpict.c
index 64d0ae150..aaca178b9 100644
--- a/xserver/hw/dmx/dmxpict.c
+++ b/xserver/hw/dmx/dmxpict.c
@@ -57,7 +57,6 @@
#include "mipict.h"
#include "fbpict.h"
-extern int RenderErrBase;
extern int (*ProcRenderVector[RenderNumberRequests]) (ClientPtr);
static int (*dmxSaveRenderVector[RenderNumberRequests]) (ClientPtr);
diff --git a/xserver/hw/dmx/dmxprop.c b/xserver/hw/dmx/dmxprop.c
index 4be2dbd4c..5e306d286 100644
--- a/xserver/hw/dmx/dmxprop.c
+++ b/xserver/hw/dmx/dmxprop.c
@@ -220,7 +220,7 @@ dmxPropertyCheckOtherWindows(DMXScreenInfo * dmxScreen, Atom atom)
if (XGetTextProperty(dpy, win, &tp, atom) && tp.nitems) {
dmxLog(dmxDebug, "On %s/%lu: %s\n",
- dmxScreen->name, win, tp.value);
+ dmxScreen->name, (unsigned long) win, tp.value);
if (!strncmp((char *) tp.value, (char *) id,
strlen((char *) id))) {
int idx;
@@ -360,8 +360,8 @@ dmxPropertyWindow(DMXScreenInfo * dmxScreen)
dmxScreen->next = (other->next ? other->next : other);
other->next = (tmp ? tmp : dmxScreen);
dmxLog(dmxDebug, "%d/%s/%lu and %d/%s/%lu are on the same backend\n",
- dmxScreen->index, dmxScreen->name, dmxScreen->scrnWin,
- other->index, other->name, other->scrnWin);
+ dmxScreen->index, dmxScreen->name, (unsigned long) dmxScreen->scrnWin,
+ other->index, other->name, (unsigned long) other->scrnWin);
}
snprintf(buf, sizeof(buf), ".%d,%lu", dmxScreen->index,
diff --git a/xserver/hw/dmx/dmxscrinit.c b/xserver/hw/dmx/dmxscrinit.c
index 963d3a9de..097418d05 100644
--- a/xserver/hw/dmx/dmxscrinit.c
+++ b/xserver/hw/dmx/dmxscrinit.c
@@ -80,7 +80,6 @@ dmxBEScreenInit(ScreenPtr pScreen)
{
DMXScreenInfo *dmxScreen = &dmxScreens[pScreen->myNum];
XSetWindowAttributes attribs;
- XGCValues gcvals;
unsigned long mask;
int i, j;
diff --git a/xserver/hw/dmx/dmxwindow.c b/xserver/hw/dmx/dmxwindow.c
index c75373534..c157e1099 100644
--- a/xserver/hw/dmx/dmxwindow.c
+++ b/xserver/hw/dmx/dmxwindow.c
@@ -857,13 +857,9 @@ dmxResizeWindow(WindowPtr pWindow, int x, int y,
ScreenPtr pScreen = pWindow->drawable.pScreen;
DMXScreenInfo *dmxScreen = &dmxScreens[pScreen->myNum];
dmxWinPrivPtr pWinPriv = DMX_GET_WINDOW_PRIV(pWindow);
- dmxWinPrivPtr pSibPriv;
unsigned int m;
XWindowChanges c;
- if (pSib)
- pSibPriv = DMX_GET_WINDOW_PRIV(pSib);
-
DMX_UNWRAP(ResizeWindow, dmxScreen, pScreen);
#if 1
if (pScreen->ResizeWindow)
diff --git a/xserver/hw/dmx/glxProxy/compsize.h b/xserver/hw/dmx/glxProxy/compsize.h
index 360966233..5e759b0a0 100644
--- a/xserver/hw/dmx/glxProxy/compsize.h
+++ b/xserver/hw/dmx/glxProxy/compsize.h
@@ -48,4 +48,11 @@ extern GLint __glTexGeniv_size(GLenum e);
extern GLint __glTexParameterfv_size(GLenum e);
extern GLint __glTexParameteriv_size(GLenum e);
+extern GLint __glCallLists_size(GLsizei n, GLenum type);
+extern GLint __glDrawPixels_size(GLenum format, GLenum type, GLsizei w, GLsizei h);
+extern GLint __glBitmap_size(GLsizei w, GLsizei h);
+extern GLint __glTexImage1D_size(GLenum format, GLenum type, GLsizei w);
+extern GLint __glTexImage2D_size(GLenum format, GLenum type, GLsizei w, GLsizei h);
+extern GLint __glTexImage3D_size(GLenum format, GLenum type, GLsizei w, GLsizei h, GLsizei d);
+
#endif /* !__compsize_h__ */
diff --git a/xserver/hw/dmx/glxProxy/g_disptab.h b/xserver/hw/dmx/glxProxy/g_disptab.h
index 530338798..783f87a54 100644
--- a/xserver/hw/dmx/glxProxy/g_disptab.h
+++ b/xserver/hw/dmx/glxProxy/g_disptab.h
@@ -655,7 +655,6 @@ extern void __glXDispSwap_CopyConvolutionFilter2D(GLbyte *);
extern void __glXDispSwap_SeparableFilter2D(GLbyte *);
extern void __glXDispSwap_TexImage3D(GLbyte *);
extern void __glXDispSwap_TexSubImage3D(GLbyte *);
-extern void __glXDispSwap_DrawArrays(GLbyte *);
extern void __glXDispSwap_PrioritizeTextures(GLbyte *);
extern void __glXDispSwap_CopyTexImage1D(GLbyte *);
extern void __glXDispSwap_CopyTexImage2D(GLbyte *);
@@ -663,6 +662,26 @@ extern void __glXDispSwap_CopyTexSubImage1D(GLbyte *);
extern void __glXDispSwap_CopyTexSubImage2D(GLbyte *);
extern void __glXDispSwap_CopyTexSubImage3D(GLbyte *);
+extern void __glXDispSwap_BindTexture(GLbyte *);
+extern void __glXDispSwap_BlendColor(GLbyte *);
+extern void __glXDispSwap_BlendEquation(GLbyte *);
+extern void __glXDispSwap_ColorTable(GLbyte *);
+extern void __glXDispSwap_ColorTableParameterfv(GLbyte *);
+extern void __glXDispSwap_ColorTableParameteriv(GLbyte *);
+extern void __glXDispSwap_CopyColorTable(GLbyte *);
+extern void __glXDispSwap_ConvolutionParameterf(GLbyte *);
+extern void __glXDispSwap_ConvolutionParameteri(GLbyte *);
+extern void __glXDispSwap_Histogram(GLbyte *);
+extern void __glXDispSwap_Minmax(GLbyte *);
+extern void __glXDispSwap_ResetHistogram(GLbyte *);
+extern void __glXDispSwap_ResetMinmax(GLbyte *);
+
+extern int __glXSwapCreateContextWithConfigSGIX(__GLXclientState *, GLbyte *);
+extern int __glXSwapBindSwapBarrierSGIX(__GLXclientState *, GLbyte *);
+extern int __glXSwapJoinSwapGroupSGIX(__GLXclientState *, GLbyte *);
+extern int __glXSwapQueryMaxSwapBarriersSGIX(__GLXclientState *, GLbyte *);
+extern int __glXSwapMakeCurrentReadSGI(__GLXclientState *, GLbyte *);
+
#define __GLX_MIN_GLXCMD_OPCODE 1
#define __GLX_MAX_GLXCMD_OPCODE 20
#define __GLX_MIN_RENDER_OPCODE 1
diff --git a/xserver/hw/dmx/glxProxy/glxcmds.c b/xserver/hw/dmx/glxProxy/glxcmds.c
index fb4d5acce..4c500c93d 100644
--- a/xserver/hw/dmx/glxProxy/glxcmds.c
+++ b/xserver/hw/dmx/glxProxy/glxcmds.c
@@ -61,7 +61,6 @@
extern __GLXFBConfig **__glXFBConfigs;
extern int __glXNumFBConfigs;
-extern int glxIsExtensionSupported(char *ext);
extern int __glXGetFBConfigsSGIX(__GLXclientState * cl, GLbyte * pc);
#define BE_TO_CLIENT_ERROR(x) \
@@ -3394,11 +3393,11 @@ __glXCreatePbuffer(__GLXclientState * cl, GLbyte * pc)
/* Send attributes */
if (attr != NULL) {
- CARD32 *pc = (CARD32 *) (be_req + 1);
+ CARD32 *pca = (CARD32 *) (be_req + 1);
while (numAttribs-- > 0) {
- *pc++ = *attr++; /* token */
- *pc++ = *attr++; /* value */
+ *pca++ = *attr++; /* token */
+ *pca++ = *attr++; /* value */
}
}
diff --git a/xserver/hw/dmx/glxProxy/glxcmds.h b/xserver/hw/dmx/glxProxy/glxcmds.h
index b0745927e..689e33485 100644
--- a/xserver/hw/dmx/glxProxy/glxcmds.h
+++ b/xserver/hw/dmx/glxProxy/glxcmds.h
@@ -33,5 +33,11 @@ extern int __glXCreateContextWithConfigSGIX(__GLXclientState * cl, GLbyte * pc);
extern int __glXJoinSwapGroupSGIX(__GLXclientState * cl, GLbyte * pc);
extern int __glXMakeCurrentReadSGI(__GLXclientState * cl, GLbyte * pc);
extern int __glXQueryMaxSwapBarriersSGIX(__GLXclientState * cl, GLbyte * pc);
+extern int __glXDoSwapBuffers(__GLXclientState * cl, XID drawId,
+ GLXContextTag tag);
+
+extern Display *GetBackEndDisplay(__GLXclientState * cl, int s);
+extern int GetCurrentBackEndTag(__GLXclientState * cl, GLXContextTag tag,
+ int s);
#endif /* !__GLX_cmds_h__ */
diff --git a/xserver/hw/dmx/glxProxy/glxcmdsswap.c b/xserver/hw/dmx/glxProxy/glxcmdsswap.c
index ab3e7edc1..5b1722d57 100644
--- a/xserver/hw/dmx/glxProxy/glxcmdsswap.c
+++ b/xserver/hw/dmx/glxProxy/glxcmdsswap.c
@@ -39,8 +39,6 @@
#include "glxext.h"
#include "glxvendor.h"
-extern int glxIsExtensionSupported(char *ext);
-
int __glXSwapGetFBConfigsSGIX(__GLXclientState * cl, GLbyte * pc);
/************************************************************************/
@@ -440,7 +438,7 @@ __glXSwapUseXFont(__GLXclientState * cl, GLbyte * pc)
int
__glXSwapQueryExtensionsString(__GLXclientState * cl, GLbyte * pc)
{
- xGLXQueryExtensionsStringReq *req = NULL;
+ xGLXQueryExtensionsStringReq *req = (xGLXQueryExtensionsStringReq *) pc;
__GLX_DECLARE_SWAP_VARIABLES;
diff --git a/xserver/hw/dmx/glxProxy/glxext.h b/xserver/hw/dmx/glxProxy/glxext.h
index 47cec15cf..b96ebc1f4 100644
--- a/xserver/hw/dmx/glxProxy/glxext.h
+++ b/xserver/hw/dmx/glxProxy/glxext.h
@@ -53,6 +53,7 @@ extern void __glXFlushContextCache(void);
extern void __glXFreeGLXWindow(__glXWindow * pGlxWindow);
extern void __glXFreeGLXPixmap(__GLXpixmap * pGlxPixmap);
+extern void __glXFreeGLXPbuffer(__glXPbuffer * pGlxPbuffer);
extern void __glXNoSuchRenderOpcode(GLbyte *);
extern int __glXNoSuchSingleOpcode(__GLXclientState *, GLbyte *);
diff --git a/xserver/hw/dmx/glxProxy/glxscreens.c b/xserver/hw/dmx/glxProxy/glxscreens.c
index 138afedf2..15bb1e862 100644
--- a/xserver/hw/dmx/glxProxy/glxscreens.c
+++ b/xserver/hw/dmx/glxProxy/glxscreens.c
@@ -65,8 +65,6 @@ static void
CalcServerVersionAndExtensions(void)
{
int s;
- xGLXQueryVersionReq *req;
- xGLXQueryVersionReply reply;
char **be_extensions;
char *ext;
char *denied_extensions;
@@ -80,6 +78,8 @@ CalcServerVersionAndExtensions(void)
for (s = 0; s < __glXNumActiveScreens; s++) {
DMXScreenInfo *dmxScreen = &dmxScreens[s];
Display *dpy = dmxScreen->beDisplay;
+ xGLXQueryVersionReq *req;
+ xGLXQueryVersionReply reply;
/* Send the glXQueryVersion request */
LockDisplay(dpy);
@@ -335,7 +335,7 @@ __glXGetServerString(unsigned int name)
}
int
-glxIsExtensionSupported(char *ext)
+glxIsExtensionSupported(const char *ext)
{
return (strstr(ExtensionsString, ext) != NULL);
}
diff --git a/xserver/hw/dmx/glxProxy/glxscreens.h b/xserver/hw/dmx/glxProxy/glxscreens.h
index a9fe2a9db..bb7477bc7 100644
--- a/xserver/hw/dmx/glxProxy/glxscreens.h
+++ b/xserver/hw/dmx/glxProxy/glxscreens.h
@@ -50,4 +50,6 @@ extern void __glXScreenReset(void);
extern char *__glXGetServerString(unsigned int name);
+extern int glxIsExtensionSupported(const char *ext);
+
#endif /* !__GLX_screens_h__ */
diff --git a/xserver/hw/dmx/glxProxy/glxserver.h b/xserver/hw/dmx/glxProxy/glxserver.h
index 754ad30a0..7aa5ad2f2 100644
--- a/xserver/hw/dmx/glxProxy/glxserver.h
+++ b/xserver/hw/dmx/glxProxy/glxserver.h
@@ -149,9 +149,7 @@ extern __GLXclientState *__glXClients[];
typedef void (*__GLXdispatchRenderProcPtr) (GLbyte *);
typedef int (*__GLXdispatchSingleProcPtr) (__GLXclientState *, GLbyte *);
typedef int (*__GLXdispatchVendorPrivProcPtr) (__GLXclientState *, GLbyte *);
-extern __GLXdispatchSingleProcPtr __glXSingleTable[];
extern __GLXdispatchVendorPrivProcPtr __glXVendorPrivTable_EXT[];
-extern __GLXdispatchSingleProcPtr __glXSwapSingleTable[];
extern __GLXdispatchVendorPrivProcPtr __glXSwapVendorPrivTable_EXT[];
extern __GLXdispatchRenderProcPtr __glXSwapRenderTable[];
@@ -193,9 +191,6 @@ extern RESTYPE __glXPbufferRes;
extern char *__glXcombine_strings(const char *, const char *);
-extern void __glXDisp_DrawArrays(GLbyte *);
-extern void __glXDispSwap_DrawArrays(GLbyte *);
-
/*
** Routines for sending swapped replies.
*/
@@ -287,9 +282,6 @@ extern int __glXConvolutionParameterfvSize(GLenum pname);
extern int __glXColorTableParameterfvSize(GLenum pname);
extern int __glXColorTableParameterivSize(GLenum pname);
-extern void __glXFreeGLXWindow(__glXWindow * pGlxWindow);
-extern void __glXFreeGLXPbuffer(__glXPbuffer * pGlxPbuffer);
-
extern int __glXVersionMajor;
extern int __glXVersionMinor;
diff --git a/xserver/hw/dmx/glxProxy/glxsingle.c b/xserver/hw/dmx/glxProxy/glxsingle.c
index 034497315..79d426bbf 100644
--- a/xserver/hw/dmx/glxProxy/glxsingle.c
+++ b/xserver/hw/dmx/glxProxy/glxsingle.c
@@ -45,6 +45,8 @@
/* #include "g_disptab_EXT.h" */
#include "unpack.h"
#include "glxutil.h"
+#include "glxcmds.h"
+#include "glxsingle.h"
#include "GL/glxproto.h"
@@ -81,10 +83,6 @@
#define X_GLXSingle 0 /* needed by GetReqExtra */
-extern Display *GetBackEndDisplay(__GLXclientState * cl, int s);
-extern int GetCurrentBackEndTag(__GLXclientState * cl, GLXContextTag tag,
- int s);
-
static int swap_vec_element_size = 0;
static void
diff --git a/xserver/hw/dmx/glxProxy/glxsingle.h b/xserver/hw/dmx/glxProxy/glxsingle.h
index 32a9d4921..6126177fa 100644
--- a/xserver/hw/dmx/glxProxy/glxsingle.h
+++ b/xserver/hw/dmx/glxProxy/glxsingle.h
@@ -47,8 +47,4 @@ extern int __glXForwardAllWithReplySwapsv(__GLXclientState * cl, GLbyte * pc);
extern int __glXForwardAllWithReplySwapiv(__GLXclientState * cl, GLbyte * pc);
extern int __glXForwardAllWithReplySwapdv(__GLXclientState * cl, GLbyte * pc);
-extern int __glXDisp_ReadPixels(__GLXclientState * cl, GLbyte * pc);
-extern int __glXDispSwap_GetTexImage(__GLXclientState * cl, GLbyte * pc);
-extern int __glXDispSwap_GetColorTable(__GLXclientState * cl, GLbyte * pc);
-
#endif
diff --git a/xserver/hw/dmx/glxProxy/glxswap.c b/xserver/hw/dmx/glxProxy/glxswap.c
index 5f565010d..bc18e5518 100644
--- a/xserver/hw/dmx/glxProxy/glxswap.c
+++ b/xserver/hw/dmx/glxProxy/glxswap.c
@@ -39,9 +39,7 @@
#include "dmxwindow.h"
#include "glxserver.h"
#include "glxswap.h"
-
-extern int __glXDoSwapBuffers(__GLXclientState * cl, XID drawId,
- GLXContextTag tag);
+#include "glxcmds.h"
typedef struct _SwapGroup *SwapGroupPtr;
diff --git a/xserver/hw/dmx/glxProxy/glxvendor.c b/xserver/hw/dmx/glxProxy/glxvendor.c
index fc8aff0cc..52d70eb70 100644
--- a/xserver/hw/dmx/glxProxy/glxvendor.c
+++ b/xserver/hw/dmx/glxProxy/glxvendor.c
@@ -44,6 +44,8 @@
/* #include "g_disptab_EXT.h" */
#include "unpack.h"
#include "glxutil.h"
+#include "glxcmds.h"
+#include "glxvendor.h"
#include "GL/glxproto.h"
@@ -78,10 +80,6 @@
dpy->request++
#endif
-extern Display *GetBackEndDisplay(__GLXclientState * cl, int s);
-extern int GetCurrentBackEndTag(__GLXclientState * cl, GLXContextTag tag,
- int s);
-
static int swap_vec_element_size = 0;
static void
diff --git a/xserver/hw/dmx/input/dmxinputinit.c b/xserver/hw/dmx/input/dmxinputinit.c
index abb6a8551..56a39df8c 100644
--- a/xserver/hw/dmx/input/dmxinputinit.c
+++ b/xserver/hw/dmx/input/dmxinputinit.c
@@ -874,17 +874,17 @@ dmxInputScanForExtensions(DMXInputInfo * dmxInput, int doXI)
{
XExtensionVersion *ext;
XDeviceInfo *devices;
- Display *display;
+ Display *dsp;
int num;
int i, j;
XextErrorHandler handler;
- if (!(display = XOpenDisplay(dmxInput->name)))
+ if (!(dsp = XOpenDisplay(dmxInput->name)))
return;
/* Print out information about the XInput Extension. */
handler = XSetExtensionErrorHandler(dmxInputExtensionErrorHandler);
- ext = XGetExtensionVersion(display, INAME);
+ ext = XGetExtensionVersion(dsp, INAME);
XSetExtensionErrorHandler(handler);
if (!ext || ext == (XExtensionVersion *) NoSuchExtension) {
@@ -894,7 +894,7 @@ dmxInputScanForExtensions(DMXInputInfo * dmxInput, int doXI)
dmxLogInput(dmxInput, "Locating devices on %s (%s version %d.%d)\n",
dmxInput->name, INAME,
ext->major_version, ext->minor_version);
- devices = XListInputDevices(display, &num);
+ devices = XListInputDevices(dsp, &num);
XFree(ext);
ext = NULL;
@@ -956,7 +956,7 @@ dmxInputScanForExtensions(DMXInputInfo * dmxInput, int doXI)
}
XFreeDeviceList(devices);
}
- XCloseDisplay(display);
+ XCloseDisplay(dsp);
}
/** Re-initialize all the devices described in \a dmxInput. Called from