aboutsummaryrefslogtreecommitdiff
path: root/xorg-server
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2011-04-27 15:56:59 +0000
committermarha <marha@users.sourceforge.net>2011-04-27 15:56:59 +0000
commit100633b3e7619842f345cb7603b0db6b5761dd11 (patch)
tree3c3af754c7e801c07263269837d6a05072ff834c /xorg-server
parent205a4bdae76f287126db9f45a4f0ba631e3efca1 (diff)
parent96d6df5da9cddedf4931bf8e17f96e242467c661 (diff)
downloadvcxsrv-100633b3e7619842f345cb7603b0db6b5761dd11.tar.gz
vcxsrv-100633b3e7619842f345cb7603b0db6b5761dd11.tar.bz2
vcxsrv-100633b3e7619842f345cb7603b0db6b5761dd11.zip
svn merge ^/branches/released .
Diffstat (limited to 'xorg-server')
-rw-r--r--xorg-server/Xext/xtest.c2
-rw-r--r--xorg-server/Xi/exevents.c11
-rw-r--r--xorg-server/Xi/extinit.c2
-rw-r--r--xorg-server/Xi/xichangehierarchy.c2
-rw-r--r--xorg-server/Xi/xipassivegrab.c16
-rw-r--r--xorg-server/composite/compalloc.c26
-rw-r--r--xorg-server/configure.ac16
-rw-r--r--xorg-server/dix/devices.c49
-rw-r--r--xorg-server/dix/getevents.c21
-rw-r--r--xorg-server/dix/ptrveloc.c292
-rw-r--r--xorg-server/dix/resource.c2
-rw-r--r--xorg-server/glx/Makefile.am5
-rw-r--r--xorg-server/glx/dispatch.h1252
-rw-r--r--xorg-server/glx/glapitable.h584
-rw-r--r--xorg-server/glx/glprocs.h1458
-rw-r--r--xorg-server/glx/glxcmds.c11
-rw-r--r--xorg-server/glx/glxdri2.c1
-rw-r--r--xorg-server/glx/glxext.c22
-rw-r--r--xorg-server/glx/indirect_dispatch.h6
-rw-r--r--xorg-server/glx/indirect_reqsize.h2
-rw-r--r--xorg-server/glx/indirect_size.h2
-rw-r--r--xorg-server/glx/indirect_size_get.c3
-rw-r--r--xorg-server/glx/indirect_size_get.h2
-rw-r--r--xorg-server/hw/dmx/input/dmxevents.c6
-rw-r--r--xorg-server/hw/kdrive/src/kinput.c4
-rw-r--r--xorg-server/hw/xfree86/common/xf86Configure.c13
-rw-r--r--xorg-server/hw/xfree86/common/xf86Events.c1506
-rw-r--r--xorg-server/hw/xfree86/common/xf86Xinput.c15
-rw-r--r--xorg-server/hw/xfree86/os-support/linux/lnx_init.c83
-rw-r--r--xorg-server/hw/xnest/Events.c2
-rw-r--r--xorg-server/hw/xquartz/X11Application.m78
-rw-r--r--xorg-server/hw/xquartz/darwin.c3
-rw-r--r--xorg-server/hw/xquartz/darwin.h1
-rw-r--r--xorg-server/hw/xquartz/darwinEvents.c1194
-rw-r--r--xorg-server/hw/xquartz/darwinEvents.h179
-rw-r--r--xorg-server/hw/xquartz/mach-startup/bundle-main.c47
-rw-r--r--xorg-server/hw/xwin/winkeybd.c2
-rw-r--r--xorg-server/include/dix-config.h.in3
-rw-r--r--xorg-server/include/input.h11
-rw-r--r--xorg-server/include/inputstr.h2
-rw-r--r--xorg-server/include/ptrveloc.h2
-rw-r--r--xorg-server/test/Makefile.am6
-rw-r--r--xorg-server/test/input.c523
-rw-r--r--xorg-server/test/list.c57
-rw-r--r--xorg-server/test/xi2/Makefile.am10
-rw-r--r--xorg-server/test/xi2/protocol-common.c5
-rw-r--r--xorg-server/test/xi2/protocol-common.h307
-rw-r--r--xorg-server/test/xi2/protocol-eventconvert.c1830
-rw-r--r--xorg-server/test/xi2/protocol-xigetclientpointer.c329
-rw-r--r--xorg-server/test/xi2/protocol-xigetselectedevents.c478
-rw-r--r--xorg-server/test/xi2/protocol-xipassivegrabdevice.c234
-rw-r--r--xorg-server/test/xi2/protocol-xiquerydevice.c628
-rw-r--r--xorg-server/test/xi2/protocol-xiquerypointer.c38
-rw-r--r--xorg-server/test/xi2/protocol-xiqueryversion.c368
-rw-r--r--xorg-server/test/xi2/protocol-xiselectevents.c672
-rw-r--r--xorg-server/test/xi2/protocol-xisetclientpointer.c294
-rw-r--r--xorg-server/test/xi2/protocol-xiwarppointer.c24
-rw-r--r--xorg-server/test/xkb.c342
-rw-r--r--xorg-server/test/xtest.c39
-rw-r--r--xorg-server/xkeyboard-config/rules/base.extras.xml.in20
-rw-r--r--xorg-server/xkeyboard-config/symbols/apl592
-rw-r--r--xorg-server/xkeyboard-config/symbols/et2
-rw-r--r--xorg-server/xkeyboard-config/symbols/lv2
-rw-r--r--xorg-server/xkeyboard-config/symbols/us4
-rw-r--r--xorg-server/xkeyboard-config/tests/genLists4Comparizon.sh12
65 files changed, 7139 insertions, 6615 deletions
diff --git a/xorg-server/Xext/xtest.c b/xorg-server/Xext/xtest.c
index 0548a8e74..a7fb183d5 100644
--- a/xorg-server/Xext/xtest.c
+++ b/xorg-server/Xext/xtest.c
@@ -423,7 +423,7 @@ ProcXTestFakeInput(ClientPtr client)
break;
case KeyPress:
case KeyRelease:
- nevents = GetKeyboardEvents(xtest_evlist, dev, type, ev->u.u.detail);
+ nevents = GetKeyboardEvents(xtest_evlist, dev, type, ev->u.u.detail, NULL);
break;
}
diff --git a/xorg-server/Xi/exevents.c b/xorg-server/Xi/exevents.c
index 1232fe363..34dd80ff6 100644
--- a/xorg-server/Xi/exevents.c
+++ b/xorg-server/Xi/exevents.c
@@ -537,6 +537,7 @@ DeepCopyPointerClasses(DeviceIntPtr from, DeviceIntPtr to)
if (from->valuator)
{
ValuatorClassPtr v;
+
if (!to->valuator)
{
classes = to->unused_classes;
@@ -545,18 +546,14 @@ DeepCopyPointerClasses(DeviceIntPtr from, DeviceIntPtr to)
classes->valuator = NULL;
}
- to->valuator = realloc(to->valuator, sizeof(ValuatorClassRec) +
- from->valuator->numAxes * sizeof(AxisInfo) +
- from->valuator->numAxes * sizeof(double));
- v = to->valuator;
+ v = AllocValuatorClass(to->valuator, from->valuator->numAxes);
+
if (!v)
FatalError("[Xi] no memory for class shift.\n");
- v->numAxes = from->valuator->numAxes;
- v->axes = (AxisInfoPtr)&v[1];
+ to->valuator = v;
memcpy(v->axes, from->valuator->axes, v->numAxes * sizeof(AxisInfo));
- v->axisVal = (double*)(v->axes + from->valuator->numAxes);
v->sourceid = from->id;
} else if (to->valuator && !from->valuator)
{
diff --git a/xorg-server/Xi/extinit.c b/xorg-server/Xi/extinit.c
index 84b0086ff..88786abb7 100644
--- a/xorg-server/Xi/extinit.c
+++ b/xorg-server/Xi/extinit.c
@@ -511,7 +511,7 @@ SReplyIDispatch(ClientPtr client, int len, xGrabDeviceReply * rep)
SRepXIQueryDevice(client, len, (xXIQueryDeviceReply*)rep);
else if (rep->RepType == X_XIGrabDevice)
SRepXIGrabDevice(client, len, (xXIGrabDeviceReply *) rep);
- else if (rep->RepType == X_XIGrabDevice)
+ else if (rep->RepType == X_XIPassiveGrabDevice)
SRepXIPassiveGrabDevice(client, len, (xXIPassiveGrabDeviceReply *) rep);
else if (rep->RepType == X_XIListProperties)
SRepXIListProperties(client, len, (xXIListPropertiesReply *) rep);
diff --git a/xorg-server/Xi/xichangehierarchy.c b/xorg-server/Xi/xichangehierarchy.c
index d48200b04..94edf6623 100644
--- a/xorg-server/Xi/xichangehierarchy.c
+++ b/xorg-server/Xi/xichangehierarchy.c
@@ -116,7 +116,9 @@ void XISendDeviceHierarchyEvent(int flags[MAXDEVICES])
ev->length = bytes_to_int32(ev->num_info * sizeof(xXIHierarchyInfo));
+ memset(&dummyDev, 0, sizeof(dummyDev));
dummyDev.id = XIAllDevices;
+ dummyDev.type = SLAVE;
SendEventToAllWindows(&dummyDev, (XI_HierarchyChangedMask >> 8), (xEvent*)ev, 1);
free(ev);
}
diff --git a/xorg-server/Xi/xipassivegrab.c b/xorg-server/Xi/xipassivegrab.c
index 487c2721b..fe8c3944a 100644
--- a/xorg-server/Xi/xipassivegrab.c
+++ b/xorg-server/Xi/xipassivegrab.c
@@ -43,6 +43,7 @@
#include "exevents.h"
#include "xipassivegrab.h"
#include "dixgrabs.h"
+#include "misc.h"
int
SProcXIPassiveGrabDevice(ClientPtr client)
@@ -87,6 +88,7 @@ ProcXIPassiveGrabDevice(ClientPtr client)
GrabParameters param;
void *tmp;
int mask_len;
+ int n;
REQUEST(xXIPassiveGrabDeviceReq);
REQUEST_AT_LEAST_SIZE(xXIPassiveGrabDeviceReq);
@@ -99,7 +101,10 @@ ProcXIPassiveGrabDevice(ClientPtr client)
{
ret = dixLookupDevice(&dev, stuff->deviceid, client, DixGrabAccess);
if (ret != Success)
+ {
+ client->errorValue = stuff->deviceid;
return ret;
+ }
}
if (stuff->grab_type != XIGrabtypeButton &&
@@ -156,6 +161,8 @@ ProcXIPassiveGrabDevice(ClientPtr client)
return status;
status = CheckGrabValues(client, &param);
+ if (status != Success)
+ return status;
modifiers = (uint32_t*)&stuff[1] + stuff->mask_len;
modifiers_failed = calloc(stuff->num_modifiers, sizeof(xXIGrabModifierInfo));
@@ -190,6 +197,9 @@ ProcXIPassiveGrabDevice(ClientPtr client)
info->status = status;
info->modifiers = *modifiers;
+ if (client->swapped)
+ swapl(&info->modifiers, n);
+
rep.num_modifiers++;
rep.length += bytes_to_int32(sizeof(xXIGrabModifierInfo));
}
@@ -197,10 +207,8 @@ ProcXIPassiveGrabDevice(ClientPtr client)
WriteReplyToClient(client, sizeof(rep), &rep);
if (rep.num_modifiers)
- {
- client->pSwapReplyFunc = (ReplySwapPtr) Swap32Write;
- WriteSwappedDataToClient(client, rep.length * 4, (char*)modifiers_failed);
- }
+ WriteToClient(client, rep.length * 4, (char*)modifiers_failed);
+
free(modifiers_failed);
return ret;
}
diff --git a/xorg-server/composite/compalloc.c b/xorg-server/composite/compalloc.c
index 8853f7058..dba67303d 100644
--- a/xorg-server/composite/compalloc.c
+++ b/xorg-server/composite/compalloc.c
@@ -508,17 +508,6 @@ compUnredirectOneSubwindow (WindowPtr pParent, WindowPtr pWin)
return Success;
}
-static int
-bgNoneVisitWindow(WindowPtr pWin, void *null)
-{
- if (pWin->backgroundState != BackgroundPixmap)
- return WT_WALKCHILDREN;
- if (pWin->background.pixmap != None)
- return WT_WALKCHILDREN;
-
- return WT_STOPWALKING;
-}
-
static PixmapPtr
compNewPixmap (WindowPtr pWin, int x, int y, int w, int h, Bool map)
{
@@ -539,21 +528,6 @@ compNewPixmap (WindowPtr pWin, int x, int y, int w, int h, Bool map)
if (!map)
return pPixmap;
- /*
- * If there's no bg=None in the tree, we're done.
- *
- * We could optimize this more by collection the regions of all the
- * bg=None subwindows and feeding that in as the clip for the
- * CopyArea below, but since window trees are shallow these days it
- * might not be worth the effort.
- */
- if (TraverseTree(pWin, bgNoneVisitWindow, NULL) == WT_NOMATCH)
- return pPixmap;
-
- /*
- * Copy bits from the parent into the new pixmap so that it will
- * have "reasonable" contents in case for background None areas.
- */
if (pParent->drawable.depth == pWin->drawable.depth)
{
GCPtr pGC = GetScratchGC (pWin->drawable.depth, pScreen);
diff --git a/xorg-server/configure.ac b/xorg-server/configure.ac
index 27aed8ecb..d80eca044 100644
--- a/xorg-server/configure.ac
+++ b/xorg-server/configure.ac
@@ -35,7 +35,7 @@ AM_MAINTAINER_MODE
# Require xorg-macros minimum of 1.13 for XORG_ENABLE_UNIT_TESTS
m4_ifndef([XORG_MACROS_VERSION],
[m4_fatal([must install xorg-macros 1.13 or later before running autoconf/autogen])])
-XORG_MACROS_VERSION(1.10)
+XORG_MACROS_VERSION(1.13)
XORG_DEFAULT_OPTIONS
XORG_WITH_DOXYGEN(1.6.1)
XORG_CHECK_SGML_DOCTOOLS(1.5)
@@ -44,7 +44,6 @@ XORG_ENABLE_DEVEL_DOCS
XORG_WITH_XMLTO(0.0.20)
XORG_WITH_FOP
XORG_ENABLE_UNIT_TESTS
-XORG_WITH_GLIB
XORG_LD_WRAP
m4_ifndef([XORG_FONT_MACROS_VERSION], [m4_fatal([must install fontutil 1.1 or later before running autoconf/autogen])])
@@ -726,9 +725,9 @@ case $host_os in
save_LDFLAGS=$LDFLAGS
LDFLAGS="$LDFLAGS -framework Carbon"
AC_LINK_IFELSE([char FSFindFolder(); int main() { FSFindFolder(); return 0;}],
- [xorg_cv_Carbon_framework=yes],
- [xorg_cv_Carbon_framework=no])
- LDFLAGS=$save_LDFLAGS])
+ [xorg_cv_Carbon_framework=yes],
+ [xorg_cv_Carbon_framework=no])
+ LDFLAGS=$save_LDFLAGS])
if test "X$xorg_cv_Carbon_framework" = Xyes; then
XQUARTZ=yes
@@ -737,6 +736,10 @@ case $host_os in
fi
fi
+ AC_CHECK_FUNC(dispatch_async,
+ AC_DEFINE([HAVE_LIBDISPATCH], 1, [Define to 1 if you have the libdispatch (GCD) available]),
+ [])
+
if test "x$XQUARTZ" = xyes ; then
XQUARTZ=yes
XVFB=no
@@ -791,7 +794,6 @@ LIBXFONT="xfont >= 1.4.2"
LIBXI="xi >= 1.2.99.1"
LIBXTST="xtst >= 1.0.99.2"
LIBPCIACCESS="pciaccess >= 0.8.0"
-LIBGLIB="glib-2.0 >= 2.16"
LIBUDEV="libudev >= 143"
LIBSELINUX="libselinux >= 2.0.86"
LIBDBUS="dbus-1 >= 1.0"
@@ -1006,7 +1008,7 @@ else
fi
AM_CONDITIONAL(GLX, test "x$GLX" = xyes)
-if test "x$AIGLX" = xyes -a "x$GLX" = xyes -a "x$DRI" = xyes; then
+if test "x$AIGLX" = xyes -a "x$GLX" = xyes -a \( "x$DRI" = xyes -o "x$DRI2" = xyes \); then
AC_DEFINE(AIGLX, 1, [Build AIGLX loader])
else
AIGLX=no
diff --git a/xorg-server/dix/devices.c b/xorg-server/dix/devices.c
index 8af202164..4a94c0534 100644
--- a/xorg-server/dix/devices.c
+++ b/xorg-server/dix/devices.c
@@ -1229,13 +1229,46 @@ InitButtonClassDeviceStruct(DeviceIntPtr dev, int numButtons, Atom* labels,
return TRUE;
}
+/**
+ * Allocate a valuator class and set up the pointers for the axis values
+ * appropriately.
+ *
+ * @param src If non-NULL, the memory is reallocated from src. If NULL, the
+ * memory is calloc'd.
+ * @parma numAxes Number of axes to allocate.
+ * @return The allocated valuator struct.
+ */
+ValuatorClassPtr
+AllocValuatorClass(ValuatorClassPtr src, int numAxes)
+{
+ ValuatorClassPtr v;
+ /* force alignment with double */
+ union align_u { ValuatorClassRec valc; double d; } *align;
+ int size;
+
+ size = sizeof(union align_u) + numAxes * (sizeof(double) + sizeof(AxisInfo));
+ align = (union align_u *) realloc(src, size);
+
+ if (!align)
+ return NULL;
+
+ if (!src)
+ memset(align, 0, size);
+
+ v = &align->valc;
+ v->numAxes = numAxes;
+ v->axisVal = (double*)(align + 1);
+ v->axes = (AxisInfoPtr)(v->axisVal + numAxes);
+
+ return v;
+}
+
Bool
InitValuatorClassDeviceStruct(DeviceIntPtr dev, int numAxes, Atom *labels,
int numMotionEvents, int mode)
{
int i;
ValuatorClassPtr valc;
- union align_u { ValuatorClassRec valc; double d; } *align;
if (!dev)
return FALSE;
@@ -1248,13 +1281,10 @@ InitValuatorClassDeviceStruct(DeviceIntPtr dev, int numAxes, Atom *labels,
numAxes = MAX_VALUATORS;
}
- align = (union align_u *) calloc(1, sizeof(union align_u) +
- numAxes * sizeof(double) +
- numAxes * sizeof(AxisInfo));
- if (!align)
- return FALSE;
+ valc = AllocValuatorClass(NULL, numAxes);
+ if (!valc)
+ return FALSE;
- valc = &align->valc;
valc->sourceid = dev->id;
valc->motion = NULL;
valc->first_motion = 0;
@@ -1262,9 +1292,6 @@ InitValuatorClassDeviceStruct(DeviceIntPtr dev, int numAxes, Atom *labels,
valc->numMotionEvents = numMotionEvents;
valc->motionHintWindow = NullWindow;
- valc->numAxes = numAxes;
- valc->axisVal = (double *)(align + 1);
- valc->axes = (AxisInfoPtr)(valc->axisVal + numAxes);
if (mode & OutOfProximity)
InitProximityClassDeviceStruct(dev);
@@ -2373,7 +2400,7 @@ ReleaseButtonsAndKeys(DeviceIntPtr dev)
{
if (BitIsOn(k->down, i))
{
- nevents = GetKeyboardEvents(eventlist, dev, KeyRelease, i);
+ nevents = GetKeyboardEvents(eventlist, dev, KeyRelease, i, NULL);
for (j = 0; j < nevents; j++)
mieqProcessDeviceEvent(dev, (InternalEvent*)(eventlist+j)->event, NULL);
}
diff --git a/xorg-server/dix/getevents.c b/xorg-server/dix/getevents.c
index c8fb48192..ac0f0ab23 100644
--- a/xorg-server/dix/getevents.c
+++ b/xorg-server/dix/getevents.c
@@ -631,8 +631,8 @@ updateMotionHistory(DeviceIntPtr pDev, CARD32 ms, ValuatorMask *mask,
/**
- * Returns the maximum number of events GetKeyboardEvents,
- * GetKeyboardValuatorEvents, and GetPointerEvents will ever return.
+ * Returns the maximum number of events GetKeyboardEvents
+ * and GetPointerEvents will ever return.
*
* This MUST be absolutely constant, from init until exit.
*/
@@ -941,19 +941,6 @@ updateHistory(DeviceIntPtr dev, ValuatorMask *mask, CARD32 ms)
}
/**
- * Convenience wrapper around GetKeyboardValuatorEvents, that takes no
- * valuators.
- */
-int
-GetKeyboardEvents(EventList *events, DeviceIntPtr pDev, int type, int key_code) {
- ValuatorMask mask;
-
- valuator_mask_zero(&mask);
- return GetKeyboardValuatorEvents(events, pDev, type, key_code, &mask);
-}
-
-
-/**
* Returns a set of InternalEvents for KeyPress/KeyRelease, optionally
* also with valuator events.
*
@@ -962,8 +949,8 @@ GetKeyboardEvents(EventList *events, DeviceIntPtr pDev, int type, int key_code)
* place via GetMaximumEventsNum(), and for freeing it.
*/
int
-GetKeyboardValuatorEvents(EventList *events, DeviceIntPtr pDev, int type,
- int key_code, const ValuatorMask *mask_in) {
+GetKeyboardEvents(EventList *events, DeviceIntPtr pDev, int type,
+ int key_code, const ValuatorMask *mask_in) {
int num_events = 0;
CARD32 ms = 0;
DeviceEvent *event;
diff --git a/xorg-server/dix/ptrveloc.c b/xorg-server/dix/ptrveloc.c
index 2ffc984c3..992bc2bf1 100644
--- a/xorg-server/dix/ptrveloc.c
+++ b/xorg-server/dix/ptrveloc.c
@@ -438,82 +438,115 @@ InitTrackers(DeviceVelocityPtr vel, int ntracker)
vel->num_tracker = ntracker;
}
+enum directions {
+ N = (1 << 0),
+ NE = (1 << 1),
+ E = (1 << 2),
+ SE = (1 << 3),
+ S = (1 << 4),
+ SW = (1 << 5),
+ W = (1 << 6),
+ NW = (1 << 7),
+ UNDEFINED = 0xFF
+};
/**
* return a bit field of possible directions.
- * 0 = N, 2 = E, 4 = S, 6 = W, in-between is as you guess.
* There's no reason against widening to more precise directions (<45 degrees),
* should it not perform well. All this is needed for is sort out non-linear
* motion, so precision isn't paramount. However, one should not flag direction
* too narrow, since it would then cut the linear segment to zero size way too
* often.
+ *
+ * @return A bitmask for N, NE, S, SE, etc. indicating the directions for
+ * this movement.
*/
static int
DoGetDirection(int dx, int dy){
- float r;
- int i1, i2;
+ int dir = 0;
+
/* on insignificant mickeys, flag 135 degrees */
- if(abs(dx) < 2 && abs(dy < 2)){
- /* first check diagonal cases */
- if(dx > 0 && dy > 0)
- return 4+8+16;
- if(dx > 0 && dy < 0)
- return 1+2+4;
- if(dx < 0 && dy < 0)
- return 1+128+64;
- if(dx < 0 && dy > 0)
- return 16+32+64;
+ if(abs(dx) < 2 && abs(dy) < 2){
+ /* first check diagonal cases */
+ if(dx > 0 && dy > 0)
+ dir = E | SE | S;
+ else if(dx > 0 && dy < 0)
+ dir = N | NE | E;
+ else if(dx < 0 && dy < 0)
+ dir = W | NW | N;
+ else if(dx < 0 && dy > 0)
+ dir = W | SW | S;
/* check axis-aligned directions */
- if(dx > 0)
- return 2+4+8; /*E*/
- if(dx < 0)
- return 128+64+32; /*W*/
- if(dy > 0)
- return 32+16+8; /*S*/
- if(dy < 0)
- return 128+1+2; /*N*/
- return 255; /* shouldn't happen */
- }
- /* else, compute angle and set appropriate flags */
+ else if(dx > 0)
+ dir = NE | E | SE;
+ else if(dx < 0)
+ dir = NW | W | SW;
+ else if(dy > 0)
+ dir = SE | S | SW;
+ else if(dy < 0)
+ dir = NE | N | NW;
+ else
+ dir = UNDEFINED; /* shouldn't happen */
+ } else { /* compute angle and set appropriate flags */
+ float r;
+ int i1, i2;
+
#ifdef _ISOC99_SOURCE
- r = atan2f(dy, dx);
+ r = atan2f(dy, dx);
#else
- r = atan2(dy, dx);
+ r = atan2(dy, dx);
#endif
- /* find direction. We avoid r to become negative,
- * since C has no well-defined modulo for such cases. */
- r = (r+(M_PI*2.5))/(M_PI/4);
- /* this intends to flag 2 directions (90 degrees),
- * except on very well-aligned mickeys. */
- i1 = (int)(r+0.1) % 8;
- i2 = (int)(r+0.9) % 8;
- if(i1 < 0 || i1 > 7 || i2 < 0 || i2 > 7)
- return 255; /* shouldn't happen */
- return 1 << i1 | 1 << i2;
+ /* find direction.
+ *
+ * Add 360° to avoid r become negative since C has no well-defined
+ * modulo for such cases. Then divide by 45° to get the octant
+ * number, e.g.
+ * 0 <= r <= 1 is [0-45]°
+ * 1 <= r <= 2 is [45-90]°
+ * etc.
+ * But we add extra 90° to match up with our N, S, etc. defines up
+ * there, rest stays the same.
+ */
+ r = (r+(M_PI*2.5))/(M_PI/4);
+ /* this intends to flag 2 directions (45 degrees),
+ * except on very well-aligned mickeys. */
+ i1 = (int)(r+0.1) % 8;
+ i2 = (int)(r+0.9) % 8;
+ if(i1 < 0 || i1 > 7 || i2 < 0 || i2 > 7)
+ dir = UNDEFINED; /* shouldn't happen */
+ else
+ dir = (1 << i1 | 1 << i2);
+ }
+ return dir;
}
#define DIRECTION_CACHE_RANGE 5
#define DIRECTION_CACHE_SIZE (DIRECTION_CACHE_RANGE*2+1)
-/* cache DoGetDirection(). */
+/* cache DoGetDirection().
+ * To avoid excessive use of direction calculation, cache the values for
+ * [-5..5] for both x/y. Anything outside of that is calcualted on the fly.
+ *
+ * @return A bitmask for N, NE, S, SE, etc. indicating the directions for
+ * this movement.
+ */
static int
GetDirection(int dx, int dy){
static int cache[DIRECTION_CACHE_SIZE][DIRECTION_CACHE_SIZE];
- int i;
+ int dir;
if (abs(dx) <= DIRECTION_CACHE_RANGE &&
abs(dy) <= DIRECTION_CACHE_RANGE) {
/* cacheable */
- i = cache[DIRECTION_CACHE_RANGE+dx][DIRECTION_CACHE_RANGE+dy];
- if(i != 0){
- return i;
- }else{
- i = DoGetDirection(dx, dy);
- cache[DIRECTION_CACHE_RANGE+dx][DIRECTION_CACHE_RANGE+dy] = i;
- return i;
+ dir = cache[DIRECTION_CACHE_RANGE+dx][DIRECTION_CACHE_RANGE+dy];
+ if(dir == 0) {
+ dir = DoGetDirection(dx, dy);
+ cache[DIRECTION_CACHE_RANGE+dx][DIRECTION_CACHE_RANGE+dy] = dir;
}
}else{
/* non-cacheable */
- return DoGetDirection(dx, dy);
+ dir = DoGetDirection(dx, dy);
}
+
+ return dir;
}
#undef DIRECTION_CACHE_RANGE
@@ -522,7 +555,12 @@ GetDirection(int dx, int dy){
/* convert offset (age) to array index */
#define TRACKER_INDEX(s, d) (((s)->num_tracker + (s)->cur_tracker - (d)) % (s)->num_tracker)
+#define TRACKER(s, d) &(s)->tracker[TRACKER_INDEX(s,d)]
+/**
+ * Add the delta motion to each tracker, then reset the latest tracker to
+ * 0/0 and set it as the current one.
+ */
static inline void
FeedTrackers(DeviceVelocityPtr vel, int dx, int dy, int cur_t)
{
@@ -548,11 +586,9 @@ FeedTrackers(DeviceVelocityPtr vel, int dx, int dy, int cur_t)
* This assumes linear motion.
*/
static float
-CalcTracker(DeviceVelocityPtr vel, int offset, int cur_t){
- int index = TRACKER_INDEX(vel, offset);
- float dist = sqrt( vel->tracker[index].dx * vel->tracker[index].dx
- + vel->tracker[index].dy * vel->tracker[index].dy);
- int dtime = cur_t - vel->tracker[index].time;
+CalcTracker(const MotionTracker *tracker, int cur_t){
+ float dist = sqrt(tracker->dx * tracker->dx + tracker->dy * tracker->dy);
+ int dtime = cur_t - tracker->time;
if(dtime > 0)
return dist / dtime;
else
@@ -560,22 +596,24 @@ CalcTracker(DeviceVelocityPtr vel, int offset, int cur_t){
}
/* find the most plausible velocity. That is, the most distant
- * (in time) tracker which isn't too old, beyond a linear partition,
- * or simply too much off initial velocity.
+ * (in time) tracker which isn't too old, the movement vector was
+ * in the same octant, and where the velocity is within an
+ * acceptable range to the inital velocity.
*
- * May return 0.
+ * @return The tracker's velocity or 0 if the above conditions are unmet
*/
static float
QueryTrackers(DeviceVelocityPtr vel, int cur_t){
- int n, offset, dir = 255, i = -1, age_ms;
+ int offset, dir = UNDEFINED, used_offset = -1, age_ms;
/* initial velocity: a low-offset, valid velocity */
- float iveloc = 0, res = 0, tmp, vdiff;
- float vfac = vel->corr_mul * vel->const_acceleration; /* premultiply */
+ float initial_velocity = 0, result = 0, velocity_diff;
+ float velocity_factor = vel->corr_mul * vel->const_acceleration; /* premultiply */
/* loop from current to older data */
for(offset = 1; offset < vel->num_tracker; offset++){
- n = TRACKER_INDEX(vel, offset);
+ MotionTracker *tracker = TRACKER(vel, offset);
+ float tracker_velocity;
- age_ms = cur_t - vel->tracker[n].time;
+ age_ms = cur_t - tracker->time;
/* bail out if data is too old and protect from overrun */
if (age_ms >= vel->reset_time || age_ms < 0) {
@@ -589,60 +627,60 @@ QueryTrackers(DeviceVelocityPtr vel, int cur_t){
* even more precision we could subdivide as a final step, so possible
* non-linearities are accounted for.
*/
- dir &= vel->tracker[n].dir;
- if(dir == 0){
+ dir &= tracker->dir;
+ if(dir == 0){ /* we've changed octant of movement (e.g. NE → NW) */
DebugAccelF("(dix prtacc) query: no longer linear\n");
/* instead of breaking it we might also inspect the partition after,
* but actual improvement with this is probably rare. */
break;
}
- tmp = CalcTracker(vel, offset, cur_t) * vfac;
+ tracker_velocity = CalcTracker(tracker, cur_t) * velocity_factor;
- if ((iveloc == 0 || offset <= vel->initial_range) && tmp != 0) {
+ if ((initial_velocity == 0 || offset <= vel->initial_range) && tracker_velocity != 0) {
/* set initial velocity and result */
- res = iveloc = tmp;
- i = offset;
- } else if (iveloc != 0 && tmp != 0) {
- vdiff = fabs(iveloc - tmp);
- if (vdiff <= vel->max_diff ||
- vdiff/(iveloc + tmp) < vel->max_rel_diff) {
- /* we're in range with the initial velocity,
- * so this result is likely better
- * (it contains more information). */
- res = tmp;
- i = offset;
- }else{
+ result = initial_velocity = tracker_velocity;
+ used_offset = offset;
+ } else if (initial_velocity != 0 && tracker_velocity != 0) {
+ velocity_diff = fabs(initial_velocity - tracker_velocity);
+
+ if (velocity_diff > vel->max_diff &&
+ velocity_diff/(initial_velocity + tracker_velocity) >= vel->max_rel_diff) {
/* we're not in range, quit - it won't get better. */
DebugAccelF("(dix prtacc) query: tracker too different:"
" old %2.2f initial %2.2f diff: %2.2f\n",
- tmp, iveloc, vdiff);
+ tracker_velocity, initial_velocity, velocity_diff);
break;
}
+ /* we're in range with the initial velocity,
+ * so this result is likely better
+ * (it contains more information). */
+ result = tracker_velocity;
+ used_offset = offset;
}
}
if(offset == vel->num_tracker){
DebugAccelF("(dix prtacc) query: last tracker in effect\n");
- i = vel->num_tracker-1;
+ used_offset = vel->num_tracker-1;
}
- if(i>=0){
- n = TRACKER_INDEX(vel, i);
+#ifdef PTRACCEL_DEBUGGING
+ if(used_offset >= 0){
+ MotionTracker *tracker = TRACKER(vel, used_offset);
DebugAccelF("(dix prtacc) result: offset %i [dx: %i dy: %i diff: %i]\n",
- i,
- vel->tracker[n].dx,
- vel->tracker[n].dy,
- cur_t - vel->tracker[n].time);
+ used_offset, tracker->dx, tracker->dy, cur_t - tracker->time);
}
- return res;
+#endif
+ return result;
}
#undef TRACKER_INDEX
+#undef TRACKER
/**
* Perform velocity approximation based on 2D 'mickeys' (mouse motion delta).
* return true if non-visible state reset is suggested
*/
-short
+BOOL
ProcessVelocityData2D(
DeviceVelocityPtr vel,
int dx,
@@ -666,36 +704,41 @@ ProcessVelocityData2D(
* constant-velocity response
*/
static inline float
-ApplySimpleSoftening(int od, int d)
+ApplySimpleSoftening(int prev_delta, int delta)
{
- float res = d;
- if (d <= 1 && d >= -1)
- return res;
- if (d > od)
- res -= 0.5;
- else if (d < od)
- res += 0.5;
- return res;
+ float result = delta;
+
+ if (delta < -1 || delta > 1) {
+ if (delta > prev_delta)
+ result -= 0.5;
+ else if (delta < prev_delta)
+ result += 0.5;
+ }
+ return result;
}
+/**
+ * Soften the delta based on previous deltas stored in vel.
+ *
+ * @param[in,out] fdx Delta X, modified in-place.
+ * @param[in,out] fdx Delta Y, modified in-place.
+ */
static void
-ApplySofteningAndConstantDeceleration(
+ApplySoftening(
DeviceVelocityPtr vel,
- int dx,
- int dy,
float* fdx,
- float* fdy,
- short do_soften)
+ float* fdy)
{
- if (do_soften && vel->use_softening) {
- *fdx = ApplySimpleSoftening(vel->last_dx, dx);
- *fdy = ApplySimpleSoftening(vel->last_dy, dy);
- } else {
- *fdx = dx;
- *fdy = dy;
+ if (vel->use_softening) {
+ *fdx = ApplySimpleSoftening(vel->last_dx, *fdx);
+ *fdy = ApplySimpleSoftening(vel->last_dy, *fdy);
}
+}
+static void
+ApplyConstantDeceleration(DeviceVelocityPtr vel, float *fdx, float *fdy)
+{
*fdx *= vel->const_acceleration;
*fdy *= vel->const_acceleration;
}
@@ -722,6 +765,8 @@ BasicComputeAcceleration(
/**
* Compute acceleration. Takes into account averaging, nv-reset, etc.
+ * If the velocity has changed, an average is taken of 6 velocity factors:
+ * current velocity, last velocity and 4 times the average between the two.
*/
static float
ComputeAcceleration(
@@ -729,7 +774,7 @@ ComputeAcceleration(
DeviceVelocityPtr vel,
float threshold,
float acc){
- float res;
+ float result;
if(vel->velocity <= 0){
DebugAccelF("(dix ptracc) profile skipped\n");
@@ -744,24 +789,24 @@ ComputeAcceleration(
* current and previous velocity.
* Though being the more natural choice, it causes a minor delay
* in comparison, so it can be disabled. */
- res = BasicComputeAcceleration(
+ result = BasicComputeAcceleration(
dev, vel, vel->velocity, threshold, acc);
- res += BasicComputeAcceleration(
+ result += BasicComputeAcceleration(
dev, vel, vel->last_velocity, threshold, acc);
- res += 4.0f * BasicComputeAcceleration(dev, vel,
+ result += 4.0f * BasicComputeAcceleration(dev, vel,
(vel->last_velocity + vel->velocity) / 2,
threshold, acc);
- res /= 6.0f;
+ result /= 6.0f;
DebugAccelF("(dix ptracc) profile average [%.2f ... %.2f] is %.3f\n",
- vel->velocity, vel->last_velocity, res);
- return res;
+ vel->velocity, vel->last_velocity, result);
}else{
- res = BasicComputeAcceleration(dev, vel,
- vel->velocity, threshold, acc);
+ result = BasicComputeAcceleration(dev, vel,
+ vel->velocity, threshold, acc);
DebugAccelF("(dix ptracc) profile sample [%.2f] is %.3f\n",
vel->velocity, res);
- return res;
}
+
+ return result;
}
@@ -1083,7 +1128,6 @@ acceleratePointerPredictable(
ValuatorMask* val,
CARD32 evtime)
{
- float fdx, fdy, tmp, mult; /* no need to init */
int dx = 0, dy = 0, tmpi;
DeviceVelocityPtr velocitydata = GetDevicePredictableAccelData(dev);
Bool soften = TRUE;
@@ -1111,6 +1155,8 @@ acceleratePointerPredictable(
}
if (dev->ptrfeed && dev->ptrfeed->ctrl.num) {
+ float mult;
+
/* invoke acceleration profile to determine acceleration */
mult = ComputeAcceleration (dev, velocitydata,
dev->ptrfeed->ctrl.threshold,
@@ -1118,12 +1164,17 @@ acceleratePointerPredictable(
(float)dev->ptrfeed->ctrl.den);
if(mult != 1.0f || velocitydata->const_acceleration != 1.0f) {
- ApplySofteningAndConstantDeceleration(velocitydata,
- dx, dy,
- &fdx, &fdy,
- (mult > 1.0f) && soften);
+ float fdx = dx,
+ fdy = dy;
+
+ if (mult > 1.0f && soften)
+ ApplySoftening(velocitydata, &fdx, &fdy);
+ ApplyConstantDeceleration(velocitydata, &fdx, &fdy);
+ /* Calculate the new delta (with accel) and drop it back
+ * into the valuator masks */
if (dx) {
+ float tmp;
tmp = mult * fdx + dev->last.remainder[0];
/* Since it may not be apparent: lrintf() does not offer
* strong statements about rounding; however because we
@@ -1135,6 +1186,7 @@ acceleratePointerPredictable(
dev->last.remainder[0] = tmp - (float)tmpi;
}
if (dy) {
+ float tmp;
tmp = mult * fdy + dev->last.remainder[1];
tmpi = lrintf(tmp);
valuator_mask_set(val, 1, tmpi);
diff --git a/xorg-server/dix/resource.c b/xorg-server/dix/resource.c
index 051c8a245..8950fe2f6 100644
--- a/xorg-server/dix/resource.c
+++ b/xorg-server/dix/resource.c
@@ -490,7 +490,7 @@ AddResource(XID id, RESTYPE type, pointer value)
rrec = &clientTable[client];
if (!rrec->buckets)
{
- ErrorF("[dix] AddResource(%lx, %lx, %lx), client=%d \n",
+ ErrorF("[dix] AddResource(%lx, %x, %lx), client=%d \n",
(unsigned long)id, type, (unsigned long)value, client);
FatalError("client not in use\n");
}
diff --git a/xorg-server/glx/Makefile.am b/xorg-server/glx/Makefile.am
index 41fdf5fc2..f89cb7e35 100644
--- a/xorg-server/glx/Makefile.am
+++ b/xorg-server/glx/Makefile.am
@@ -48,10 +48,13 @@ glapi_sources = \
glthread.h
libglxdri_la_SOURCES = \
- glxdri.c \
extension_string.c \
extension_string.h
+if DRI
+libglxdri_la_SOURCES += glxdri.c
+endif
+
if DRI2_AIGLX
libglxdri_la_SOURCES += glxdri2.c
endif
diff --git a/xorg-server/glx/dispatch.h b/xorg-server/glx/dispatch.h
index 76d72d7a8..e3ade7ba5 100644
--- a/xorg-server/glx/dispatch.h
+++ b/xorg-server/glx/dispatch.h
@@ -58,7 +58,7 @@
} while(0)
/* total number of offsets below */
-#define _gloffset_COUNT 908
+#define _gloffset_COUNT 928
#define _gloffset_NewList 0
#define _gloffset_EndList 1
@@ -689,292 +689,312 @@
#define _gloffset_GetShaderPrecisionFormat 623
#define _gloffset_ReleaseShaderCompiler 624
#define _gloffset_ShaderBinary 625
-#define _gloffset_PolygonOffsetEXT 626
-#define _gloffset_GetPixelTexGenParameterfvSGIS 627
-#define _gloffset_GetPixelTexGenParameterivSGIS 628
-#define _gloffset_PixelTexGenParameterfSGIS 629
-#define _gloffset_PixelTexGenParameterfvSGIS 630
-#define _gloffset_PixelTexGenParameteriSGIS 631
-#define _gloffset_PixelTexGenParameterivSGIS 632
-#define _gloffset_SampleMaskSGIS 633
-#define _gloffset_SamplePatternSGIS 634
-#define _gloffset_ColorPointerEXT 635
-#define _gloffset_EdgeFlagPointerEXT 636
-#define _gloffset_IndexPointerEXT 637
-#define _gloffset_NormalPointerEXT 638
-#define _gloffset_TexCoordPointerEXT 639
-#define _gloffset_VertexPointerEXT 640
-#define _gloffset_PointParameterfEXT 641
-#define _gloffset_PointParameterfvEXT 642
-#define _gloffset_LockArraysEXT 643
-#define _gloffset_UnlockArraysEXT 644
-#define _gloffset_SecondaryColor3bEXT 645
-#define _gloffset_SecondaryColor3bvEXT 646
-#define _gloffset_SecondaryColor3dEXT 647
-#define _gloffset_SecondaryColor3dvEXT 648
-#define _gloffset_SecondaryColor3fEXT 649
-#define _gloffset_SecondaryColor3fvEXT 650
-#define _gloffset_SecondaryColor3iEXT 651
-#define _gloffset_SecondaryColor3ivEXT 652
-#define _gloffset_SecondaryColor3sEXT 653
-#define _gloffset_SecondaryColor3svEXT 654
-#define _gloffset_SecondaryColor3ubEXT 655
-#define _gloffset_SecondaryColor3ubvEXT 656
-#define _gloffset_SecondaryColor3uiEXT 657
-#define _gloffset_SecondaryColor3uivEXT 658
-#define _gloffset_SecondaryColor3usEXT 659
-#define _gloffset_SecondaryColor3usvEXT 660
-#define _gloffset_SecondaryColorPointerEXT 661
-#define _gloffset_MultiDrawArraysEXT 662
-#define _gloffset_MultiDrawElementsEXT 663
-#define _gloffset_FogCoordPointerEXT 664
-#define _gloffset_FogCoorddEXT 665
-#define _gloffset_FogCoorddvEXT 666
-#define _gloffset_FogCoordfEXT 667
-#define _gloffset_FogCoordfvEXT 668
-#define _gloffset_PixelTexGenSGIX 669
-#define _gloffset_BlendFuncSeparateEXT 670
-#define _gloffset_FlushVertexArrayRangeNV 671
-#define _gloffset_VertexArrayRangeNV 672
-#define _gloffset_CombinerInputNV 673
-#define _gloffset_CombinerOutputNV 674
-#define _gloffset_CombinerParameterfNV 675
-#define _gloffset_CombinerParameterfvNV 676
-#define _gloffset_CombinerParameteriNV 677
-#define _gloffset_CombinerParameterivNV 678
-#define _gloffset_FinalCombinerInputNV 679
-#define _gloffset_GetCombinerInputParameterfvNV 680
-#define _gloffset_GetCombinerInputParameterivNV 681
-#define _gloffset_GetCombinerOutputParameterfvNV 682
-#define _gloffset_GetCombinerOutputParameterivNV 683
-#define _gloffset_GetFinalCombinerInputParameterfvNV 684
-#define _gloffset_GetFinalCombinerInputParameterivNV 685
-#define _gloffset_ResizeBuffersMESA 686
-#define _gloffset_WindowPos2dMESA 687
-#define _gloffset_WindowPos2dvMESA 688
-#define _gloffset_WindowPos2fMESA 689
-#define _gloffset_WindowPos2fvMESA 690
-#define _gloffset_WindowPos2iMESA 691
-#define _gloffset_WindowPos2ivMESA 692
-#define _gloffset_WindowPos2sMESA 693
-#define _gloffset_WindowPos2svMESA 694
-#define _gloffset_WindowPos3dMESA 695
-#define _gloffset_WindowPos3dvMESA 696
-#define _gloffset_WindowPos3fMESA 697
-#define _gloffset_WindowPos3fvMESA 698
-#define _gloffset_WindowPos3iMESA 699
-#define _gloffset_WindowPos3ivMESA 700
-#define _gloffset_WindowPos3sMESA 701
-#define _gloffset_WindowPos3svMESA 702
-#define _gloffset_WindowPos4dMESA 703
-#define _gloffset_WindowPos4dvMESA 704
-#define _gloffset_WindowPos4fMESA 705
-#define _gloffset_WindowPos4fvMESA 706
-#define _gloffset_WindowPos4iMESA 707
-#define _gloffset_WindowPos4ivMESA 708
-#define _gloffset_WindowPos4sMESA 709
-#define _gloffset_WindowPos4svMESA 710
-#define _gloffset_MultiModeDrawArraysIBM 711
-#define _gloffset_MultiModeDrawElementsIBM 712
-#define _gloffset_DeleteFencesNV 713
-#define _gloffset_FinishFenceNV 714
-#define _gloffset_GenFencesNV 715
-#define _gloffset_GetFenceivNV 716
-#define _gloffset_IsFenceNV 717
-#define _gloffset_SetFenceNV 718
-#define _gloffset_TestFenceNV 719
-#define _gloffset_AreProgramsResidentNV 720
-#define _gloffset_BindProgramNV 721
-#define _gloffset_DeleteProgramsNV 722
-#define _gloffset_ExecuteProgramNV 723
-#define _gloffset_GenProgramsNV 724
-#define _gloffset_GetProgramParameterdvNV 725
-#define _gloffset_GetProgramParameterfvNV 726
-#define _gloffset_GetProgramStringNV 727
-#define _gloffset_GetProgramivNV 728
-#define _gloffset_GetTrackMatrixivNV 729
-#define _gloffset_GetVertexAttribPointervNV 730
-#define _gloffset_GetVertexAttribdvNV 731
-#define _gloffset_GetVertexAttribfvNV 732
-#define _gloffset_GetVertexAttribivNV 733
-#define _gloffset_IsProgramNV 734
-#define _gloffset_LoadProgramNV 735
-#define _gloffset_ProgramParameters4dvNV 736
-#define _gloffset_ProgramParameters4fvNV 737
-#define _gloffset_RequestResidentProgramsNV 738
-#define _gloffset_TrackMatrixNV 739
-#define _gloffset_VertexAttrib1dNV 740
-#define _gloffset_VertexAttrib1dvNV 741
-#define _gloffset_VertexAttrib1fNV 742
-#define _gloffset_VertexAttrib1fvNV 743
-#define _gloffset_VertexAttrib1sNV 744
-#define _gloffset_VertexAttrib1svNV 745
-#define _gloffset_VertexAttrib2dNV 746
-#define _gloffset_VertexAttrib2dvNV 747
-#define _gloffset_VertexAttrib2fNV 748
-#define _gloffset_VertexAttrib2fvNV 749
-#define _gloffset_VertexAttrib2sNV 750
-#define _gloffset_VertexAttrib2svNV 751
-#define _gloffset_VertexAttrib3dNV 752
-#define _gloffset_VertexAttrib3dvNV 753
-#define _gloffset_VertexAttrib3fNV 754
-#define _gloffset_VertexAttrib3fvNV 755
-#define _gloffset_VertexAttrib3sNV 756
-#define _gloffset_VertexAttrib3svNV 757
-#define _gloffset_VertexAttrib4dNV 758
-#define _gloffset_VertexAttrib4dvNV 759
-#define _gloffset_VertexAttrib4fNV 760
-#define _gloffset_VertexAttrib4fvNV 761
-#define _gloffset_VertexAttrib4sNV 762
-#define _gloffset_VertexAttrib4svNV 763
-#define _gloffset_VertexAttrib4ubNV 764
-#define _gloffset_VertexAttrib4ubvNV 765
-#define _gloffset_VertexAttribPointerNV 766
-#define _gloffset_VertexAttribs1dvNV 767
-#define _gloffset_VertexAttribs1fvNV 768
-#define _gloffset_VertexAttribs1svNV 769
-#define _gloffset_VertexAttribs2dvNV 770
-#define _gloffset_VertexAttribs2fvNV 771
-#define _gloffset_VertexAttribs2svNV 772
-#define _gloffset_VertexAttribs3dvNV 773
-#define _gloffset_VertexAttribs3fvNV 774
-#define _gloffset_VertexAttribs3svNV 775
-#define _gloffset_VertexAttribs4dvNV 776
-#define _gloffset_VertexAttribs4fvNV 777
-#define _gloffset_VertexAttribs4svNV 778
-#define _gloffset_VertexAttribs4ubvNV 779
-#define _gloffset_GetTexBumpParameterfvATI 780
-#define _gloffset_GetTexBumpParameterivATI 781
-#define _gloffset_TexBumpParameterfvATI 782
-#define _gloffset_TexBumpParameterivATI 783
-#define _gloffset_AlphaFragmentOp1ATI 784
-#define _gloffset_AlphaFragmentOp2ATI 785
-#define _gloffset_AlphaFragmentOp3ATI 786
-#define _gloffset_BeginFragmentShaderATI 787
-#define _gloffset_BindFragmentShaderATI 788
-#define _gloffset_ColorFragmentOp1ATI 789
-#define _gloffset_ColorFragmentOp2ATI 790
-#define _gloffset_ColorFragmentOp3ATI 791
-#define _gloffset_DeleteFragmentShaderATI 792
-#define _gloffset_EndFragmentShaderATI 793
-#define _gloffset_GenFragmentShadersATI 794
-#define _gloffset_PassTexCoordATI 795
-#define _gloffset_SampleMapATI 796
-#define _gloffset_SetFragmentShaderConstantATI 797
-#define _gloffset_PointParameteriNV 798
-#define _gloffset_PointParameterivNV 799
-#define _gloffset_ActiveStencilFaceEXT 800
-#define _gloffset_BindVertexArrayAPPLE 801
-#define _gloffset_DeleteVertexArraysAPPLE 802
-#define _gloffset_GenVertexArraysAPPLE 803
-#define _gloffset_IsVertexArrayAPPLE 804
-#define _gloffset_GetProgramNamedParameterdvNV 805
-#define _gloffset_GetProgramNamedParameterfvNV 806
-#define _gloffset_ProgramNamedParameter4dNV 807
-#define _gloffset_ProgramNamedParameter4dvNV 808
-#define _gloffset_ProgramNamedParameter4fNV 809
-#define _gloffset_ProgramNamedParameter4fvNV 810
-#define _gloffset_PrimitiveRestartIndexNV 811
-#define _gloffset_PrimitiveRestartNV 812
-#define _gloffset_DepthBoundsEXT 813
-#define _gloffset_BlendEquationSeparateEXT 814
-#define _gloffset_BindFramebufferEXT 815
-#define _gloffset_BindRenderbufferEXT 816
-#define _gloffset_CheckFramebufferStatusEXT 817
-#define _gloffset_DeleteFramebuffersEXT 818
-#define _gloffset_DeleteRenderbuffersEXT 819
-#define _gloffset_FramebufferRenderbufferEXT 820
-#define _gloffset_FramebufferTexture1DEXT 821
-#define _gloffset_FramebufferTexture2DEXT 822
-#define _gloffset_FramebufferTexture3DEXT 823
-#define _gloffset_GenFramebuffersEXT 824
-#define _gloffset_GenRenderbuffersEXT 825
-#define _gloffset_GenerateMipmapEXT 826
-#define _gloffset_GetFramebufferAttachmentParameterivEXT 827
-#define _gloffset_GetRenderbufferParameterivEXT 828
-#define _gloffset_IsFramebufferEXT 829
-#define _gloffset_IsRenderbufferEXT 830
-#define _gloffset_RenderbufferStorageEXT 831
-#define _gloffset_BlitFramebufferEXT 832
-#define _gloffset_BufferParameteriAPPLE 833
-#define _gloffset_FlushMappedBufferRangeAPPLE 834
-#define _gloffset_BindFragDataLocationEXT 835
-#define _gloffset_GetFragDataLocationEXT 836
-#define _gloffset_GetUniformuivEXT 837
-#define _gloffset_GetVertexAttribIivEXT 838
-#define _gloffset_GetVertexAttribIuivEXT 839
-#define _gloffset_Uniform1uiEXT 840
-#define _gloffset_Uniform1uivEXT 841
-#define _gloffset_Uniform2uiEXT 842
-#define _gloffset_Uniform2uivEXT 843
-#define _gloffset_Uniform3uiEXT 844
-#define _gloffset_Uniform3uivEXT 845
-#define _gloffset_Uniform4uiEXT 846
-#define _gloffset_Uniform4uivEXT 847
-#define _gloffset_VertexAttribI1iEXT 848
-#define _gloffset_VertexAttribI1ivEXT 849
-#define _gloffset_VertexAttribI1uiEXT 850
-#define _gloffset_VertexAttribI1uivEXT 851
-#define _gloffset_VertexAttribI2iEXT 852
-#define _gloffset_VertexAttribI2ivEXT 853
-#define _gloffset_VertexAttribI2uiEXT 854
-#define _gloffset_VertexAttribI2uivEXT 855
-#define _gloffset_VertexAttribI3iEXT 856
-#define _gloffset_VertexAttribI3ivEXT 857
-#define _gloffset_VertexAttribI3uiEXT 858
-#define _gloffset_VertexAttribI3uivEXT 859
-#define _gloffset_VertexAttribI4bvEXT 860
-#define _gloffset_VertexAttribI4iEXT 861
-#define _gloffset_VertexAttribI4ivEXT 862
-#define _gloffset_VertexAttribI4svEXT 863
-#define _gloffset_VertexAttribI4ubvEXT 864
-#define _gloffset_VertexAttribI4uiEXT 865
-#define _gloffset_VertexAttribI4uivEXT 866
-#define _gloffset_VertexAttribI4usvEXT 867
-#define _gloffset_VertexAttribIPointerEXT 868
-#define _gloffset_FramebufferTextureLayerEXT 869
-#define _gloffset_ColorMaskIndexedEXT 870
-#define _gloffset_DisableIndexedEXT 871
-#define _gloffset_EnableIndexedEXT 872
-#define _gloffset_GetBooleanIndexedvEXT 873
-#define _gloffset_GetIntegerIndexedvEXT 874
-#define _gloffset_IsEnabledIndexedEXT 875
-#define _gloffset_ClearColorIiEXT 876
-#define _gloffset_ClearColorIuiEXT 877
-#define _gloffset_GetTexParameterIivEXT 878
-#define _gloffset_GetTexParameterIuivEXT 879
-#define _gloffset_TexParameterIivEXT 880
-#define _gloffset_TexParameterIuivEXT 881
-#define _gloffset_BeginConditionalRenderNV 882
-#define _gloffset_EndConditionalRenderNV 883
-#define _gloffset_BeginTransformFeedbackEXT 884
-#define _gloffset_BindBufferBaseEXT 885
-#define _gloffset_BindBufferOffsetEXT 886
-#define _gloffset_BindBufferRangeEXT 887
-#define _gloffset_EndTransformFeedbackEXT 888
-#define _gloffset_GetTransformFeedbackVaryingEXT 889
-#define _gloffset_TransformFeedbackVaryingsEXT 890
-#define _gloffset_ProvokingVertexEXT 891
-#define _gloffset_GetTexParameterPointervAPPLE 892
-#define _gloffset_TextureRangeAPPLE 893
-#define _gloffset_GetObjectParameterivAPPLE 894
-#define _gloffset_ObjectPurgeableAPPLE 895
-#define _gloffset_ObjectUnpurgeableAPPLE 896
-#define _gloffset_ActiveProgramEXT 897
-#define _gloffset_CreateShaderProgramEXT 898
-#define _gloffset_UseShaderProgramEXT 899
-#define _gloffset_TextureBarrierNV 900
-#define _gloffset_StencilFuncSeparateATI 901
-#define _gloffset_ProgramEnvParameters4fvEXT 902
-#define _gloffset_ProgramLocalParameters4fvEXT 903
-#define _gloffset_GetQueryObjecti64vEXT 904
-#define _gloffset_GetQueryObjectui64vEXT 905
-#define _gloffset_EGLImageTargetRenderbufferStorageOES 906
-#define _gloffset_EGLImageTargetTexture2DOES 907
+#define _gloffset_GetGraphicsResetStatusARB 626
+#define _gloffset_GetnColorTableARB 627
+#define _gloffset_GetnCompressedTexImageARB 628
+#define _gloffset_GetnConvolutionFilterARB 629
+#define _gloffset_GetnHistogramARB 630
+#define _gloffset_GetnMapdvARB 631
+#define _gloffset_GetnMapfvARB 632
+#define _gloffset_GetnMapivARB 633
+#define _gloffset_GetnMinmaxARB 634
+#define _gloffset_GetnPixelMapfvARB 635
+#define _gloffset_GetnPixelMapuivARB 636
+#define _gloffset_GetnPixelMapusvARB 637
+#define _gloffset_GetnPolygonStippleARB 638
+#define _gloffset_GetnSeparableFilterARB 639
+#define _gloffset_GetnTexImageARB 640
+#define _gloffset_GetnUniformdvARB 641
+#define _gloffset_GetnUniformfvARB 642
+#define _gloffset_GetnUniformivARB 643
+#define _gloffset_GetnUniformuivARB 644
+#define _gloffset_ReadnPixelsARB 645
+#define _gloffset_PolygonOffsetEXT 646
+#define _gloffset_GetPixelTexGenParameterfvSGIS 647
+#define _gloffset_GetPixelTexGenParameterivSGIS 648
+#define _gloffset_PixelTexGenParameterfSGIS 649
+#define _gloffset_PixelTexGenParameterfvSGIS 650
+#define _gloffset_PixelTexGenParameteriSGIS 651
+#define _gloffset_PixelTexGenParameterivSGIS 652
+#define _gloffset_SampleMaskSGIS 653
+#define _gloffset_SamplePatternSGIS 654
+#define _gloffset_ColorPointerEXT 655
+#define _gloffset_EdgeFlagPointerEXT 656
+#define _gloffset_IndexPointerEXT 657
+#define _gloffset_NormalPointerEXT 658
+#define _gloffset_TexCoordPointerEXT 659
+#define _gloffset_VertexPointerEXT 660
+#define _gloffset_PointParameterfEXT 661
+#define _gloffset_PointParameterfvEXT 662
+#define _gloffset_LockArraysEXT 663
+#define _gloffset_UnlockArraysEXT 664
+#define _gloffset_SecondaryColor3bEXT 665
+#define _gloffset_SecondaryColor3bvEXT 666
+#define _gloffset_SecondaryColor3dEXT 667
+#define _gloffset_SecondaryColor3dvEXT 668
+#define _gloffset_SecondaryColor3fEXT 669
+#define _gloffset_SecondaryColor3fvEXT 670
+#define _gloffset_SecondaryColor3iEXT 671
+#define _gloffset_SecondaryColor3ivEXT 672
+#define _gloffset_SecondaryColor3sEXT 673
+#define _gloffset_SecondaryColor3svEXT 674
+#define _gloffset_SecondaryColor3ubEXT 675
+#define _gloffset_SecondaryColor3ubvEXT 676
+#define _gloffset_SecondaryColor3uiEXT 677
+#define _gloffset_SecondaryColor3uivEXT 678
+#define _gloffset_SecondaryColor3usEXT 679
+#define _gloffset_SecondaryColor3usvEXT 680
+#define _gloffset_SecondaryColorPointerEXT 681
+#define _gloffset_MultiDrawArraysEXT 682
+#define _gloffset_MultiDrawElementsEXT 683
+#define _gloffset_FogCoordPointerEXT 684
+#define _gloffset_FogCoorddEXT 685
+#define _gloffset_FogCoorddvEXT 686
+#define _gloffset_FogCoordfEXT 687
+#define _gloffset_FogCoordfvEXT 688
+#define _gloffset_PixelTexGenSGIX 689
+#define _gloffset_BlendFuncSeparateEXT 690
+#define _gloffset_FlushVertexArrayRangeNV 691
+#define _gloffset_VertexArrayRangeNV 692
+#define _gloffset_CombinerInputNV 693
+#define _gloffset_CombinerOutputNV 694
+#define _gloffset_CombinerParameterfNV 695
+#define _gloffset_CombinerParameterfvNV 696
+#define _gloffset_CombinerParameteriNV 697
+#define _gloffset_CombinerParameterivNV 698
+#define _gloffset_FinalCombinerInputNV 699
+#define _gloffset_GetCombinerInputParameterfvNV 700
+#define _gloffset_GetCombinerInputParameterivNV 701
+#define _gloffset_GetCombinerOutputParameterfvNV 702
+#define _gloffset_GetCombinerOutputParameterivNV 703
+#define _gloffset_GetFinalCombinerInputParameterfvNV 704
+#define _gloffset_GetFinalCombinerInputParameterivNV 705
+#define _gloffset_ResizeBuffersMESA 706
+#define _gloffset_WindowPos2dMESA 707
+#define _gloffset_WindowPos2dvMESA 708
+#define _gloffset_WindowPos2fMESA 709
+#define _gloffset_WindowPos2fvMESA 710
+#define _gloffset_WindowPos2iMESA 711
+#define _gloffset_WindowPos2ivMESA 712
+#define _gloffset_WindowPos2sMESA 713
+#define _gloffset_WindowPos2svMESA 714
+#define _gloffset_WindowPos3dMESA 715
+#define _gloffset_WindowPos3dvMESA 716
+#define _gloffset_WindowPos3fMESA 717
+#define _gloffset_WindowPos3fvMESA 718
+#define _gloffset_WindowPos3iMESA 719
+#define _gloffset_WindowPos3ivMESA 720
+#define _gloffset_WindowPos3sMESA 721
+#define _gloffset_WindowPos3svMESA 722
+#define _gloffset_WindowPos4dMESA 723
+#define _gloffset_WindowPos4dvMESA 724
+#define _gloffset_WindowPos4fMESA 725
+#define _gloffset_WindowPos4fvMESA 726
+#define _gloffset_WindowPos4iMESA 727
+#define _gloffset_WindowPos4ivMESA 728
+#define _gloffset_WindowPos4sMESA 729
+#define _gloffset_WindowPos4svMESA 730
+#define _gloffset_MultiModeDrawArraysIBM 731
+#define _gloffset_MultiModeDrawElementsIBM 732
+#define _gloffset_DeleteFencesNV 733
+#define _gloffset_FinishFenceNV 734
+#define _gloffset_GenFencesNV 735
+#define _gloffset_GetFenceivNV 736
+#define _gloffset_IsFenceNV 737
+#define _gloffset_SetFenceNV 738
+#define _gloffset_TestFenceNV 739
+#define _gloffset_AreProgramsResidentNV 740
+#define _gloffset_BindProgramNV 741
+#define _gloffset_DeleteProgramsNV 742
+#define _gloffset_ExecuteProgramNV 743
+#define _gloffset_GenProgramsNV 744
+#define _gloffset_GetProgramParameterdvNV 745
+#define _gloffset_GetProgramParameterfvNV 746
+#define _gloffset_GetProgramStringNV 747
+#define _gloffset_GetProgramivNV 748
+#define _gloffset_GetTrackMatrixivNV 749
+#define _gloffset_GetVertexAttribPointervNV 750
+#define _gloffset_GetVertexAttribdvNV 751
+#define _gloffset_GetVertexAttribfvNV 752
+#define _gloffset_GetVertexAttribivNV 753
+#define _gloffset_IsProgramNV 754
+#define _gloffset_LoadProgramNV 755
+#define _gloffset_ProgramParameters4dvNV 756
+#define _gloffset_ProgramParameters4fvNV 757
+#define _gloffset_RequestResidentProgramsNV 758
+#define _gloffset_TrackMatrixNV 759
+#define _gloffset_VertexAttrib1dNV 760
+#define _gloffset_VertexAttrib1dvNV 761
+#define _gloffset_VertexAttrib1fNV 762
+#define _gloffset_VertexAttrib1fvNV 763
+#define _gloffset_VertexAttrib1sNV 764
+#define _gloffset_VertexAttrib1svNV 765
+#define _gloffset_VertexAttrib2dNV 766
+#define _gloffset_VertexAttrib2dvNV 767
+#define _gloffset_VertexAttrib2fNV 768
+#define _gloffset_VertexAttrib2fvNV 769
+#define _gloffset_VertexAttrib2sNV 770
+#define _gloffset_VertexAttrib2svNV 771
+#define _gloffset_VertexAttrib3dNV 772
+#define _gloffset_VertexAttrib3dvNV 773
+#define _gloffset_VertexAttrib3fNV 774
+#define _gloffset_VertexAttrib3fvNV 775
+#define _gloffset_VertexAttrib3sNV 776
+#define _gloffset_VertexAttrib3svNV 777
+#define _gloffset_VertexAttrib4dNV 778
+#define _gloffset_VertexAttrib4dvNV 779
+#define _gloffset_VertexAttrib4fNV 780
+#define _gloffset_VertexAttrib4fvNV 781
+#define _gloffset_VertexAttrib4sNV 782
+#define _gloffset_VertexAttrib4svNV 783
+#define _gloffset_VertexAttrib4ubNV 784
+#define _gloffset_VertexAttrib4ubvNV 785
+#define _gloffset_VertexAttribPointerNV 786
+#define _gloffset_VertexAttribs1dvNV 787
+#define _gloffset_VertexAttribs1fvNV 788
+#define _gloffset_VertexAttribs1svNV 789
+#define _gloffset_VertexAttribs2dvNV 790
+#define _gloffset_VertexAttribs2fvNV 791
+#define _gloffset_VertexAttribs2svNV 792
+#define _gloffset_VertexAttribs3dvNV 793
+#define _gloffset_VertexAttribs3fvNV 794
+#define _gloffset_VertexAttribs3svNV 795
+#define _gloffset_VertexAttribs4dvNV 796
+#define _gloffset_VertexAttribs4fvNV 797
+#define _gloffset_VertexAttribs4svNV 798
+#define _gloffset_VertexAttribs4ubvNV 799
+#define _gloffset_GetTexBumpParameterfvATI 800
+#define _gloffset_GetTexBumpParameterivATI 801
+#define _gloffset_TexBumpParameterfvATI 802
+#define _gloffset_TexBumpParameterivATI 803
+#define _gloffset_AlphaFragmentOp1ATI 804
+#define _gloffset_AlphaFragmentOp2ATI 805
+#define _gloffset_AlphaFragmentOp3ATI 806
+#define _gloffset_BeginFragmentShaderATI 807
+#define _gloffset_BindFragmentShaderATI 808
+#define _gloffset_ColorFragmentOp1ATI 809
+#define _gloffset_ColorFragmentOp2ATI 810
+#define _gloffset_ColorFragmentOp3ATI 811
+#define _gloffset_DeleteFragmentShaderATI 812
+#define _gloffset_EndFragmentShaderATI 813
+#define _gloffset_GenFragmentShadersATI 814
+#define _gloffset_PassTexCoordATI 815
+#define _gloffset_SampleMapATI 816
+#define _gloffset_SetFragmentShaderConstantATI 817
+#define _gloffset_PointParameteriNV 818
+#define _gloffset_PointParameterivNV 819
+#define _gloffset_ActiveStencilFaceEXT 820
+#define _gloffset_BindVertexArrayAPPLE 821
+#define _gloffset_DeleteVertexArraysAPPLE 822
+#define _gloffset_GenVertexArraysAPPLE 823
+#define _gloffset_IsVertexArrayAPPLE 824
+#define _gloffset_GetProgramNamedParameterdvNV 825
+#define _gloffset_GetProgramNamedParameterfvNV 826
+#define _gloffset_ProgramNamedParameter4dNV 827
+#define _gloffset_ProgramNamedParameter4dvNV 828
+#define _gloffset_ProgramNamedParameter4fNV 829
+#define _gloffset_ProgramNamedParameter4fvNV 830
+#define _gloffset_PrimitiveRestartIndexNV 831
+#define _gloffset_PrimitiveRestartNV 832
+#define _gloffset_DepthBoundsEXT 833
+#define _gloffset_BlendEquationSeparateEXT 834
+#define _gloffset_BindFramebufferEXT 835
+#define _gloffset_BindRenderbufferEXT 836
+#define _gloffset_CheckFramebufferStatusEXT 837
+#define _gloffset_DeleteFramebuffersEXT 838
+#define _gloffset_DeleteRenderbuffersEXT 839
+#define _gloffset_FramebufferRenderbufferEXT 840
+#define _gloffset_FramebufferTexture1DEXT 841
+#define _gloffset_FramebufferTexture2DEXT 842
+#define _gloffset_FramebufferTexture3DEXT 843
+#define _gloffset_GenFramebuffersEXT 844
+#define _gloffset_GenRenderbuffersEXT 845
+#define _gloffset_GenerateMipmapEXT 846
+#define _gloffset_GetFramebufferAttachmentParameterivEXT 847
+#define _gloffset_GetRenderbufferParameterivEXT 848
+#define _gloffset_IsFramebufferEXT 849
+#define _gloffset_IsRenderbufferEXT 850
+#define _gloffset_RenderbufferStorageEXT 851
+#define _gloffset_BlitFramebufferEXT 852
+#define _gloffset_BufferParameteriAPPLE 853
+#define _gloffset_FlushMappedBufferRangeAPPLE 854
+#define _gloffset_BindFragDataLocationEXT 855
+#define _gloffset_GetFragDataLocationEXT 856
+#define _gloffset_GetUniformuivEXT 857
+#define _gloffset_GetVertexAttribIivEXT 858
+#define _gloffset_GetVertexAttribIuivEXT 859
+#define _gloffset_Uniform1uiEXT 860
+#define _gloffset_Uniform1uivEXT 861
+#define _gloffset_Uniform2uiEXT 862
+#define _gloffset_Uniform2uivEXT 863
+#define _gloffset_Uniform3uiEXT 864
+#define _gloffset_Uniform3uivEXT 865
+#define _gloffset_Uniform4uiEXT 866
+#define _gloffset_Uniform4uivEXT 867
+#define _gloffset_VertexAttribI1iEXT 868
+#define _gloffset_VertexAttribI1ivEXT 869
+#define _gloffset_VertexAttribI1uiEXT 870
+#define _gloffset_VertexAttribI1uivEXT 871
+#define _gloffset_VertexAttribI2iEXT 872
+#define _gloffset_VertexAttribI2ivEXT 873
+#define _gloffset_VertexAttribI2uiEXT 874
+#define _gloffset_VertexAttribI2uivEXT 875
+#define _gloffset_VertexAttribI3iEXT 876
+#define _gloffset_VertexAttribI3ivEXT 877
+#define _gloffset_VertexAttribI3uiEXT 878
+#define _gloffset_VertexAttribI3uivEXT 879
+#define _gloffset_VertexAttribI4bvEXT 880
+#define _gloffset_VertexAttribI4iEXT 881
+#define _gloffset_VertexAttribI4ivEXT 882
+#define _gloffset_VertexAttribI4svEXT 883
+#define _gloffset_VertexAttribI4ubvEXT 884
+#define _gloffset_VertexAttribI4uiEXT 885
+#define _gloffset_VertexAttribI4uivEXT 886
+#define _gloffset_VertexAttribI4usvEXT 887
+#define _gloffset_VertexAttribIPointerEXT 888
+#define _gloffset_FramebufferTextureLayerEXT 889
+#define _gloffset_ColorMaskIndexedEXT 890
+#define _gloffset_DisableIndexedEXT 891
+#define _gloffset_EnableIndexedEXT 892
+#define _gloffset_GetBooleanIndexedvEXT 893
+#define _gloffset_GetIntegerIndexedvEXT 894
+#define _gloffset_IsEnabledIndexedEXT 895
+#define _gloffset_ClearColorIiEXT 896
+#define _gloffset_ClearColorIuiEXT 897
+#define _gloffset_GetTexParameterIivEXT 898
+#define _gloffset_GetTexParameterIuivEXT 899
+#define _gloffset_TexParameterIivEXT 900
+#define _gloffset_TexParameterIuivEXT 901
+#define _gloffset_BeginConditionalRenderNV 902
+#define _gloffset_EndConditionalRenderNV 903
+#define _gloffset_BeginTransformFeedbackEXT 904
+#define _gloffset_BindBufferBaseEXT 905
+#define _gloffset_BindBufferOffsetEXT 906
+#define _gloffset_BindBufferRangeEXT 907
+#define _gloffset_EndTransformFeedbackEXT 908
+#define _gloffset_GetTransformFeedbackVaryingEXT 909
+#define _gloffset_TransformFeedbackVaryingsEXT 910
+#define _gloffset_ProvokingVertexEXT 911
+#define _gloffset_GetTexParameterPointervAPPLE 912
+#define _gloffset_TextureRangeAPPLE 913
+#define _gloffset_GetObjectParameterivAPPLE 914
+#define _gloffset_ObjectPurgeableAPPLE 915
+#define _gloffset_ObjectUnpurgeableAPPLE 916
+#define _gloffset_ActiveProgramEXT 917
+#define _gloffset_CreateShaderProgramEXT 918
+#define _gloffset_UseShaderProgramEXT 919
+#define _gloffset_TextureBarrierNV 920
+#define _gloffset_StencilFuncSeparateATI 921
+#define _gloffset_ProgramEnvParameters4fvEXT 922
+#define _gloffset_ProgramLocalParameters4fvEXT 923
+#define _gloffset_GetQueryObjecti64vEXT 924
+#define _gloffset_GetQueryObjectui64vEXT 925
+#define _gloffset_EGLImageTargetRenderbufferStorageOES 926
+#define _gloffset_EGLImageTargetTexture2DOES 927
#else /* !_GLAPI_USE_REMAP_TABLE */
-#define driDispatchRemapTable_size 500
+#define driDispatchRemapTable_size 520
extern int driDispatchRemapTable[ driDispatchRemapTable_size ];
#define AttachShader_remap_index 0
@@ -1195,288 +1215,308 @@ extern int driDispatchRemapTable[ driDispatchRemapTable_size ];
#define GetShaderPrecisionFormat_remap_index 215
#define ReleaseShaderCompiler_remap_index 216
#define ShaderBinary_remap_index 217
-#define PolygonOffsetEXT_remap_index 218
-#define GetPixelTexGenParameterfvSGIS_remap_index 219
-#define GetPixelTexGenParameterivSGIS_remap_index 220
-#define PixelTexGenParameterfSGIS_remap_index 221
-#define PixelTexGenParameterfvSGIS_remap_index 222
-#define PixelTexGenParameteriSGIS_remap_index 223
-#define PixelTexGenParameterivSGIS_remap_index 224
-#define SampleMaskSGIS_remap_index 225
-#define SamplePatternSGIS_remap_index 226
-#define ColorPointerEXT_remap_index 227
-#define EdgeFlagPointerEXT_remap_index 228
-#define IndexPointerEXT_remap_index 229
-#define NormalPointerEXT_remap_index 230
-#define TexCoordPointerEXT_remap_index 231
-#define VertexPointerEXT_remap_index 232
-#define PointParameterfEXT_remap_index 233
-#define PointParameterfvEXT_remap_index 234
-#define LockArraysEXT_remap_index 235
-#define UnlockArraysEXT_remap_index 236
-#define SecondaryColor3bEXT_remap_index 237
-#define SecondaryColor3bvEXT_remap_index 238
-#define SecondaryColor3dEXT_remap_index 239
-#define SecondaryColor3dvEXT_remap_index 240
-#define SecondaryColor3fEXT_remap_index 241
-#define SecondaryColor3fvEXT_remap_index 242
-#define SecondaryColor3iEXT_remap_index 243
-#define SecondaryColor3ivEXT_remap_index 244
-#define SecondaryColor3sEXT_remap_index 245
-#define SecondaryColor3svEXT_remap_index 246
-#define SecondaryColor3ubEXT_remap_index 247
-#define SecondaryColor3ubvEXT_remap_index 248
-#define SecondaryColor3uiEXT_remap_index 249
-#define SecondaryColor3uivEXT_remap_index 250
-#define SecondaryColor3usEXT_remap_index 251
-#define SecondaryColor3usvEXT_remap_index 252
-#define SecondaryColorPointerEXT_remap_index 253
-#define MultiDrawArraysEXT_remap_index 254
-#define MultiDrawElementsEXT_remap_index 255
-#define FogCoordPointerEXT_remap_index 256
-#define FogCoorddEXT_remap_index 257
-#define FogCoorddvEXT_remap_index 258
-#define FogCoordfEXT_remap_index 259
-#define FogCoordfvEXT_remap_index 260
-#define PixelTexGenSGIX_remap_index 261
-#define BlendFuncSeparateEXT_remap_index 262
-#define FlushVertexArrayRangeNV_remap_index 263
-#define VertexArrayRangeNV_remap_index 264
-#define CombinerInputNV_remap_index 265
-#define CombinerOutputNV_remap_index 266
-#define CombinerParameterfNV_remap_index 267
-#define CombinerParameterfvNV_remap_index 268
-#define CombinerParameteriNV_remap_index 269
-#define CombinerParameterivNV_remap_index 270
-#define FinalCombinerInputNV_remap_index 271
-#define GetCombinerInputParameterfvNV_remap_index 272
-#define GetCombinerInputParameterivNV_remap_index 273
-#define GetCombinerOutputParameterfvNV_remap_index 274
-#define GetCombinerOutputParameterivNV_remap_index 275
-#define GetFinalCombinerInputParameterfvNV_remap_index 276
-#define GetFinalCombinerInputParameterivNV_remap_index 277
-#define ResizeBuffersMESA_remap_index 278
-#define WindowPos2dMESA_remap_index 279
-#define WindowPos2dvMESA_remap_index 280
-#define WindowPos2fMESA_remap_index 281
-#define WindowPos2fvMESA_remap_index 282
-#define WindowPos2iMESA_remap_index 283
-#define WindowPos2ivMESA_remap_index 284
-#define WindowPos2sMESA_remap_index 285
-#define WindowPos2svMESA_remap_index 286
-#define WindowPos3dMESA_remap_index 287
-#define WindowPos3dvMESA_remap_index 288
-#define WindowPos3fMESA_remap_index 289
-#define WindowPos3fvMESA_remap_index 290
-#define WindowPos3iMESA_remap_index 291
-#define WindowPos3ivMESA_remap_index 292
-#define WindowPos3sMESA_remap_index 293
-#define WindowPos3svMESA_remap_index 294
-#define WindowPos4dMESA_remap_index 295
-#define WindowPos4dvMESA_remap_index 296
-#define WindowPos4fMESA_remap_index 297
-#define WindowPos4fvMESA_remap_index 298
-#define WindowPos4iMESA_remap_index 299
-#define WindowPos4ivMESA_remap_index 300
-#define WindowPos4sMESA_remap_index 301
-#define WindowPos4svMESA_remap_index 302
-#define MultiModeDrawArraysIBM_remap_index 303
-#define MultiModeDrawElementsIBM_remap_index 304
-#define DeleteFencesNV_remap_index 305
-#define FinishFenceNV_remap_index 306
-#define GenFencesNV_remap_index 307
-#define GetFenceivNV_remap_index 308
-#define IsFenceNV_remap_index 309
-#define SetFenceNV_remap_index 310
-#define TestFenceNV_remap_index 311
-#define AreProgramsResidentNV_remap_index 312
-#define BindProgramNV_remap_index 313
-#define DeleteProgramsNV_remap_index 314
-#define ExecuteProgramNV_remap_index 315
-#define GenProgramsNV_remap_index 316
-#define GetProgramParameterdvNV_remap_index 317
-#define GetProgramParameterfvNV_remap_index 318
-#define GetProgramStringNV_remap_index 319
-#define GetProgramivNV_remap_index 320
-#define GetTrackMatrixivNV_remap_index 321
-#define GetVertexAttribPointervNV_remap_index 322
-#define GetVertexAttribdvNV_remap_index 323
-#define GetVertexAttribfvNV_remap_index 324
-#define GetVertexAttribivNV_remap_index 325
-#define IsProgramNV_remap_index 326
-#define LoadProgramNV_remap_index 327
-#define ProgramParameters4dvNV_remap_index 328
-#define ProgramParameters4fvNV_remap_index 329
-#define RequestResidentProgramsNV_remap_index 330
-#define TrackMatrixNV_remap_index 331
-#define VertexAttrib1dNV_remap_index 332
-#define VertexAttrib1dvNV_remap_index 333
-#define VertexAttrib1fNV_remap_index 334
-#define VertexAttrib1fvNV_remap_index 335
-#define VertexAttrib1sNV_remap_index 336
-#define VertexAttrib1svNV_remap_index 337
-#define VertexAttrib2dNV_remap_index 338
-#define VertexAttrib2dvNV_remap_index 339
-#define VertexAttrib2fNV_remap_index 340
-#define VertexAttrib2fvNV_remap_index 341
-#define VertexAttrib2sNV_remap_index 342
-#define VertexAttrib2svNV_remap_index 343
-#define VertexAttrib3dNV_remap_index 344
-#define VertexAttrib3dvNV_remap_index 345
-#define VertexAttrib3fNV_remap_index 346
-#define VertexAttrib3fvNV_remap_index 347
-#define VertexAttrib3sNV_remap_index 348
-#define VertexAttrib3svNV_remap_index 349
-#define VertexAttrib4dNV_remap_index 350
-#define VertexAttrib4dvNV_remap_index 351
-#define VertexAttrib4fNV_remap_index 352
-#define VertexAttrib4fvNV_remap_index 353
-#define VertexAttrib4sNV_remap_index 354
-#define VertexAttrib4svNV_remap_index 355
-#define VertexAttrib4ubNV_remap_index 356
-#define VertexAttrib4ubvNV_remap_index 357
-#define VertexAttribPointerNV_remap_index 358
-#define VertexAttribs1dvNV_remap_index 359
-#define VertexAttribs1fvNV_remap_index 360
-#define VertexAttribs1svNV_remap_index 361
-#define VertexAttribs2dvNV_remap_index 362
-#define VertexAttribs2fvNV_remap_index 363
-#define VertexAttribs2svNV_remap_index 364
-#define VertexAttribs3dvNV_remap_index 365
-#define VertexAttribs3fvNV_remap_index 366
-#define VertexAttribs3svNV_remap_index 367
-#define VertexAttribs4dvNV_remap_index 368
-#define VertexAttribs4fvNV_remap_index 369
-#define VertexAttribs4svNV_remap_index 370
-#define VertexAttribs4ubvNV_remap_index 371
-#define GetTexBumpParameterfvATI_remap_index 372
-#define GetTexBumpParameterivATI_remap_index 373
-#define TexBumpParameterfvATI_remap_index 374
-#define TexBumpParameterivATI_remap_index 375
-#define AlphaFragmentOp1ATI_remap_index 376
-#define AlphaFragmentOp2ATI_remap_index 377
-#define AlphaFragmentOp3ATI_remap_index 378
-#define BeginFragmentShaderATI_remap_index 379
-#define BindFragmentShaderATI_remap_index 380
-#define ColorFragmentOp1ATI_remap_index 381
-#define ColorFragmentOp2ATI_remap_index 382
-#define ColorFragmentOp3ATI_remap_index 383
-#define DeleteFragmentShaderATI_remap_index 384
-#define EndFragmentShaderATI_remap_index 385
-#define GenFragmentShadersATI_remap_index 386
-#define PassTexCoordATI_remap_index 387
-#define SampleMapATI_remap_index 388
-#define SetFragmentShaderConstantATI_remap_index 389
-#define PointParameteriNV_remap_index 390
-#define PointParameterivNV_remap_index 391
-#define ActiveStencilFaceEXT_remap_index 392
-#define BindVertexArrayAPPLE_remap_index 393
-#define DeleteVertexArraysAPPLE_remap_index 394
-#define GenVertexArraysAPPLE_remap_index 395
-#define IsVertexArrayAPPLE_remap_index 396
-#define GetProgramNamedParameterdvNV_remap_index 397
-#define GetProgramNamedParameterfvNV_remap_index 398
-#define ProgramNamedParameter4dNV_remap_index 399
-#define ProgramNamedParameter4dvNV_remap_index 400
-#define ProgramNamedParameter4fNV_remap_index 401
-#define ProgramNamedParameter4fvNV_remap_index 402
-#define PrimitiveRestartIndexNV_remap_index 403
-#define PrimitiveRestartNV_remap_index 404
-#define DepthBoundsEXT_remap_index 405
-#define BlendEquationSeparateEXT_remap_index 406
-#define BindFramebufferEXT_remap_index 407
-#define BindRenderbufferEXT_remap_index 408
-#define CheckFramebufferStatusEXT_remap_index 409
-#define DeleteFramebuffersEXT_remap_index 410
-#define DeleteRenderbuffersEXT_remap_index 411
-#define FramebufferRenderbufferEXT_remap_index 412
-#define FramebufferTexture1DEXT_remap_index 413
-#define FramebufferTexture2DEXT_remap_index 414
-#define FramebufferTexture3DEXT_remap_index 415
-#define GenFramebuffersEXT_remap_index 416
-#define GenRenderbuffersEXT_remap_index 417
-#define GenerateMipmapEXT_remap_index 418
-#define GetFramebufferAttachmentParameterivEXT_remap_index 419
-#define GetRenderbufferParameterivEXT_remap_index 420
-#define IsFramebufferEXT_remap_index 421
-#define IsRenderbufferEXT_remap_index 422
-#define RenderbufferStorageEXT_remap_index 423
-#define BlitFramebufferEXT_remap_index 424
-#define BufferParameteriAPPLE_remap_index 425
-#define FlushMappedBufferRangeAPPLE_remap_index 426
-#define BindFragDataLocationEXT_remap_index 427
-#define GetFragDataLocationEXT_remap_index 428
-#define GetUniformuivEXT_remap_index 429
-#define GetVertexAttribIivEXT_remap_index 430
-#define GetVertexAttribIuivEXT_remap_index 431
-#define Uniform1uiEXT_remap_index 432
-#define Uniform1uivEXT_remap_index 433
-#define Uniform2uiEXT_remap_index 434
-#define Uniform2uivEXT_remap_index 435
-#define Uniform3uiEXT_remap_index 436
-#define Uniform3uivEXT_remap_index 437
-#define Uniform4uiEXT_remap_index 438
-#define Uniform4uivEXT_remap_index 439
-#define VertexAttribI1iEXT_remap_index 440
-#define VertexAttribI1ivEXT_remap_index 441
-#define VertexAttribI1uiEXT_remap_index 442
-#define VertexAttribI1uivEXT_remap_index 443
-#define VertexAttribI2iEXT_remap_index 444
-#define VertexAttribI2ivEXT_remap_index 445
-#define VertexAttribI2uiEXT_remap_index 446
-#define VertexAttribI2uivEXT_remap_index 447
-#define VertexAttribI3iEXT_remap_index 448
-#define VertexAttribI3ivEXT_remap_index 449
-#define VertexAttribI3uiEXT_remap_index 450
-#define VertexAttribI3uivEXT_remap_index 451
-#define VertexAttribI4bvEXT_remap_index 452
-#define VertexAttribI4iEXT_remap_index 453
-#define VertexAttribI4ivEXT_remap_index 454
-#define VertexAttribI4svEXT_remap_index 455
-#define VertexAttribI4ubvEXT_remap_index 456
-#define VertexAttribI4uiEXT_remap_index 457
-#define VertexAttribI4uivEXT_remap_index 458
-#define VertexAttribI4usvEXT_remap_index 459
-#define VertexAttribIPointerEXT_remap_index 460
-#define FramebufferTextureLayerEXT_remap_index 461
-#define ColorMaskIndexedEXT_remap_index 462
-#define DisableIndexedEXT_remap_index 463
-#define EnableIndexedEXT_remap_index 464
-#define GetBooleanIndexedvEXT_remap_index 465
-#define GetIntegerIndexedvEXT_remap_index 466
-#define IsEnabledIndexedEXT_remap_index 467
-#define ClearColorIiEXT_remap_index 468
-#define ClearColorIuiEXT_remap_index 469
-#define GetTexParameterIivEXT_remap_index 470
-#define GetTexParameterIuivEXT_remap_index 471
-#define TexParameterIivEXT_remap_index 472
-#define TexParameterIuivEXT_remap_index 473
-#define BeginConditionalRenderNV_remap_index 474
-#define EndConditionalRenderNV_remap_index 475
-#define BeginTransformFeedbackEXT_remap_index 476
-#define BindBufferBaseEXT_remap_index 477
-#define BindBufferOffsetEXT_remap_index 478
-#define BindBufferRangeEXT_remap_index 479
-#define EndTransformFeedbackEXT_remap_index 480
-#define GetTransformFeedbackVaryingEXT_remap_index 481
-#define TransformFeedbackVaryingsEXT_remap_index 482
-#define ProvokingVertexEXT_remap_index 483
-#define GetTexParameterPointervAPPLE_remap_index 484
-#define TextureRangeAPPLE_remap_index 485
-#define GetObjectParameterivAPPLE_remap_index 486
-#define ObjectPurgeableAPPLE_remap_index 487
-#define ObjectUnpurgeableAPPLE_remap_index 488
-#define ActiveProgramEXT_remap_index 489
-#define CreateShaderProgramEXT_remap_index 490
-#define UseShaderProgramEXT_remap_index 491
-#define TextureBarrierNV_remap_index 492
-#define StencilFuncSeparateATI_remap_index 493
-#define ProgramEnvParameters4fvEXT_remap_index 494
-#define ProgramLocalParameters4fvEXT_remap_index 495
-#define GetQueryObjecti64vEXT_remap_index 496
-#define GetQueryObjectui64vEXT_remap_index 497
-#define EGLImageTargetRenderbufferStorageOES_remap_index 498
-#define EGLImageTargetTexture2DOES_remap_index 499
+#define GetGraphicsResetStatusARB_remap_index 218
+#define GetnColorTableARB_remap_index 219
+#define GetnCompressedTexImageARB_remap_index 220
+#define GetnConvolutionFilterARB_remap_index 221
+#define GetnHistogramARB_remap_index 222
+#define GetnMapdvARB_remap_index 223
+#define GetnMapfvARB_remap_index 224
+#define GetnMapivARB_remap_index 225
+#define GetnMinmaxARB_remap_index 226
+#define GetnPixelMapfvARB_remap_index 227
+#define GetnPixelMapuivARB_remap_index 228
+#define GetnPixelMapusvARB_remap_index 229
+#define GetnPolygonStippleARB_remap_index 230
+#define GetnSeparableFilterARB_remap_index 231
+#define GetnTexImageARB_remap_index 232
+#define GetnUniformdvARB_remap_index 233
+#define GetnUniformfvARB_remap_index 234
+#define GetnUniformivARB_remap_index 235
+#define GetnUniformuivARB_remap_index 236
+#define ReadnPixelsARB_remap_index 237
+#define PolygonOffsetEXT_remap_index 238
+#define GetPixelTexGenParameterfvSGIS_remap_index 239
+#define GetPixelTexGenParameterivSGIS_remap_index 240
+#define PixelTexGenParameterfSGIS_remap_index 241
+#define PixelTexGenParameterfvSGIS_remap_index 242
+#define PixelTexGenParameteriSGIS_remap_index 243
+#define PixelTexGenParameterivSGIS_remap_index 244
+#define SampleMaskSGIS_remap_index 245
+#define SamplePatternSGIS_remap_index 246
+#define ColorPointerEXT_remap_index 247
+#define EdgeFlagPointerEXT_remap_index 248
+#define IndexPointerEXT_remap_index 249
+#define NormalPointerEXT_remap_index 250
+#define TexCoordPointerEXT_remap_index 251
+#define VertexPointerEXT_remap_index 252
+#define PointParameterfEXT_remap_index 253
+#define PointParameterfvEXT_remap_index 254
+#define LockArraysEXT_remap_index 255
+#define UnlockArraysEXT_remap_index 256
+#define SecondaryColor3bEXT_remap_index 257
+#define SecondaryColor3bvEXT_remap_index 258
+#define SecondaryColor3dEXT_remap_index 259
+#define SecondaryColor3dvEXT_remap_index 260
+#define SecondaryColor3fEXT_remap_index 261
+#define SecondaryColor3fvEXT_remap_index 262
+#define SecondaryColor3iEXT_remap_index 263
+#define SecondaryColor3ivEXT_remap_index 264
+#define SecondaryColor3sEXT_remap_index 265
+#define SecondaryColor3svEXT_remap_index 266
+#define SecondaryColor3ubEXT_remap_index 267
+#define SecondaryColor3ubvEXT_remap_index 268
+#define SecondaryColor3uiEXT_remap_index 269
+#define SecondaryColor3uivEXT_remap_index 270
+#define SecondaryColor3usEXT_remap_index 271
+#define SecondaryColor3usvEXT_remap_index 272
+#define SecondaryColorPointerEXT_remap_index 273
+#define MultiDrawArraysEXT_remap_index 274
+#define MultiDrawElementsEXT_remap_index 275
+#define FogCoordPointerEXT_remap_index 276
+#define FogCoorddEXT_remap_index 277
+#define FogCoorddvEXT_remap_index 278
+#define FogCoordfEXT_remap_index 279
+#define FogCoordfvEXT_remap_index 280
+#define PixelTexGenSGIX_remap_index 281
+#define BlendFuncSeparateEXT_remap_index 282
+#define FlushVertexArrayRangeNV_remap_index 283
+#define VertexArrayRangeNV_remap_index 284
+#define CombinerInputNV_remap_index 285
+#define CombinerOutputNV_remap_index 286
+#define CombinerParameterfNV_remap_index 287
+#define CombinerParameterfvNV_remap_index 288
+#define CombinerParameteriNV_remap_index 289
+#define CombinerParameterivNV_remap_index 290
+#define FinalCombinerInputNV_remap_index 291
+#define GetCombinerInputParameterfvNV_remap_index 292
+#define GetCombinerInputParameterivNV_remap_index 293
+#define GetCombinerOutputParameterfvNV_remap_index 294
+#define GetCombinerOutputParameterivNV_remap_index 295
+#define GetFinalCombinerInputParameterfvNV_remap_index 296
+#define GetFinalCombinerInputParameterivNV_remap_index 297
+#define ResizeBuffersMESA_remap_index 298
+#define WindowPos2dMESA_remap_index 299
+#define WindowPos2dvMESA_remap_index 300
+#define WindowPos2fMESA_remap_index 301
+#define WindowPos2fvMESA_remap_index 302
+#define WindowPos2iMESA_remap_index 303
+#define WindowPos2ivMESA_remap_index 304
+#define WindowPos2sMESA_remap_index 305
+#define WindowPos2svMESA_remap_index 306
+#define WindowPos3dMESA_remap_index 307
+#define WindowPos3dvMESA_remap_index 308
+#define WindowPos3fMESA_remap_index 309
+#define WindowPos3fvMESA_remap_index 310
+#define WindowPos3iMESA_remap_index 311
+#define WindowPos3ivMESA_remap_index 312
+#define WindowPos3sMESA_remap_index 313
+#define WindowPos3svMESA_remap_index 314
+#define WindowPos4dMESA_remap_index 315
+#define WindowPos4dvMESA_remap_index 316
+#define WindowPos4fMESA_remap_index 317
+#define WindowPos4fvMESA_remap_index 318
+#define WindowPos4iMESA_remap_index 319
+#define WindowPos4ivMESA_remap_index 320
+#define WindowPos4sMESA_remap_index 321
+#define WindowPos4svMESA_remap_index 322
+#define MultiModeDrawArraysIBM_remap_index 323
+#define MultiModeDrawElementsIBM_remap_index 324
+#define DeleteFencesNV_remap_index 325
+#define FinishFenceNV_remap_index 326
+#define GenFencesNV_remap_index 327
+#define GetFenceivNV_remap_index 328
+#define IsFenceNV_remap_index 329
+#define SetFenceNV_remap_index 330
+#define TestFenceNV_remap_index 331
+#define AreProgramsResidentNV_remap_index 332
+#define BindProgramNV_remap_index 333
+#define DeleteProgramsNV_remap_index 334
+#define ExecuteProgramNV_remap_index 335
+#define GenProgramsNV_remap_index 336
+#define GetProgramParameterdvNV_remap_index 337
+#define GetProgramParameterfvNV_remap_index 338
+#define GetProgramStringNV_remap_index 339
+#define GetProgramivNV_remap_index 340
+#define GetTrackMatrixivNV_remap_index 341
+#define GetVertexAttribPointervNV_remap_index 342
+#define GetVertexAttribdvNV_remap_index 343
+#define GetVertexAttribfvNV_remap_index 344
+#define GetVertexAttribivNV_remap_index 345
+#define IsProgramNV_remap_index 346
+#define LoadProgramNV_remap_index 347
+#define ProgramParameters4dvNV_remap_index 348
+#define ProgramParameters4fvNV_remap_index 349
+#define RequestResidentProgramsNV_remap_index 350
+#define TrackMatrixNV_remap_index 351
+#define VertexAttrib1dNV_remap_index 352
+#define VertexAttrib1dvNV_remap_index 353
+#define VertexAttrib1fNV_remap_index 354
+#define VertexAttrib1fvNV_remap_index 355
+#define VertexAttrib1sNV_remap_index 356
+#define VertexAttrib1svNV_remap_index 357
+#define VertexAttrib2dNV_remap_index 358
+#define VertexAttrib2dvNV_remap_index 359
+#define VertexAttrib2fNV_remap_index 360
+#define VertexAttrib2fvNV_remap_index 361
+#define VertexAttrib2sNV_remap_index 362
+#define VertexAttrib2svNV_remap_index 363
+#define VertexAttrib3dNV_remap_index 364
+#define VertexAttrib3dvNV_remap_index 365
+#define VertexAttrib3fNV_remap_index 366
+#define VertexAttrib3fvNV_remap_index 367
+#define VertexAttrib3sNV_remap_index 368
+#define VertexAttrib3svNV_remap_index 369
+#define VertexAttrib4dNV_remap_index 370
+#define VertexAttrib4dvNV_remap_index 371
+#define VertexAttrib4fNV_remap_index 372
+#define VertexAttrib4fvNV_remap_index 373
+#define VertexAttrib4sNV_remap_index 374
+#define VertexAttrib4svNV_remap_index 375
+#define VertexAttrib4ubNV_remap_index 376
+#define VertexAttrib4ubvNV_remap_index 377
+#define VertexAttribPointerNV_remap_index 378
+#define VertexAttribs1dvNV_remap_index 379
+#define VertexAttribs1fvNV_remap_index 380
+#define VertexAttribs1svNV_remap_index 381
+#define VertexAttribs2dvNV_remap_index 382
+#define VertexAttribs2fvNV_remap_index 383
+#define VertexAttribs2svNV_remap_index 384
+#define VertexAttribs3dvNV_remap_index 385
+#define VertexAttribs3fvNV_remap_index 386
+#define VertexAttribs3svNV_remap_index 387
+#define VertexAttribs4dvNV_remap_index 388
+#define VertexAttribs4fvNV_remap_index 389
+#define VertexAttribs4svNV_remap_index 390
+#define VertexAttribs4ubvNV_remap_index 391
+#define GetTexBumpParameterfvATI_remap_index 392
+#define GetTexBumpParameterivATI_remap_index 393
+#define TexBumpParameterfvATI_remap_index 394
+#define TexBumpParameterivATI_remap_index 395
+#define AlphaFragmentOp1ATI_remap_index 396
+#define AlphaFragmentOp2ATI_remap_index 397
+#define AlphaFragmentOp3ATI_remap_index 398
+#define BeginFragmentShaderATI_remap_index 399
+#define BindFragmentShaderATI_remap_index 400
+#define ColorFragmentOp1ATI_remap_index 401
+#define ColorFragmentOp2ATI_remap_index 402
+#define ColorFragmentOp3ATI_remap_index 403
+#define DeleteFragmentShaderATI_remap_index 404
+#define EndFragmentShaderATI_remap_index 405
+#define GenFragmentShadersATI_remap_index 406
+#define PassTexCoordATI_remap_index 407
+#define SampleMapATI_remap_index 408
+#define SetFragmentShaderConstantATI_remap_index 409
+#define PointParameteriNV_remap_index 410
+#define PointParameterivNV_remap_index 411
+#define ActiveStencilFaceEXT_remap_index 412
+#define BindVertexArrayAPPLE_remap_index 413
+#define DeleteVertexArraysAPPLE_remap_index 414
+#define GenVertexArraysAPPLE_remap_index 415
+#define IsVertexArrayAPPLE_remap_index 416
+#define GetProgramNamedParameterdvNV_remap_index 417
+#define GetProgramNamedParameterfvNV_remap_index 418
+#define ProgramNamedParameter4dNV_remap_index 419
+#define ProgramNamedParameter4dvNV_remap_index 420
+#define ProgramNamedParameter4fNV_remap_index 421
+#define ProgramNamedParameter4fvNV_remap_index 422
+#define PrimitiveRestartIndexNV_remap_index 423
+#define PrimitiveRestartNV_remap_index 424
+#define DepthBoundsEXT_remap_index 425
+#define BlendEquationSeparateEXT_remap_index 426
+#define BindFramebufferEXT_remap_index 427
+#define BindRenderbufferEXT_remap_index 428
+#define CheckFramebufferStatusEXT_remap_index 429
+#define DeleteFramebuffersEXT_remap_index 430
+#define DeleteRenderbuffersEXT_remap_index 431
+#define FramebufferRenderbufferEXT_remap_index 432
+#define FramebufferTexture1DEXT_remap_index 433
+#define FramebufferTexture2DEXT_remap_index 434
+#define FramebufferTexture3DEXT_remap_index 435
+#define GenFramebuffersEXT_remap_index 436
+#define GenRenderbuffersEXT_remap_index 437
+#define GenerateMipmapEXT_remap_index 438
+#define GetFramebufferAttachmentParameterivEXT_remap_index 439
+#define GetRenderbufferParameterivEXT_remap_index 440
+#define IsFramebufferEXT_remap_index 441
+#define IsRenderbufferEXT_remap_index 442
+#define RenderbufferStorageEXT_remap_index 443
+#define BlitFramebufferEXT_remap_index 444
+#define BufferParameteriAPPLE_remap_index 445
+#define FlushMappedBufferRangeAPPLE_remap_index 446
+#define BindFragDataLocationEXT_remap_index 447
+#define GetFragDataLocationEXT_remap_index 448
+#define GetUniformuivEXT_remap_index 449
+#define GetVertexAttribIivEXT_remap_index 450
+#define GetVertexAttribIuivEXT_remap_index 451
+#define Uniform1uiEXT_remap_index 452
+#define Uniform1uivEXT_remap_index 453
+#define Uniform2uiEXT_remap_index 454
+#define Uniform2uivEXT_remap_index 455
+#define Uniform3uiEXT_remap_index 456
+#define Uniform3uivEXT_remap_index 457
+#define Uniform4uiEXT_remap_index 458
+#define Uniform4uivEXT_remap_index 459
+#define VertexAttribI1iEXT_remap_index 460
+#define VertexAttribI1ivEXT_remap_index 461
+#define VertexAttribI1uiEXT_remap_index 462
+#define VertexAttribI1uivEXT_remap_index 463
+#define VertexAttribI2iEXT_remap_index 464
+#define VertexAttribI2ivEXT_remap_index 465
+#define VertexAttribI2uiEXT_remap_index 466
+#define VertexAttribI2uivEXT_remap_index 467
+#define VertexAttribI3iEXT_remap_index 468
+#define VertexAttribI3ivEXT_remap_index 469
+#define VertexAttribI3uiEXT_remap_index 470
+#define VertexAttribI3uivEXT_remap_index 471
+#define VertexAttribI4bvEXT_remap_index 472
+#define VertexAttribI4iEXT_remap_index 473
+#define VertexAttribI4ivEXT_remap_index 474
+#define VertexAttribI4svEXT_remap_index 475
+#define VertexAttribI4ubvEXT_remap_index 476
+#define VertexAttribI4uiEXT_remap_index 477
+#define VertexAttribI4uivEXT_remap_index 478
+#define VertexAttribI4usvEXT_remap_index 479
+#define VertexAttribIPointerEXT_remap_index 480
+#define FramebufferTextureLayerEXT_remap_index 481
+#define ColorMaskIndexedEXT_remap_index 482
+#define DisableIndexedEXT_remap_index 483
+#define EnableIndexedEXT_remap_index 484
+#define GetBooleanIndexedvEXT_remap_index 485
+#define GetIntegerIndexedvEXT_remap_index 486
+#define IsEnabledIndexedEXT_remap_index 487
+#define ClearColorIiEXT_remap_index 488
+#define ClearColorIuiEXT_remap_index 489
+#define GetTexParameterIivEXT_remap_index 490
+#define GetTexParameterIuivEXT_remap_index 491
+#define TexParameterIivEXT_remap_index 492
+#define TexParameterIuivEXT_remap_index 493
+#define BeginConditionalRenderNV_remap_index 494
+#define EndConditionalRenderNV_remap_index 495
+#define BeginTransformFeedbackEXT_remap_index 496
+#define BindBufferBaseEXT_remap_index 497
+#define BindBufferOffsetEXT_remap_index 498
+#define BindBufferRangeEXT_remap_index 499
+#define EndTransformFeedbackEXT_remap_index 500
+#define GetTransformFeedbackVaryingEXT_remap_index 501
+#define TransformFeedbackVaryingsEXT_remap_index 502
+#define ProvokingVertexEXT_remap_index 503
+#define GetTexParameterPointervAPPLE_remap_index 504
+#define TextureRangeAPPLE_remap_index 505
+#define GetObjectParameterivAPPLE_remap_index 506
+#define ObjectPurgeableAPPLE_remap_index 507
+#define ObjectUnpurgeableAPPLE_remap_index 508
+#define ActiveProgramEXT_remap_index 509
+#define CreateShaderProgramEXT_remap_index 510
+#define UseShaderProgramEXT_remap_index 511
+#define TextureBarrierNV_remap_index 512
+#define StencilFuncSeparateATI_remap_index 513
+#define ProgramEnvParameters4fvEXT_remap_index 514
+#define ProgramLocalParameters4fvEXT_remap_index 515
+#define GetQueryObjecti64vEXT_remap_index 516
+#define GetQueryObjectui64vEXT_remap_index 517
+#define EGLImageTargetRenderbufferStorageOES_remap_index 518
+#define EGLImageTargetTexture2DOES_remap_index 519
#define _gloffset_AttachShader driDispatchRemapTable[AttachShader_remap_index]
#define _gloffset_CreateProgram driDispatchRemapTable[CreateProgram_remap_index]
@@ -1696,6 +1736,26 @@ extern int driDispatchRemapTable[ driDispatchRemapTable_size ];
#define _gloffset_GetShaderPrecisionFormat driDispatchRemapTable[GetShaderPrecisionFormat_remap_index]
#define _gloffset_ReleaseShaderCompiler driDispatchRemapTable[ReleaseShaderCompiler_remap_index]
#define _gloffset_ShaderBinary driDispatchRemapTable[ShaderBinary_remap_index]
+#define _gloffset_GetGraphicsResetStatusARB driDispatchRemapTable[GetGraphicsResetStatusARB_remap_index]
+#define _gloffset_GetnColorTableARB driDispatchRemapTable[GetnColorTableARB_remap_index]
+#define _gloffset_GetnCompressedTexImageARB driDispatchRemapTable[GetnCompressedTexImageARB_remap_index]
+#define _gloffset_GetnConvolutionFilterARB driDispatchRemapTable[GetnConvolutionFilterARB_remap_index]
+#define _gloffset_GetnHistogramARB driDispatchRemapTable[GetnHistogramARB_remap_index]
+#define _gloffset_GetnMapdvARB driDispatchRemapTable[GetnMapdvARB_remap_index]
+#define _gloffset_GetnMapfvARB driDispatchRemapTable[GetnMapfvARB_remap_index]
+#define _gloffset_GetnMapivARB driDispatchRemapTable[GetnMapivARB_remap_index]
+#define _gloffset_GetnMinmaxARB driDispatchRemapTable[GetnMinmaxARB_remap_index]
+#define _gloffset_GetnPixelMapfvARB driDispatchRemapTable[GetnPixelMapfvARB_remap_index]
+#define _gloffset_GetnPixelMapuivARB driDispatchRemapTable[GetnPixelMapuivARB_remap_index]
+#define _gloffset_GetnPixelMapusvARB driDispatchRemapTable[GetnPixelMapusvARB_remap_index]
+#define _gloffset_GetnPolygonStippleARB driDispatchRemapTable[GetnPolygonStippleARB_remap_index]
+#define _gloffset_GetnSeparableFilterARB driDispatchRemapTable[GetnSeparableFilterARB_remap_index]
+#define _gloffset_GetnTexImageARB driDispatchRemapTable[GetnTexImageARB_remap_index]
+#define _gloffset_GetnUniformdvARB driDispatchRemapTable[GetnUniformdvARB_remap_index]
+#define _gloffset_GetnUniformfvARB driDispatchRemapTable[GetnUniformfvARB_remap_index]
+#define _gloffset_GetnUniformivARB driDispatchRemapTable[GetnUniformivARB_remap_index]
+#define _gloffset_GetnUniformuivARB driDispatchRemapTable[GetnUniformuivARB_remap_index]
+#define _gloffset_ReadnPixelsARB driDispatchRemapTable[ReadnPixelsARB_remap_index]
#define _gloffset_PolygonOffsetEXT driDispatchRemapTable[PolygonOffsetEXT_remap_index]
#define _gloffset_GetPixelTexGenParameterfvSGIS driDispatchRemapTable[GetPixelTexGenParameterfvSGIS_remap_index]
#define _gloffset_GetPixelTexGenParameterivSGIS driDispatchRemapTable[GetPixelTexGenParameterivSGIS_remap_index]
@@ -3859,6 +3919,66 @@ extern int driDispatchRemapTable[ driDispatchRemapTable_size ];
#define CALL_ShaderBinary(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLsizei, const GLuint *, GLenum, const GLvoid *, GLsizei)), _gloffset_ShaderBinary, parameters)
#define GET_ShaderBinary(disp) GET_by_offset(disp, _gloffset_ShaderBinary)
#define SET_ShaderBinary(disp, fn) SET_by_offset(disp, _gloffset_ShaderBinary, fn)
+#define CALL_GetGraphicsResetStatusARB(disp, parameters) CALL_by_offset(disp, (GLenum (GLAPIENTRYP)(void)), _gloffset_GetGraphicsResetStatusARB, parameters)
+#define GET_GetGraphicsResetStatusARB(disp) GET_by_offset(disp, _gloffset_GetGraphicsResetStatusARB)
+#define SET_GetGraphicsResetStatusARB(disp, fn) SET_by_offset(disp, _gloffset_GetGraphicsResetStatusARB, fn)
+#define CALL_GetnColorTableARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLenum, GLenum, GLenum, GLsizei, GLvoid *)), _gloffset_GetnColorTableARB, parameters)
+#define GET_GetnColorTableARB(disp) GET_by_offset(disp, _gloffset_GetnColorTableARB)
+#define SET_GetnColorTableARB(disp, fn) SET_by_offset(disp, _gloffset_GetnColorTableARB, fn)
+#define CALL_GetnCompressedTexImageARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLenum, GLint, GLsizei, GLvoid *)), _gloffset_GetnCompressedTexImageARB, parameters)
+#define GET_GetnCompressedTexImageARB(disp) GET_by_offset(disp, _gloffset_GetnCompressedTexImageARB)
+#define SET_GetnCompressedTexImageARB(disp, fn) SET_by_offset(disp, _gloffset_GetnCompressedTexImageARB, fn)
+#define CALL_GetnConvolutionFilterARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLenum, GLenum, GLenum, GLsizei, GLvoid *)), _gloffset_GetnConvolutionFilterARB, parameters)
+#define GET_GetnConvolutionFilterARB(disp) GET_by_offset(disp, _gloffset_GetnConvolutionFilterARB)
+#define SET_GetnConvolutionFilterARB(disp, fn) SET_by_offset(disp, _gloffset_GetnConvolutionFilterARB, fn)
+#define CALL_GetnHistogramARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLenum, GLboolean, GLenum, GLenum, GLsizei, GLvoid *)), _gloffset_GetnHistogramARB, parameters)
+#define GET_GetnHistogramARB(disp) GET_by_offset(disp, _gloffset_GetnHistogramARB)
+#define SET_GetnHistogramARB(disp, fn) SET_by_offset(disp, _gloffset_GetnHistogramARB, fn)
+#define CALL_GetnMapdvARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLenum, GLenum, GLsizei, GLdouble *)), _gloffset_GetnMapdvARB, parameters)
+#define GET_GetnMapdvARB(disp) GET_by_offset(disp, _gloffset_GetnMapdvARB)
+#define SET_GetnMapdvARB(disp, fn) SET_by_offset(disp, _gloffset_GetnMapdvARB, fn)
+#define CALL_GetnMapfvARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLenum, GLenum, GLsizei, GLfloat *)), _gloffset_GetnMapfvARB, parameters)
+#define GET_GetnMapfvARB(disp) GET_by_offset(disp, _gloffset_GetnMapfvARB)
+#define SET_GetnMapfvARB(disp, fn) SET_by_offset(disp, _gloffset_GetnMapfvARB, fn)
+#define CALL_GetnMapivARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLenum, GLenum, GLsizei, GLint *)), _gloffset_GetnMapivARB, parameters)
+#define GET_GetnMapivARB(disp) GET_by_offset(disp, _gloffset_GetnMapivARB)
+#define SET_GetnMapivARB(disp, fn) SET_by_offset(disp, _gloffset_GetnMapivARB, fn)
+#define CALL_GetnMinmaxARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLenum, GLboolean, GLenum, GLenum, GLsizei, GLvoid *)), _gloffset_GetnMinmaxARB, parameters)
+#define GET_GetnMinmaxARB(disp) GET_by_offset(disp, _gloffset_GetnMinmaxARB)
+#define SET_GetnMinmaxARB(disp, fn) SET_by_offset(disp, _gloffset_GetnMinmaxARB, fn)
+#define CALL_GetnPixelMapfvARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLenum, GLsizei, GLfloat *)), _gloffset_GetnPixelMapfvARB, parameters)
+#define GET_GetnPixelMapfvARB(disp) GET_by_offset(disp, _gloffset_GetnPixelMapfvARB)
+#define SET_GetnPixelMapfvARB(disp, fn) SET_by_offset(disp, _gloffset_GetnPixelMapfvARB, fn)
+#define CALL_GetnPixelMapuivARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLenum, GLsizei, GLuint *)), _gloffset_GetnPixelMapuivARB, parameters)
+#define GET_GetnPixelMapuivARB(disp) GET_by_offset(disp, _gloffset_GetnPixelMapuivARB)
+#define SET_GetnPixelMapuivARB(disp, fn) SET_by_offset(disp, _gloffset_GetnPixelMapuivARB, fn)
+#define CALL_GetnPixelMapusvARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLenum, GLsizei, GLushort *)), _gloffset_GetnPixelMapusvARB, parameters)
+#define GET_GetnPixelMapusvARB(disp) GET_by_offset(disp, _gloffset_GetnPixelMapusvARB)
+#define SET_GetnPixelMapusvARB(disp, fn) SET_by_offset(disp, _gloffset_GetnPixelMapusvARB, fn)
+#define CALL_GetnPolygonStippleARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLsizei, GLubyte *)), _gloffset_GetnPolygonStippleARB, parameters)
+#define GET_GetnPolygonStippleARB(disp) GET_by_offset(disp, _gloffset_GetnPolygonStippleARB)
+#define SET_GetnPolygonStippleARB(disp, fn) SET_by_offset(disp, _gloffset_GetnPolygonStippleARB, fn)
+#define CALL_GetnSeparableFilterARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLenum, GLenum, GLenum, GLsizei, GLvoid *, GLsizei, GLvoid *, GLvoid *)), _gloffset_GetnSeparableFilterARB, parameters)
+#define GET_GetnSeparableFilterARB(disp) GET_by_offset(disp, _gloffset_GetnSeparableFilterARB)
+#define SET_GetnSeparableFilterARB(disp, fn) SET_by_offset(disp, _gloffset_GetnSeparableFilterARB, fn)
+#define CALL_GetnTexImageARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLenum, GLint, GLenum, GLenum, GLsizei, GLvoid *)), _gloffset_GetnTexImageARB, parameters)
+#define GET_GetnTexImageARB(disp) GET_by_offset(disp, _gloffset_GetnTexImageARB)
+#define SET_GetnTexImageARB(disp, fn) SET_by_offset(disp, _gloffset_GetnTexImageARB, fn)
+#define CALL_GetnUniformdvARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLhandleARB, GLint, GLsizei, GLdouble *)), _gloffset_GetnUniformdvARB, parameters)
+#define GET_GetnUniformdvARB(disp) GET_by_offset(disp, _gloffset_GetnUniformdvARB)
+#define SET_GetnUniformdvARB(disp, fn) SET_by_offset(disp, _gloffset_GetnUniformdvARB, fn)
+#define CALL_GetnUniformfvARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLhandleARB, GLint, GLsizei, GLfloat *)), _gloffset_GetnUniformfvARB, parameters)
+#define GET_GetnUniformfvARB(disp) GET_by_offset(disp, _gloffset_GetnUniformfvARB)
+#define SET_GetnUniformfvARB(disp, fn) SET_by_offset(disp, _gloffset_GetnUniformfvARB, fn)
+#define CALL_GetnUniformivARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLhandleARB, GLint, GLsizei, GLint *)), _gloffset_GetnUniformivARB, parameters)
+#define GET_GetnUniformivARB(disp) GET_by_offset(disp, _gloffset_GetnUniformivARB)
+#define SET_GetnUniformivARB(disp, fn) SET_by_offset(disp, _gloffset_GetnUniformivARB, fn)
+#define CALL_GetnUniformuivARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLhandleARB, GLint, GLsizei, GLuint *)), _gloffset_GetnUniformuivARB, parameters)
+#define GET_GetnUniformuivARB(disp) GET_by_offset(disp, _gloffset_GetnUniformuivARB)
+#define SET_GetnUniformuivARB(disp, fn) SET_by_offset(disp, _gloffset_GetnUniformuivARB, fn)
+#define CALL_ReadnPixelsARB(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLint, GLint, GLsizei, GLsizei, GLenum, GLenum, GLsizei, GLvoid *)), _gloffset_ReadnPixelsARB, parameters)
+#define GET_ReadnPixelsARB(disp) GET_by_offset(disp, _gloffset_ReadnPixelsARB)
+#define SET_ReadnPixelsARB(disp, fn) SET_by_offset(disp, _gloffset_ReadnPixelsARB, fn)
#define CALL_PolygonOffsetEXT(disp, parameters) CALL_by_offset(disp, (void (GLAPIENTRYP)(GLfloat, GLfloat)), _gloffset_PolygonOffsetEXT, parameters)
#define GET_PolygonOffsetEXT(disp) GET_by_offset(disp, _gloffset_PolygonOffsetEXT)
#define SET_PolygonOffsetEXT(disp, fn) SET_by_offset(disp, _gloffset_PolygonOffsetEXT, fn)
diff --git a/xorg-server/glx/glapitable.h b/xorg-server/glx/glapitable.h
index 7449a4045..16f072fb6 100644
--- a/xorg-server/glx/glapitable.h
+++ b/xorg-server/glx/glapitable.h
@@ -666,288 +666,308 @@ struct _glapi_table
void (GLAPIENTRYP GetShaderPrecisionFormat)(GLenum shadertype, GLenum precisiontype, GLint * range, GLint * precision); /* 623 */
void (GLAPIENTRYP ReleaseShaderCompiler)(void); /* 624 */
void (GLAPIENTRYP ShaderBinary)(GLsizei n, const GLuint * shaders, GLenum binaryformat, const GLvoid * binary, GLsizei length); /* 625 */
- void (GLAPIENTRYP PolygonOffsetEXT)(GLfloat factor, GLfloat bias); /* 626 */
- void (GLAPIENTRYP GetPixelTexGenParameterfvSGIS)(GLenum pname, GLfloat * params); /* 627 */
- void (GLAPIENTRYP GetPixelTexGenParameterivSGIS)(GLenum pname, GLint * params); /* 628 */
- void (GLAPIENTRYP PixelTexGenParameterfSGIS)(GLenum pname, GLfloat param); /* 629 */
- void (GLAPIENTRYP PixelTexGenParameterfvSGIS)(GLenum pname, const GLfloat * params); /* 630 */
- void (GLAPIENTRYP PixelTexGenParameteriSGIS)(GLenum pname, GLint param); /* 631 */
- void (GLAPIENTRYP PixelTexGenParameterivSGIS)(GLenum pname, const GLint * params); /* 632 */
- void (GLAPIENTRYP SampleMaskSGIS)(GLclampf value, GLboolean invert); /* 633 */
- void (GLAPIENTRYP SamplePatternSGIS)(GLenum pattern); /* 634 */
- void (GLAPIENTRYP ColorPointerEXT)(GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid * pointer); /* 635 */
- void (GLAPIENTRYP EdgeFlagPointerEXT)(GLsizei stride, GLsizei count, const GLboolean * pointer); /* 636 */
- void (GLAPIENTRYP IndexPointerEXT)(GLenum type, GLsizei stride, GLsizei count, const GLvoid * pointer); /* 637 */
- void (GLAPIENTRYP NormalPointerEXT)(GLenum type, GLsizei stride, GLsizei count, const GLvoid * pointer); /* 638 */
- void (GLAPIENTRYP TexCoordPointerEXT)(GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid * pointer); /* 639 */
- void (GLAPIENTRYP VertexPointerEXT)(GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid * pointer); /* 640 */
- void (GLAPIENTRYP PointParameterfEXT)(GLenum pname, GLfloat param); /* 641 */
- void (GLAPIENTRYP PointParameterfvEXT)(GLenum pname, const GLfloat * params); /* 642 */
- void (GLAPIENTRYP LockArraysEXT)(GLint first, GLsizei count); /* 643 */
- void (GLAPIENTRYP UnlockArraysEXT)(void); /* 644 */
- void (GLAPIENTRYP SecondaryColor3bEXT)(GLbyte red, GLbyte green, GLbyte blue); /* 645 */
- void (GLAPIENTRYP SecondaryColor3bvEXT)(const GLbyte * v); /* 646 */
- void (GLAPIENTRYP SecondaryColor3dEXT)(GLdouble red, GLdouble green, GLdouble blue); /* 647 */
- void (GLAPIENTRYP SecondaryColor3dvEXT)(const GLdouble * v); /* 648 */
- void (GLAPIENTRYP SecondaryColor3fEXT)(GLfloat red, GLfloat green, GLfloat blue); /* 649 */
- void (GLAPIENTRYP SecondaryColor3fvEXT)(const GLfloat * v); /* 650 */
- void (GLAPIENTRYP SecondaryColor3iEXT)(GLint red, GLint green, GLint blue); /* 651 */
- void (GLAPIENTRYP SecondaryColor3ivEXT)(const GLint * v); /* 652 */
- void (GLAPIENTRYP SecondaryColor3sEXT)(GLshort red, GLshort green, GLshort blue); /* 653 */
- void (GLAPIENTRYP SecondaryColor3svEXT)(const GLshort * v); /* 654 */
- void (GLAPIENTRYP SecondaryColor3ubEXT)(GLubyte red, GLubyte green, GLubyte blue); /* 655 */
- void (GLAPIENTRYP SecondaryColor3ubvEXT)(const GLubyte * v); /* 656 */
- void (GLAPIENTRYP SecondaryColor3uiEXT)(GLuint red, GLuint green, GLuint blue); /* 657 */
- void (GLAPIENTRYP SecondaryColor3uivEXT)(const GLuint * v); /* 658 */
- void (GLAPIENTRYP SecondaryColor3usEXT)(GLushort red, GLushort green, GLushort blue); /* 659 */
- void (GLAPIENTRYP SecondaryColor3usvEXT)(const GLushort * v); /* 660 */
- void (GLAPIENTRYP SecondaryColorPointerEXT)(GLint size, GLenum type, GLsizei stride, const GLvoid * pointer); /* 661 */
- void (GLAPIENTRYP MultiDrawArraysEXT)(GLenum mode, const GLint * first, const GLsizei * count, GLsizei primcount); /* 662 */
- void (GLAPIENTRYP MultiDrawElementsEXT)(GLenum mode, const GLsizei * count, GLenum type, const GLvoid ** indices, GLsizei primcount); /* 663 */
- void (GLAPIENTRYP FogCoordPointerEXT)(GLenum type, GLsizei stride, const GLvoid * pointer); /* 664 */
- void (GLAPIENTRYP FogCoorddEXT)(GLdouble coord); /* 665 */
- void (GLAPIENTRYP FogCoorddvEXT)(const GLdouble * coord); /* 666 */
- void (GLAPIENTRYP FogCoordfEXT)(GLfloat coord); /* 667 */
- void (GLAPIENTRYP FogCoordfvEXT)(const GLfloat * coord); /* 668 */
- void (GLAPIENTRYP PixelTexGenSGIX)(GLenum mode); /* 669 */
- void (GLAPIENTRYP BlendFuncSeparateEXT)(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); /* 670 */
- void (GLAPIENTRYP FlushVertexArrayRangeNV)(void); /* 671 */
- void (GLAPIENTRYP VertexArrayRangeNV)(GLsizei length, const GLvoid * pointer); /* 672 */
- void (GLAPIENTRYP CombinerInputNV)(GLenum stage, GLenum portion, GLenum variable, GLenum input, GLenum mapping, GLenum componentUsage); /* 673 */
- void (GLAPIENTRYP CombinerOutputNV)(GLenum stage, GLenum portion, GLenum abOutput, GLenum cdOutput, GLenum sumOutput, GLenum scale, GLenum bias, GLboolean abDotProduct, GLboolean cdDotProduct, GLboolean muxSum); /* 674 */
- void (GLAPIENTRYP CombinerParameterfNV)(GLenum pname, GLfloat param); /* 675 */
- void (GLAPIENTRYP CombinerParameterfvNV)(GLenum pname, const GLfloat * params); /* 676 */
- void (GLAPIENTRYP CombinerParameteriNV)(GLenum pname, GLint param); /* 677 */
- void (GLAPIENTRYP CombinerParameterivNV)(GLenum pname, const GLint * params); /* 678 */
- void (GLAPIENTRYP FinalCombinerInputNV)(GLenum variable, GLenum input, GLenum mapping, GLenum componentUsage); /* 679 */
- void (GLAPIENTRYP GetCombinerInputParameterfvNV)(GLenum stage, GLenum portion, GLenum variable, GLenum pname, GLfloat * params); /* 680 */
- void (GLAPIENTRYP GetCombinerInputParameterivNV)(GLenum stage, GLenum portion, GLenum variable, GLenum pname, GLint * params); /* 681 */
- void (GLAPIENTRYP GetCombinerOutputParameterfvNV)(GLenum stage, GLenum portion, GLenum pname, GLfloat * params); /* 682 */
- void (GLAPIENTRYP GetCombinerOutputParameterivNV)(GLenum stage, GLenum portion, GLenum pname, GLint * params); /* 683 */
- void (GLAPIENTRYP GetFinalCombinerInputParameterfvNV)(GLenum variable, GLenum pname, GLfloat * params); /* 684 */
- void (GLAPIENTRYP GetFinalCombinerInputParameterivNV)(GLenum variable, GLenum pname, GLint * params); /* 685 */
- void (GLAPIENTRYP ResizeBuffersMESA)(void); /* 686 */
- void (GLAPIENTRYP WindowPos2dMESA)(GLdouble x, GLdouble y); /* 687 */
- void (GLAPIENTRYP WindowPos2dvMESA)(const GLdouble * v); /* 688 */
- void (GLAPIENTRYP WindowPos2fMESA)(GLfloat x, GLfloat y); /* 689 */
- void (GLAPIENTRYP WindowPos2fvMESA)(const GLfloat * v); /* 690 */
- void (GLAPIENTRYP WindowPos2iMESA)(GLint x, GLint y); /* 691 */
- void (GLAPIENTRYP WindowPos2ivMESA)(const GLint * v); /* 692 */
- void (GLAPIENTRYP WindowPos2sMESA)(GLshort x, GLshort y); /* 693 */
- void (GLAPIENTRYP WindowPos2svMESA)(const GLshort * v); /* 694 */
- void (GLAPIENTRYP WindowPos3dMESA)(GLdouble x, GLdouble y, GLdouble z); /* 695 */
- void (GLAPIENTRYP WindowPos3dvMESA)(const GLdouble * v); /* 696 */
- void (GLAPIENTRYP WindowPos3fMESA)(GLfloat x, GLfloat y, GLfloat z); /* 697 */
- void (GLAPIENTRYP WindowPos3fvMESA)(const GLfloat * v); /* 698 */
- void (GLAPIENTRYP WindowPos3iMESA)(GLint x, GLint y, GLint z); /* 699 */
- void (GLAPIENTRYP WindowPos3ivMESA)(const GLint * v); /* 700 */
- void (GLAPIENTRYP WindowPos3sMESA)(GLshort x, GLshort y, GLshort z); /* 701 */
- void (GLAPIENTRYP WindowPos3svMESA)(const GLshort * v); /* 702 */
- void (GLAPIENTRYP WindowPos4dMESA)(GLdouble x, GLdouble y, GLdouble z, GLdouble w); /* 703 */
- void (GLAPIENTRYP WindowPos4dvMESA)(const GLdouble * v); /* 704 */
- void (GLAPIENTRYP WindowPos4fMESA)(GLfloat x, GLfloat y, GLfloat z, GLfloat w); /* 705 */
- void (GLAPIENTRYP WindowPos4fvMESA)(const GLfloat * v); /* 706 */
- void (GLAPIENTRYP WindowPos4iMESA)(GLint x, GLint y, GLint z, GLint w); /* 707 */
- void (GLAPIENTRYP WindowPos4ivMESA)(const GLint * v); /* 708 */
- void (GLAPIENTRYP WindowPos4sMESA)(GLshort x, GLshort y, GLshort z, GLshort w); /* 709 */
- void (GLAPIENTRYP WindowPos4svMESA)(const GLshort * v); /* 710 */
- void (GLAPIENTRYP MultiModeDrawArraysIBM)(const GLenum * mode, const GLint * first, const GLsizei * count, GLsizei primcount, GLint modestride); /* 711 */
- void (GLAPIENTRYP MultiModeDrawElementsIBM)(const GLenum * mode, const GLsizei * count, GLenum type, const GLvoid * const * indices, GLsizei primcount, GLint modestride); /* 712 */
- void (GLAPIENTRYP DeleteFencesNV)(GLsizei n, const GLuint * fences); /* 713 */
- void (GLAPIENTRYP FinishFenceNV)(GLuint fence); /* 714 */
- void (GLAPIENTRYP GenFencesNV)(GLsizei n, GLuint * fences); /* 715 */
- void (GLAPIENTRYP GetFenceivNV)(GLuint fence, GLenum pname, GLint * params); /* 716 */
- GLboolean (GLAPIENTRYP IsFenceNV)(GLuint fence); /* 717 */
- void (GLAPIENTRYP SetFenceNV)(GLuint fence, GLenum condition); /* 718 */
- GLboolean (GLAPIENTRYP TestFenceNV)(GLuint fence); /* 719 */
- GLboolean (GLAPIENTRYP AreProgramsResidentNV)(GLsizei n, const GLuint * ids, GLboolean * residences); /* 720 */
- void (GLAPIENTRYP BindProgramNV)(GLenum target, GLuint program); /* 721 */
- void (GLAPIENTRYP DeleteProgramsNV)(GLsizei n, const GLuint * programs); /* 722 */
- void (GLAPIENTRYP ExecuteProgramNV)(GLenum target, GLuint id, const GLfloat * params); /* 723 */
- void (GLAPIENTRYP GenProgramsNV)(GLsizei n, GLuint * programs); /* 724 */
- void (GLAPIENTRYP GetProgramParameterdvNV)(GLenum target, GLuint index, GLenum pname, GLdouble * params); /* 725 */
- void (GLAPIENTRYP GetProgramParameterfvNV)(GLenum target, GLuint index, GLenum pname, GLfloat * params); /* 726 */
- void (GLAPIENTRYP GetProgramStringNV)(GLuint id, GLenum pname, GLubyte * program); /* 727 */
- void (GLAPIENTRYP GetProgramivNV)(GLuint id, GLenum pname, GLint * params); /* 728 */
- void (GLAPIENTRYP GetTrackMatrixivNV)(GLenum target, GLuint address, GLenum pname, GLint * params); /* 729 */
- void (GLAPIENTRYP GetVertexAttribPointervNV)(GLuint index, GLenum pname, GLvoid ** pointer); /* 730 */
- void (GLAPIENTRYP GetVertexAttribdvNV)(GLuint index, GLenum pname, GLdouble * params); /* 731 */
- void (GLAPIENTRYP GetVertexAttribfvNV)(GLuint index, GLenum pname, GLfloat * params); /* 732 */
- void (GLAPIENTRYP GetVertexAttribivNV)(GLuint index, GLenum pname, GLint * params); /* 733 */
- GLboolean (GLAPIENTRYP IsProgramNV)(GLuint program); /* 734 */
- void (GLAPIENTRYP LoadProgramNV)(GLenum target, GLuint id, GLsizei len, const GLubyte * program); /* 735 */
- void (GLAPIENTRYP ProgramParameters4dvNV)(GLenum target, GLuint index, GLsizei num, const GLdouble * params); /* 736 */
- void (GLAPIENTRYP ProgramParameters4fvNV)(GLenum target, GLuint index, GLsizei num, const GLfloat * params); /* 737 */
- void (GLAPIENTRYP RequestResidentProgramsNV)(GLsizei n, const GLuint * ids); /* 738 */
- void (GLAPIENTRYP TrackMatrixNV)(GLenum target, GLuint address, GLenum matrix, GLenum transform); /* 739 */
- void (GLAPIENTRYP VertexAttrib1dNV)(GLuint index, GLdouble x); /* 740 */
- void (GLAPIENTRYP VertexAttrib1dvNV)(GLuint index, const GLdouble * v); /* 741 */
- void (GLAPIENTRYP VertexAttrib1fNV)(GLuint index, GLfloat x); /* 742 */
- void (GLAPIENTRYP VertexAttrib1fvNV)(GLuint index, const GLfloat * v); /* 743 */
- void (GLAPIENTRYP VertexAttrib1sNV)(GLuint index, GLshort x); /* 744 */
- void (GLAPIENTRYP VertexAttrib1svNV)(GLuint index, const GLshort * v); /* 745 */
- void (GLAPIENTRYP VertexAttrib2dNV)(GLuint index, GLdouble x, GLdouble y); /* 746 */
- void (GLAPIENTRYP VertexAttrib2dvNV)(GLuint index, const GLdouble * v); /* 747 */
- void (GLAPIENTRYP VertexAttrib2fNV)(GLuint index, GLfloat x, GLfloat y); /* 748 */
- void (GLAPIENTRYP VertexAttrib2fvNV)(GLuint index, const GLfloat * v); /* 749 */
- void (GLAPIENTRYP VertexAttrib2sNV)(GLuint index, GLshort x, GLshort y); /* 750 */
- void (GLAPIENTRYP VertexAttrib2svNV)(GLuint index, const GLshort * v); /* 751 */
- void (GLAPIENTRYP VertexAttrib3dNV)(GLuint index, GLdouble x, GLdouble y, GLdouble z); /* 752 */
- void (GLAPIENTRYP VertexAttrib3dvNV)(GLuint index, const GLdouble * v); /* 753 */
- void (GLAPIENTRYP VertexAttrib3fNV)(GLuint index, GLfloat x, GLfloat y, GLfloat z); /* 754 */
- void (GLAPIENTRYP VertexAttrib3fvNV)(GLuint index, const GLfloat * v); /* 755 */
- void (GLAPIENTRYP VertexAttrib3sNV)(GLuint index, GLshort x, GLshort y, GLshort z); /* 756 */
- void (GLAPIENTRYP VertexAttrib3svNV)(GLuint index, const GLshort * v); /* 757 */
- void (GLAPIENTRYP VertexAttrib4dNV)(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); /* 758 */
- void (GLAPIENTRYP VertexAttrib4dvNV)(GLuint index, const GLdouble * v); /* 759 */
- void (GLAPIENTRYP VertexAttrib4fNV)(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); /* 760 */
- void (GLAPIENTRYP VertexAttrib4fvNV)(GLuint index, const GLfloat * v); /* 761 */
- void (GLAPIENTRYP VertexAttrib4sNV)(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w); /* 762 */
- void (GLAPIENTRYP VertexAttrib4svNV)(GLuint index, const GLshort * v); /* 763 */
- void (GLAPIENTRYP VertexAttrib4ubNV)(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w); /* 764 */
- void (GLAPIENTRYP VertexAttrib4ubvNV)(GLuint index, const GLubyte * v); /* 765 */
- void (GLAPIENTRYP VertexAttribPointerNV)(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid * pointer); /* 766 */
- void (GLAPIENTRYP VertexAttribs1dvNV)(GLuint index, GLsizei n, const GLdouble * v); /* 767 */
- void (GLAPIENTRYP VertexAttribs1fvNV)(GLuint index, GLsizei n, const GLfloat * v); /* 768 */
- void (GLAPIENTRYP VertexAttribs1svNV)(GLuint index, GLsizei n, const GLshort * v); /* 769 */
- void (GLAPIENTRYP VertexAttribs2dvNV)(GLuint index, GLsizei n, const GLdouble * v); /* 770 */
- void (GLAPIENTRYP VertexAttribs2fvNV)(GLuint index, GLsizei n, const GLfloat * v); /* 771 */
- void (GLAPIENTRYP VertexAttribs2svNV)(GLuint index, GLsizei n, const GLshort * v); /* 772 */
- void (GLAPIENTRYP VertexAttribs3dvNV)(GLuint index, GLsizei n, const GLdouble * v); /* 773 */
- void (GLAPIENTRYP VertexAttribs3fvNV)(GLuint index, GLsizei n, const GLfloat * v); /* 774 */
- void (GLAPIENTRYP VertexAttribs3svNV)(GLuint index, GLsizei n, const GLshort * v); /* 775 */
- void (GLAPIENTRYP VertexAttribs4dvNV)(GLuint index, GLsizei n, const GLdouble * v); /* 776 */
- void (GLAPIENTRYP VertexAttribs4fvNV)(GLuint index, GLsizei n, const GLfloat * v); /* 777 */
- void (GLAPIENTRYP VertexAttribs4svNV)(GLuint index, GLsizei n, const GLshort * v); /* 778 */
- void (GLAPIENTRYP VertexAttribs4ubvNV)(GLuint index, GLsizei n, const GLubyte * v); /* 779 */
- void (GLAPIENTRYP GetTexBumpParameterfvATI)(GLenum pname, GLfloat * param); /* 780 */
- void (GLAPIENTRYP GetTexBumpParameterivATI)(GLenum pname, GLint * param); /* 781 */
- void (GLAPIENTRYP TexBumpParameterfvATI)(GLenum pname, const GLfloat * param); /* 782 */
- void (GLAPIENTRYP TexBumpParameterivATI)(GLenum pname, const GLint * param); /* 783 */
- void (GLAPIENTRYP AlphaFragmentOp1ATI)(GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod); /* 784 */
- void (GLAPIENTRYP AlphaFragmentOp2ATI)(GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod); /* 785 */
- void (GLAPIENTRYP AlphaFragmentOp3ATI)(GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod, GLuint arg3, GLuint arg3Rep, GLuint arg3Mod); /* 786 */
- void (GLAPIENTRYP BeginFragmentShaderATI)(void); /* 787 */
- void (GLAPIENTRYP BindFragmentShaderATI)(GLuint id); /* 788 */
- void (GLAPIENTRYP ColorFragmentOp1ATI)(GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod); /* 789 */
- void (GLAPIENTRYP ColorFragmentOp2ATI)(GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod); /* 790 */
- void (GLAPIENTRYP ColorFragmentOp3ATI)(GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod, GLuint arg3, GLuint arg3Rep, GLuint arg3Mod); /* 791 */
- void (GLAPIENTRYP DeleteFragmentShaderATI)(GLuint id); /* 792 */
- void (GLAPIENTRYP EndFragmentShaderATI)(void); /* 793 */
- GLuint (GLAPIENTRYP GenFragmentShadersATI)(GLuint range); /* 794 */
- void (GLAPIENTRYP PassTexCoordATI)(GLuint dst, GLuint coord, GLenum swizzle); /* 795 */
- void (GLAPIENTRYP SampleMapATI)(GLuint dst, GLuint interp, GLenum swizzle); /* 796 */
- void (GLAPIENTRYP SetFragmentShaderConstantATI)(GLuint dst, const GLfloat * value); /* 797 */
- void (GLAPIENTRYP PointParameteriNV)(GLenum pname, GLint param); /* 798 */
- void (GLAPIENTRYP PointParameterivNV)(GLenum pname, const GLint * params); /* 799 */
- void (GLAPIENTRYP ActiveStencilFaceEXT)(GLenum face); /* 800 */
- void (GLAPIENTRYP BindVertexArrayAPPLE)(GLuint array); /* 801 */
- void (GLAPIENTRYP DeleteVertexArraysAPPLE)(GLsizei n, const GLuint * arrays); /* 802 */
- void (GLAPIENTRYP GenVertexArraysAPPLE)(GLsizei n, GLuint * arrays); /* 803 */
- GLboolean (GLAPIENTRYP IsVertexArrayAPPLE)(GLuint array); /* 804 */
- void (GLAPIENTRYP GetProgramNamedParameterdvNV)(GLuint id, GLsizei len, const GLubyte * name, GLdouble * params); /* 805 */
- void (GLAPIENTRYP GetProgramNamedParameterfvNV)(GLuint id, GLsizei len, const GLubyte * name, GLfloat * params); /* 806 */
- void (GLAPIENTRYP ProgramNamedParameter4dNV)(GLuint id, GLsizei len, const GLubyte * name, GLdouble x, GLdouble y, GLdouble z, GLdouble w); /* 807 */
- void (GLAPIENTRYP ProgramNamedParameter4dvNV)(GLuint id, GLsizei len, const GLubyte * name, const GLdouble * v); /* 808 */
- void (GLAPIENTRYP ProgramNamedParameter4fNV)(GLuint id, GLsizei len, const GLubyte * name, GLfloat x, GLfloat y, GLfloat z, GLfloat w); /* 809 */
- void (GLAPIENTRYP ProgramNamedParameter4fvNV)(GLuint id, GLsizei len, const GLubyte * name, const GLfloat * v); /* 810 */
- void (GLAPIENTRYP PrimitiveRestartIndexNV)(GLuint index); /* 811 */
- void (GLAPIENTRYP PrimitiveRestartNV)(void); /* 812 */
- void (GLAPIENTRYP DepthBoundsEXT)(GLclampd zmin, GLclampd zmax); /* 813 */
- void (GLAPIENTRYP BlendEquationSeparateEXT)(GLenum modeRGB, GLenum modeA); /* 814 */
- void (GLAPIENTRYP BindFramebufferEXT)(GLenum target, GLuint framebuffer); /* 815 */
- void (GLAPIENTRYP BindRenderbufferEXT)(GLenum target, GLuint renderbuffer); /* 816 */
- GLenum (GLAPIENTRYP CheckFramebufferStatusEXT)(GLenum target); /* 817 */
- void (GLAPIENTRYP DeleteFramebuffersEXT)(GLsizei n, const GLuint * framebuffers); /* 818 */
- void (GLAPIENTRYP DeleteRenderbuffersEXT)(GLsizei n, const GLuint * renderbuffers); /* 819 */
- void (GLAPIENTRYP FramebufferRenderbufferEXT)(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer); /* 820 */
- void (GLAPIENTRYP FramebufferTexture1DEXT)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); /* 821 */
- void (GLAPIENTRYP FramebufferTexture2DEXT)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); /* 822 */
- void (GLAPIENTRYP FramebufferTexture3DEXT)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset); /* 823 */
- void (GLAPIENTRYP GenFramebuffersEXT)(GLsizei n, GLuint * framebuffers); /* 824 */
- void (GLAPIENTRYP GenRenderbuffersEXT)(GLsizei n, GLuint * renderbuffers); /* 825 */
- void (GLAPIENTRYP GenerateMipmapEXT)(GLenum target); /* 826 */
- void (GLAPIENTRYP GetFramebufferAttachmentParameterivEXT)(GLenum target, GLenum attachment, GLenum pname, GLint * params); /* 827 */
- void (GLAPIENTRYP GetRenderbufferParameterivEXT)(GLenum target, GLenum pname, GLint * params); /* 828 */
- GLboolean (GLAPIENTRYP IsFramebufferEXT)(GLuint framebuffer); /* 829 */
- GLboolean (GLAPIENTRYP IsRenderbufferEXT)(GLuint renderbuffer); /* 830 */
- void (GLAPIENTRYP RenderbufferStorageEXT)(GLenum target, GLenum internalformat, GLsizei width, GLsizei height); /* 831 */
- void (GLAPIENTRYP BlitFramebufferEXT)(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter); /* 832 */
- void (GLAPIENTRYP BufferParameteriAPPLE)(GLenum target, GLenum pname, GLint param); /* 833 */
- void (GLAPIENTRYP FlushMappedBufferRangeAPPLE)(GLenum target, GLintptr offset, GLsizeiptr size); /* 834 */
- void (GLAPIENTRYP BindFragDataLocationEXT)(GLuint program, GLuint colorNumber, const GLchar * name); /* 835 */
- GLint (GLAPIENTRYP GetFragDataLocationEXT)(GLuint program, const GLchar * name); /* 836 */
- void (GLAPIENTRYP GetUniformuivEXT)(GLuint program, GLint location, GLuint * params); /* 837 */
- void (GLAPIENTRYP GetVertexAttribIivEXT)(GLuint index, GLenum pname, GLint * params); /* 838 */
- void (GLAPIENTRYP GetVertexAttribIuivEXT)(GLuint index, GLenum pname, GLuint * params); /* 839 */
- void (GLAPIENTRYP Uniform1uiEXT)(GLint location, GLuint x); /* 840 */
- void (GLAPIENTRYP Uniform1uivEXT)(GLint location, GLsizei count, const GLuint * value); /* 841 */
- void (GLAPIENTRYP Uniform2uiEXT)(GLint location, GLuint x, GLuint y); /* 842 */
- void (GLAPIENTRYP Uniform2uivEXT)(GLint location, GLsizei count, const GLuint * value); /* 843 */
- void (GLAPIENTRYP Uniform3uiEXT)(GLint location, GLuint x, GLuint y, GLuint z); /* 844 */
- void (GLAPIENTRYP Uniform3uivEXT)(GLint location, GLsizei count, const GLuint * value); /* 845 */
- void (GLAPIENTRYP Uniform4uiEXT)(GLint location, GLuint x, GLuint y, GLuint z, GLuint w); /* 846 */
- void (GLAPIENTRYP Uniform4uivEXT)(GLint location, GLsizei count, const GLuint * value); /* 847 */
- void (GLAPIENTRYP VertexAttribI1iEXT)(GLuint index, GLint x); /* 848 */
- void (GLAPIENTRYP VertexAttribI1ivEXT)(GLuint index, const GLint * v); /* 849 */
- void (GLAPIENTRYP VertexAttribI1uiEXT)(GLuint index, GLuint x); /* 850 */
- void (GLAPIENTRYP VertexAttribI1uivEXT)(GLuint index, const GLuint * v); /* 851 */
- void (GLAPIENTRYP VertexAttribI2iEXT)(GLuint index, GLint x, GLint y); /* 852 */
- void (GLAPIENTRYP VertexAttribI2ivEXT)(GLuint index, const GLint * v); /* 853 */
- void (GLAPIENTRYP VertexAttribI2uiEXT)(GLuint index, GLuint x, GLuint y); /* 854 */
- void (GLAPIENTRYP VertexAttribI2uivEXT)(GLuint index, const GLuint * v); /* 855 */
- void (GLAPIENTRYP VertexAttribI3iEXT)(GLuint index, GLint x, GLint y, GLint z); /* 856 */
- void (GLAPIENTRYP VertexAttribI3ivEXT)(GLuint index, const GLint * v); /* 857 */
- void (GLAPIENTRYP VertexAttribI3uiEXT)(GLuint index, GLuint x, GLuint y, GLuint z); /* 858 */
- void (GLAPIENTRYP VertexAttribI3uivEXT)(GLuint index, const GLuint * v); /* 859 */
- void (GLAPIENTRYP VertexAttribI4bvEXT)(GLuint index, const GLbyte * v); /* 860 */
- void (GLAPIENTRYP VertexAttribI4iEXT)(GLuint index, GLint x, GLint y, GLint z, GLint w); /* 861 */
- void (GLAPIENTRYP VertexAttribI4ivEXT)(GLuint index, const GLint * v); /* 862 */
- void (GLAPIENTRYP VertexAttribI4svEXT)(GLuint index, const GLshort * v); /* 863 */
- void (GLAPIENTRYP VertexAttribI4ubvEXT)(GLuint index, const GLubyte * v); /* 864 */
- void (GLAPIENTRYP VertexAttribI4uiEXT)(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w); /* 865 */
- void (GLAPIENTRYP VertexAttribI4uivEXT)(GLuint index, const GLuint * v); /* 866 */
- void (GLAPIENTRYP VertexAttribI4usvEXT)(GLuint index, const GLushort * v); /* 867 */
- void (GLAPIENTRYP VertexAttribIPointerEXT)(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid * pointer); /* 868 */
- void (GLAPIENTRYP FramebufferTextureLayerEXT)(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer); /* 869 */
- void (GLAPIENTRYP ColorMaskIndexedEXT)(GLuint buf, GLboolean r, GLboolean g, GLboolean b, GLboolean a); /* 870 */
- void (GLAPIENTRYP DisableIndexedEXT)(GLenum target, GLuint index); /* 871 */
- void (GLAPIENTRYP EnableIndexedEXT)(GLenum target, GLuint index); /* 872 */
- void (GLAPIENTRYP GetBooleanIndexedvEXT)(GLenum value, GLuint index, GLboolean * data); /* 873 */
- void (GLAPIENTRYP GetIntegerIndexedvEXT)(GLenum value, GLuint index, GLint * data); /* 874 */
- GLboolean (GLAPIENTRYP IsEnabledIndexedEXT)(GLenum target, GLuint index); /* 875 */
- void (GLAPIENTRYP ClearColorIiEXT)(GLint r, GLint g, GLint b, GLint a); /* 876 */
- void (GLAPIENTRYP ClearColorIuiEXT)(GLuint r, GLuint g, GLuint b, GLuint a); /* 877 */
- void (GLAPIENTRYP GetTexParameterIivEXT)(GLenum target, GLenum pname, GLint * params); /* 878 */
- void (GLAPIENTRYP GetTexParameterIuivEXT)(GLenum target, GLenum pname, GLuint * params); /* 879 */
- void (GLAPIENTRYP TexParameterIivEXT)(GLenum target, GLenum pname, const GLint * params); /* 880 */
- void (GLAPIENTRYP TexParameterIuivEXT)(GLenum target, GLenum pname, const GLuint * params); /* 881 */
- void (GLAPIENTRYP BeginConditionalRenderNV)(GLuint query, GLenum mode); /* 882 */
- void (GLAPIENTRYP EndConditionalRenderNV)(void); /* 883 */
- void (GLAPIENTRYP BeginTransformFeedbackEXT)(GLenum mode); /* 884 */
- void (GLAPIENTRYP BindBufferBaseEXT)(GLenum target, GLuint index, GLuint buffer); /* 885 */
- void (GLAPIENTRYP BindBufferOffsetEXT)(GLenum target, GLuint index, GLuint buffer, GLintptr offset); /* 886 */
- void (GLAPIENTRYP BindBufferRangeEXT)(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size); /* 887 */
- void (GLAPIENTRYP EndTransformFeedbackEXT)(void); /* 888 */
- void (GLAPIENTRYP GetTransformFeedbackVaryingEXT)(GLuint program, GLuint index, GLsizei bufSize, GLsizei * length, GLsizei * size, GLenum * type, GLchar * name); /* 889 */
- void (GLAPIENTRYP TransformFeedbackVaryingsEXT)(GLuint program, GLsizei count, const char ** varyings, GLenum bufferMode); /* 890 */
- void (GLAPIENTRYP ProvokingVertexEXT)(GLenum mode); /* 891 */
- void (GLAPIENTRYP GetTexParameterPointervAPPLE)(GLenum target, GLenum pname, GLvoid ** params); /* 892 */
- void (GLAPIENTRYP TextureRangeAPPLE)(GLenum target, GLsizei length, GLvoid * pointer); /* 893 */
- void (GLAPIENTRYP GetObjectParameterivAPPLE)(GLenum objectType, GLuint name, GLenum pname, GLint * value); /* 894 */
- GLenum (GLAPIENTRYP ObjectPurgeableAPPLE)(GLenum objectType, GLuint name, GLenum option); /* 895 */
- GLenum (GLAPIENTRYP ObjectUnpurgeableAPPLE)(GLenum objectType, GLuint name, GLenum option); /* 896 */
- void (GLAPIENTRYP ActiveProgramEXT)(GLuint program); /* 897 */
- GLuint (GLAPIENTRYP CreateShaderProgramEXT)(GLenum type, const GLchar * string); /* 898 */
- void (GLAPIENTRYP UseShaderProgramEXT)(GLenum type, GLuint program); /* 899 */
- void (GLAPIENTRYP TextureBarrierNV)(void); /* 900 */
- void (GLAPIENTRYP StencilFuncSeparateATI)(GLenum frontfunc, GLenum backfunc, GLint ref, GLuint mask); /* 901 */
- void (GLAPIENTRYP ProgramEnvParameters4fvEXT)(GLenum target, GLuint index, GLsizei count, const GLfloat * params); /* 902 */
- void (GLAPIENTRYP ProgramLocalParameters4fvEXT)(GLenum target, GLuint index, GLsizei count, const GLfloat * params); /* 903 */
- void (GLAPIENTRYP GetQueryObjecti64vEXT)(GLuint id, GLenum pname, GLint64EXT * params); /* 904 */
- void (GLAPIENTRYP GetQueryObjectui64vEXT)(GLuint id, GLenum pname, GLuint64EXT * params); /* 905 */
- void (GLAPIENTRYP EGLImageTargetRenderbufferStorageOES)(GLenum target, GLvoid * writeOffset); /* 906 */
- void (GLAPIENTRYP EGLImageTargetTexture2DOES)(GLenum target, GLvoid * writeOffset); /* 907 */
+ GLenum (GLAPIENTRYP GetGraphicsResetStatusARB)(void); /* 626 */
+ void (GLAPIENTRYP GetnColorTableARB)(GLenum target, GLenum format, GLenum type, GLsizei bufSize, GLvoid * table); /* 627 */
+ void (GLAPIENTRYP GetnCompressedTexImageARB)(GLenum target, GLint lod, GLsizei bufSize, GLvoid * img); /* 628 */
+ void (GLAPIENTRYP GetnConvolutionFilterARB)(GLenum target, GLenum format, GLenum type, GLsizei bufSize, GLvoid * image); /* 629 */
+ void (GLAPIENTRYP GetnHistogramARB)(GLenum target, GLboolean reset, GLenum format, GLenum type, GLsizei bufSize, GLvoid * values); /* 630 */
+ void (GLAPIENTRYP GetnMapdvARB)(GLenum target, GLenum query, GLsizei bufSize, GLdouble * v); /* 631 */
+ void (GLAPIENTRYP GetnMapfvARB)(GLenum target, GLenum query, GLsizei bufSize, GLfloat * v); /* 632 */
+ void (GLAPIENTRYP GetnMapivARB)(GLenum target, GLenum query, GLsizei bufSize, GLint * v); /* 633 */
+ void (GLAPIENTRYP GetnMinmaxARB)(GLenum target, GLboolean reset, GLenum format, GLenum type, GLsizei bufSize, GLvoid * values); /* 634 */
+ void (GLAPIENTRYP GetnPixelMapfvARB)(GLenum map, GLsizei bufSize, GLfloat * values); /* 635 */
+ void (GLAPIENTRYP GetnPixelMapuivARB)(GLenum map, GLsizei bufSize, GLuint * values); /* 636 */
+ void (GLAPIENTRYP GetnPixelMapusvARB)(GLenum map, GLsizei bufSize, GLushort * values); /* 637 */
+ void (GLAPIENTRYP GetnPolygonStippleARB)(GLsizei bufSize, GLubyte * pattern); /* 638 */
+ void (GLAPIENTRYP GetnSeparableFilterARB)(GLenum target, GLenum format, GLenum type, GLsizei rowBufSize, GLvoid * row, GLsizei columnBufSize, GLvoid * column, GLvoid * span); /* 639 */
+ void (GLAPIENTRYP GetnTexImageARB)(GLenum target, GLint level, GLenum format, GLenum type, GLsizei bufSize, GLvoid * img); /* 640 */
+ void (GLAPIENTRYP GetnUniformdvARB)(GLhandleARB program, GLint location, GLsizei bufSize, GLdouble * params); /* 641 */
+ void (GLAPIENTRYP GetnUniformfvARB)(GLhandleARB program, GLint location, GLsizei bufSize, GLfloat * params); /* 642 */
+ void (GLAPIENTRYP GetnUniformivARB)(GLhandleARB program, GLint location, GLsizei bufSize, GLint * params); /* 643 */
+ void (GLAPIENTRYP GetnUniformuivARB)(GLhandleARB program, GLint location, GLsizei bufSize, GLuint * params); /* 644 */
+ void (GLAPIENTRYP ReadnPixelsARB)(GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLsizei bufSize, GLvoid * data); /* 645 */
+ void (GLAPIENTRYP PolygonOffsetEXT)(GLfloat factor, GLfloat bias); /* 646 */
+ void (GLAPIENTRYP GetPixelTexGenParameterfvSGIS)(GLenum pname, GLfloat * params); /* 647 */
+ void (GLAPIENTRYP GetPixelTexGenParameterivSGIS)(GLenum pname, GLint * params); /* 648 */
+ void (GLAPIENTRYP PixelTexGenParameterfSGIS)(GLenum pname, GLfloat param); /* 649 */
+ void (GLAPIENTRYP PixelTexGenParameterfvSGIS)(GLenum pname, const GLfloat * params); /* 650 */
+ void (GLAPIENTRYP PixelTexGenParameteriSGIS)(GLenum pname, GLint param); /* 651 */
+ void (GLAPIENTRYP PixelTexGenParameterivSGIS)(GLenum pname, const GLint * params); /* 652 */
+ void (GLAPIENTRYP SampleMaskSGIS)(GLclampf value, GLboolean invert); /* 653 */
+ void (GLAPIENTRYP SamplePatternSGIS)(GLenum pattern); /* 654 */
+ void (GLAPIENTRYP ColorPointerEXT)(GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid * pointer); /* 655 */
+ void (GLAPIENTRYP EdgeFlagPointerEXT)(GLsizei stride, GLsizei count, const GLboolean * pointer); /* 656 */
+ void (GLAPIENTRYP IndexPointerEXT)(GLenum type, GLsizei stride, GLsizei count, const GLvoid * pointer); /* 657 */
+ void (GLAPIENTRYP NormalPointerEXT)(GLenum type, GLsizei stride, GLsizei count, const GLvoid * pointer); /* 658 */
+ void (GLAPIENTRYP TexCoordPointerEXT)(GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid * pointer); /* 659 */
+ void (GLAPIENTRYP VertexPointerEXT)(GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid * pointer); /* 660 */
+ void (GLAPIENTRYP PointParameterfEXT)(GLenum pname, GLfloat param); /* 661 */
+ void (GLAPIENTRYP PointParameterfvEXT)(GLenum pname, const GLfloat * params); /* 662 */
+ void (GLAPIENTRYP LockArraysEXT)(GLint first, GLsizei count); /* 663 */
+ void (GLAPIENTRYP UnlockArraysEXT)(void); /* 664 */
+ void (GLAPIENTRYP SecondaryColor3bEXT)(GLbyte red, GLbyte green, GLbyte blue); /* 665 */
+ void (GLAPIENTRYP SecondaryColor3bvEXT)(const GLbyte * v); /* 666 */
+ void (GLAPIENTRYP SecondaryColor3dEXT)(GLdouble red, GLdouble green, GLdouble blue); /* 667 */
+ void (GLAPIENTRYP SecondaryColor3dvEXT)(const GLdouble * v); /* 668 */
+ void (GLAPIENTRYP SecondaryColor3fEXT)(GLfloat red, GLfloat green, GLfloat blue); /* 669 */
+ void (GLAPIENTRYP SecondaryColor3fvEXT)(const GLfloat * v); /* 670 */
+ void (GLAPIENTRYP SecondaryColor3iEXT)(GLint red, GLint green, GLint blue); /* 671 */
+ void (GLAPIENTRYP SecondaryColor3ivEXT)(const GLint * v); /* 672 */
+ void (GLAPIENTRYP SecondaryColor3sEXT)(GLshort red, GLshort green, GLshort blue); /* 673 */
+ void (GLAPIENTRYP SecondaryColor3svEXT)(const GLshort * v); /* 674 */
+ void (GLAPIENTRYP SecondaryColor3ubEXT)(GLubyte red, GLubyte green, GLubyte blue); /* 675 */
+ void (GLAPIENTRYP SecondaryColor3ubvEXT)(const GLubyte * v); /* 676 */
+ void (GLAPIENTRYP SecondaryColor3uiEXT)(GLuint red, GLuint green, GLuint blue); /* 677 */
+ void (GLAPIENTRYP SecondaryColor3uivEXT)(const GLuint * v); /* 678 */
+ void (GLAPIENTRYP SecondaryColor3usEXT)(GLushort red, GLushort green, GLushort blue); /* 679 */
+ void (GLAPIENTRYP SecondaryColor3usvEXT)(const GLushort * v); /* 680 */
+ void (GLAPIENTRYP SecondaryColorPointerEXT)(GLint size, GLenum type, GLsizei stride, const GLvoid * pointer); /* 681 */
+ void (GLAPIENTRYP MultiDrawArraysEXT)(GLenum mode, const GLint * first, const GLsizei * count, GLsizei primcount); /* 682 */
+ void (GLAPIENTRYP MultiDrawElementsEXT)(GLenum mode, const GLsizei * count, GLenum type, const GLvoid ** indices, GLsizei primcount); /* 683 */
+ void (GLAPIENTRYP FogCoordPointerEXT)(GLenum type, GLsizei stride, const GLvoid * pointer); /* 684 */
+ void (GLAPIENTRYP FogCoorddEXT)(GLdouble coord); /* 685 */
+ void (GLAPIENTRYP FogCoorddvEXT)(const GLdouble * coord); /* 686 */
+ void (GLAPIENTRYP FogCoordfEXT)(GLfloat coord); /* 687 */
+ void (GLAPIENTRYP FogCoordfvEXT)(const GLfloat * coord); /* 688 */
+ void (GLAPIENTRYP PixelTexGenSGIX)(GLenum mode); /* 689 */
+ void (GLAPIENTRYP BlendFuncSeparateEXT)(GLenum sfactorRGB, GLenum dfactorRGB, GLenum sfactorAlpha, GLenum dfactorAlpha); /* 690 */
+ void (GLAPIENTRYP FlushVertexArrayRangeNV)(void); /* 691 */
+ void (GLAPIENTRYP VertexArrayRangeNV)(GLsizei length, const GLvoid * pointer); /* 692 */
+ void (GLAPIENTRYP CombinerInputNV)(GLenum stage, GLenum portion, GLenum variable, GLenum input, GLenum mapping, GLenum componentUsage); /* 693 */
+ void (GLAPIENTRYP CombinerOutputNV)(GLenum stage, GLenum portion, GLenum abOutput, GLenum cdOutput, GLenum sumOutput, GLenum scale, GLenum bias, GLboolean abDotProduct, GLboolean cdDotProduct, GLboolean muxSum); /* 694 */
+ void (GLAPIENTRYP CombinerParameterfNV)(GLenum pname, GLfloat param); /* 695 */
+ void (GLAPIENTRYP CombinerParameterfvNV)(GLenum pname, const GLfloat * params); /* 696 */
+ void (GLAPIENTRYP CombinerParameteriNV)(GLenum pname, GLint param); /* 697 */
+ void (GLAPIENTRYP CombinerParameterivNV)(GLenum pname, const GLint * params); /* 698 */
+ void (GLAPIENTRYP FinalCombinerInputNV)(GLenum variable, GLenum input, GLenum mapping, GLenum componentUsage); /* 699 */
+ void (GLAPIENTRYP GetCombinerInputParameterfvNV)(GLenum stage, GLenum portion, GLenum variable, GLenum pname, GLfloat * params); /* 700 */
+ void (GLAPIENTRYP GetCombinerInputParameterivNV)(GLenum stage, GLenum portion, GLenum variable, GLenum pname, GLint * params); /* 701 */
+ void (GLAPIENTRYP GetCombinerOutputParameterfvNV)(GLenum stage, GLenum portion, GLenum pname, GLfloat * params); /* 702 */
+ void (GLAPIENTRYP GetCombinerOutputParameterivNV)(GLenum stage, GLenum portion, GLenum pname, GLint * params); /* 703 */
+ void (GLAPIENTRYP GetFinalCombinerInputParameterfvNV)(GLenum variable, GLenum pname, GLfloat * params); /* 704 */
+ void (GLAPIENTRYP GetFinalCombinerInputParameterivNV)(GLenum variable, GLenum pname, GLint * params); /* 705 */
+ void (GLAPIENTRYP ResizeBuffersMESA)(void); /* 706 */
+ void (GLAPIENTRYP WindowPos2dMESA)(GLdouble x, GLdouble y); /* 707 */
+ void (GLAPIENTRYP WindowPos2dvMESA)(const GLdouble * v); /* 708 */
+ void (GLAPIENTRYP WindowPos2fMESA)(GLfloat x, GLfloat y); /* 709 */
+ void (GLAPIENTRYP WindowPos2fvMESA)(const GLfloat * v); /* 710 */
+ void (GLAPIENTRYP WindowPos2iMESA)(GLint x, GLint y); /* 711 */
+ void (GLAPIENTRYP WindowPos2ivMESA)(const GLint * v); /* 712 */
+ void (GLAPIENTRYP WindowPos2sMESA)(GLshort x, GLshort y); /* 713 */
+ void (GLAPIENTRYP WindowPos2svMESA)(const GLshort * v); /* 714 */
+ void (GLAPIENTRYP WindowPos3dMESA)(GLdouble x, GLdouble y, GLdouble z); /* 715 */
+ void (GLAPIENTRYP WindowPos3dvMESA)(const GLdouble * v); /* 716 */
+ void (GLAPIENTRYP WindowPos3fMESA)(GLfloat x, GLfloat y, GLfloat z); /* 717 */
+ void (GLAPIENTRYP WindowPos3fvMESA)(const GLfloat * v); /* 718 */
+ void (GLAPIENTRYP WindowPos3iMESA)(GLint x, GLint y, GLint z); /* 719 */
+ void (GLAPIENTRYP WindowPos3ivMESA)(const GLint * v); /* 720 */
+ void (GLAPIENTRYP WindowPos3sMESA)(GLshort x, GLshort y, GLshort z); /* 721 */
+ void (GLAPIENTRYP WindowPos3svMESA)(const GLshort * v); /* 722 */
+ void (GLAPIENTRYP WindowPos4dMESA)(GLdouble x, GLdouble y, GLdouble z, GLdouble w); /* 723 */
+ void (GLAPIENTRYP WindowPos4dvMESA)(const GLdouble * v); /* 724 */
+ void (GLAPIENTRYP WindowPos4fMESA)(GLfloat x, GLfloat y, GLfloat z, GLfloat w); /* 725 */
+ void (GLAPIENTRYP WindowPos4fvMESA)(const GLfloat * v); /* 726 */
+ void (GLAPIENTRYP WindowPos4iMESA)(GLint x, GLint y, GLint z, GLint w); /* 727 */
+ void (GLAPIENTRYP WindowPos4ivMESA)(const GLint * v); /* 728 */
+ void (GLAPIENTRYP WindowPos4sMESA)(GLshort x, GLshort y, GLshort z, GLshort w); /* 729 */
+ void (GLAPIENTRYP WindowPos4svMESA)(const GLshort * v); /* 730 */
+ void (GLAPIENTRYP MultiModeDrawArraysIBM)(const GLenum * mode, const GLint * first, const GLsizei * count, GLsizei primcount, GLint modestride); /* 731 */
+ void (GLAPIENTRYP MultiModeDrawElementsIBM)(const GLenum * mode, const GLsizei * count, GLenum type, const GLvoid * const * indices, GLsizei primcount, GLint modestride); /* 732 */
+ void (GLAPIENTRYP DeleteFencesNV)(GLsizei n, const GLuint * fences); /* 733 */
+ void (GLAPIENTRYP FinishFenceNV)(GLuint fence); /* 734 */
+ void (GLAPIENTRYP GenFencesNV)(GLsizei n, GLuint * fences); /* 735 */
+ void (GLAPIENTRYP GetFenceivNV)(GLuint fence, GLenum pname, GLint * params); /* 736 */
+ GLboolean (GLAPIENTRYP IsFenceNV)(GLuint fence); /* 737 */
+ void (GLAPIENTRYP SetFenceNV)(GLuint fence, GLenum condition); /* 738 */
+ GLboolean (GLAPIENTRYP TestFenceNV)(GLuint fence); /* 739 */
+ GLboolean (GLAPIENTRYP AreProgramsResidentNV)(GLsizei n, const GLuint * ids, GLboolean * residences); /* 740 */
+ void (GLAPIENTRYP BindProgramNV)(GLenum target, GLuint program); /* 741 */
+ void (GLAPIENTRYP DeleteProgramsNV)(GLsizei n, const GLuint * programs); /* 742 */
+ void (GLAPIENTRYP ExecuteProgramNV)(GLenum target, GLuint id, const GLfloat * params); /* 743 */
+ void (GLAPIENTRYP GenProgramsNV)(GLsizei n, GLuint * programs); /* 744 */
+ void (GLAPIENTRYP GetProgramParameterdvNV)(GLenum target, GLuint index, GLenum pname, GLdouble * params); /* 745 */
+ void (GLAPIENTRYP GetProgramParameterfvNV)(GLenum target, GLuint index, GLenum pname, GLfloat * params); /* 746 */
+ void (GLAPIENTRYP GetProgramStringNV)(GLuint id, GLenum pname, GLubyte * program); /* 747 */
+ void (GLAPIENTRYP GetProgramivNV)(GLuint id, GLenum pname, GLint * params); /* 748 */
+ void (GLAPIENTRYP GetTrackMatrixivNV)(GLenum target, GLuint address, GLenum pname, GLint * params); /* 749 */
+ void (GLAPIENTRYP GetVertexAttribPointervNV)(GLuint index, GLenum pname, GLvoid ** pointer); /* 750 */
+ void (GLAPIENTRYP GetVertexAttribdvNV)(GLuint index, GLenum pname, GLdouble * params); /* 751 */
+ void (GLAPIENTRYP GetVertexAttribfvNV)(GLuint index, GLenum pname, GLfloat * params); /* 752 */
+ void (GLAPIENTRYP GetVertexAttribivNV)(GLuint index, GLenum pname, GLint * params); /* 753 */
+ GLboolean (GLAPIENTRYP IsProgramNV)(GLuint program); /* 754 */
+ void (GLAPIENTRYP LoadProgramNV)(GLenum target, GLuint id, GLsizei len, const GLubyte * program); /* 755 */
+ void (GLAPIENTRYP ProgramParameters4dvNV)(GLenum target, GLuint index, GLsizei num, const GLdouble * params); /* 756 */
+ void (GLAPIENTRYP ProgramParameters4fvNV)(GLenum target, GLuint index, GLsizei num, const GLfloat * params); /* 757 */
+ void (GLAPIENTRYP RequestResidentProgramsNV)(GLsizei n, const GLuint * ids); /* 758 */
+ void (GLAPIENTRYP TrackMatrixNV)(GLenum target, GLuint address, GLenum matrix, GLenum transform); /* 759 */
+ void (GLAPIENTRYP VertexAttrib1dNV)(GLuint index, GLdouble x); /* 760 */
+ void (GLAPIENTRYP VertexAttrib1dvNV)(GLuint index, const GLdouble * v); /* 761 */
+ void (GLAPIENTRYP VertexAttrib1fNV)(GLuint index, GLfloat x); /* 762 */
+ void (GLAPIENTRYP VertexAttrib1fvNV)(GLuint index, const GLfloat * v); /* 763 */
+ void (GLAPIENTRYP VertexAttrib1sNV)(GLuint index, GLshort x); /* 764 */
+ void (GLAPIENTRYP VertexAttrib1svNV)(GLuint index, const GLshort * v); /* 765 */
+ void (GLAPIENTRYP VertexAttrib2dNV)(GLuint index, GLdouble x, GLdouble y); /* 766 */
+ void (GLAPIENTRYP VertexAttrib2dvNV)(GLuint index, const GLdouble * v); /* 767 */
+ void (GLAPIENTRYP VertexAttrib2fNV)(GLuint index, GLfloat x, GLfloat y); /* 768 */
+ void (GLAPIENTRYP VertexAttrib2fvNV)(GLuint index, const GLfloat * v); /* 769 */
+ void (GLAPIENTRYP VertexAttrib2sNV)(GLuint index, GLshort x, GLshort y); /* 770 */
+ void (GLAPIENTRYP VertexAttrib2svNV)(GLuint index, const GLshort * v); /* 771 */
+ void (GLAPIENTRYP VertexAttrib3dNV)(GLuint index, GLdouble x, GLdouble y, GLdouble z); /* 772 */
+ void (GLAPIENTRYP VertexAttrib3dvNV)(GLuint index, const GLdouble * v); /* 773 */
+ void (GLAPIENTRYP VertexAttrib3fNV)(GLuint index, GLfloat x, GLfloat y, GLfloat z); /* 774 */
+ void (GLAPIENTRYP VertexAttrib3fvNV)(GLuint index, const GLfloat * v); /* 775 */
+ void (GLAPIENTRYP VertexAttrib3sNV)(GLuint index, GLshort x, GLshort y, GLshort z); /* 776 */
+ void (GLAPIENTRYP VertexAttrib3svNV)(GLuint index, const GLshort * v); /* 777 */
+ void (GLAPIENTRYP VertexAttrib4dNV)(GLuint index, GLdouble x, GLdouble y, GLdouble z, GLdouble w); /* 778 */
+ void (GLAPIENTRYP VertexAttrib4dvNV)(GLuint index, const GLdouble * v); /* 779 */
+ void (GLAPIENTRYP VertexAttrib4fNV)(GLuint index, GLfloat x, GLfloat y, GLfloat z, GLfloat w); /* 780 */
+ void (GLAPIENTRYP VertexAttrib4fvNV)(GLuint index, const GLfloat * v); /* 781 */
+ void (GLAPIENTRYP VertexAttrib4sNV)(GLuint index, GLshort x, GLshort y, GLshort z, GLshort w); /* 782 */
+ void (GLAPIENTRYP VertexAttrib4svNV)(GLuint index, const GLshort * v); /* 783 */
+ void (GLAPIENTRYP VertexAttrib4ubNV)(GLuint index, GLubyte x, GLubyte y, GLubyte z, GLubyte w); /* 784 */
+ void (GLAPIENTRYP VertexAttrib4ubvNV)(GLuint index, const GLubyte * v); /* 785 */
+ void (GLAPIENTRYP VertexAttribPointerNV)(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid * pointer); /* 786 */
+ void (GLAPIENTRYP VertexAttribs1dvNV)(GLuint index, GLsizei n, const GLdouble * v); /* 787 */
+ void (GLAPIENTRYP VertexAttribs1fvNV)(GLuint index, GLsizei n, const GLfloat * v); /* 788 */
+ void (GLAPIENTRYP VertexAttribs1svNV)(GLuint index, GLsizei n, const GLshort * v); /* 789 */
+ void (GLAPIENTRYP VertexAttribs2dvNV)(GLuint index, GLsizei n, const GLdouble * v); /* 790 */
+ void (GLAPIENTRYP VertexAttribs2fvNV)(GLuint index, GLsizei n, const GLfloat * v); /* 791 */
+ void (GLAPIENTRYP VertexAttribs2svNV)(GLuint index, GLsizei n, const GLshort * v); /* 792 */
+ void (GLAPIENTRYP VertexAttribs3dvNV)(GLuint index, GLsizei n, const GLdouble * v); /* 793 */
+ void (GLAPIENTRYP VertexAttribs3fvNV)(GLuint index, GLsizei n, const GLfloat * v); /* 794 */
+ void (GLAPIENTRYP VertexAttribs3svNV)(GLuint index, GLsizei n, const GLshort * v); /* 795 */
+ void (GLAPIENTRYP VertexAttribs4dvNV)(GLuint index, GLsizei n, const GLdouble * v); /* 796 */
+ void (GLAPIENTRYP VertexAttribs4fvNV)(GLuint index, GLsizei n, const GLfloat * v); /* 797 */
+ void (GLAPIENTRYP VertexAttribs4svNV)(GLuint index, GLsizei n, const GLshort * v); /* 798 */
+ void (GLAPIENTRYP VertexAttribs4ubvNV)(GLuint index, GLsizei n, const GLubyte * v); /* 799 */
+ void (GLAPIENTRYP GetTexBumpParameterfvATI)(GLenum pname, GLfloat * param); /* 800 */
+ void (GLAPIENTRYP GetTexBumpParameterivATI)(GLenum pname, GLint * param); /* 801 */
+ void (GLAPIENTRYP TexBumpParameterfvATI)(GLenum pname, const GLfloat * param); /* 802 */
+ void (GLAPIENTRYP TexBumpParameterivATI)(GLenum pname, const GLint * param); /* 803 */
+ void (GLAPIENTRYP AlphaFragmentOp1ATI)(GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod); /* 804 */
+ void (GLAPIENTRYP AlphaFragmentOp2ATI)(GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod); /* 805 */
+ void (GLAPIENTRYP AlphaFragmentOp3ATI)(GLenum op, GLuint dst, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod, GLuint arg3, GLuint arg3Rep, GLuint arg3Mod); /* 806 */
+ void (GLAPIENTRYP BeginFragmentShaderATI)(void); /* 807 */
+ void (GLAPIENTRYP BindFragmentShaderATI)(GLuint id); /* 808 */
+ void (GLAPIENTRYP ColorFragmentOp1ATI)(GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod); /* 809 */
+ void (GLAPIENTRYP ColorFragmentOp2ATI)(GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod); /* 810 */
+ void (GLAPIENTRYP ColorFragmentOp3ATI)(GLenum op, GLuint dst, GLuint dstMask, GLuint dstMod, GLuint arg1, GLuint arg1Rep, GLuint arg1Mod, GLuint arg2, GLuint arg2Rep, GLuint arg2Mod, GLuint arg3, GLuint arg3Rep, GLuint arg3Mod); /* 811 */
+ void (GLAPIENTRYP DeleteFragmentShaderATI)(GLuint id); /* 812 */
+ void (GLAPIENTRYP EndFragmentShaderATI)(void); /* 813 */
+ GLuint (GLAPIENTRYP GenFragmentShadersATI)(GLuint range); /* 814 */
+ void (GLAPIENTRYP PassTexCoordATI)(GLuint dst, GLuint coord, GLenum swizzle); /* 815 */
+ void (GLAPIENTRYP SampleMapATI)(GLuint dst, GLuint interp, GLenum swizzle); /* 816 */
+ void (GLAPIENTRYP SetFragmentShaderConstantATI)(GLuint dst, const GLfloat * value); /* 817 */
+ void (GLAPIENTRYP PointParameteriNV)(GLenum pname, GLint param); /* 818 */
+ void (GLAPIENTRYP PointParameterivNV)(GLenum pname, const GLint * params); /* 819 */
+ void (GLAPIENTRYP ActiveStencilFaceEXT)(GLenum face); /* 820 */
+ void (GLAPIENTRYP BindVertexArrayAPPLE)(GLuint array); /* 821 */
+ void (GLAPIENTRYP DeleteVertexArraysAPPLE)(GLsizei n, const GLuint * arrays); /* 822 */
+ void (GLAPIENTRYP GenVertexArraysAPPLE)(GLsizei n, GLuint * arrays); /* 823 */
+ GLboolean (GLAPIENTRYP IsVertexArrayAPPLE)(GLuint array); /* 824 */
+ void (GLAPIENTRYP GetProgramNamedParameterdvNV)(GLuint id, GLsizei len, const GLubyte * name, GLdouble * params); /* 825 */
+ void (GLAPIENTRYP GetProgramNamedParameterfvNV)(GLuint id, GLsizei len, const GLubyte * name, GLfloat * params); /* 826 */
+ void (GLAPIENTRYP ProgramNamedParameter4dNV)(GLuint id, GLsizei len, const GLubyte * name, GLdouble x, GLdouble y, GLdouble z, GLdouble w); /* 827 */
+ void (GLAPIENTRYP ProgramNamedParameter4dvNV)(GLuint id, GLsizei len, const GLubyte * name, const GLdouble * v); /* 828 */
+ void (GLAPIENTRYP ProgramNamedParameter4fNV)(GLuint id, GLsizei len, const GLubyte * name, GLfloat x, GLfloat y, GLfloat z, GLfloat w); /* 829 */
+ void (GLAPIENTRYP ProgramNamedParameter4fvNV)(GLuint id, GLsizei len, const GLubyte * name, const GLfloat * v); /* 830 */
+ void (GLAPIENTRYP PrimitiveRestartIndexNV)(GLuint index); /* 831 */
+ void (GLAPIENTRYP PrimitiveRestartNV)(void); /* 832 */
+ void (GLAPIENTRYP DepthBoundsEXT)(GLclampd zmin, GLclampd zmax); /* 833 */
+ void (GLAPIENTRYP BlendEquationSeparateEXT)(GLenum modeRGB, GLenum modeA); /* 834 */
+ void (GLAPIENTRYP BindFramebufferEXT)(GLenum target, GLuint framebuffer); /* 835 */
+ void (GLAPIENTRYP BindRenderbufferEXT)(GLenum target, GLuint renderbuffer); /* 836 */
+ GLenum (GLAPIENTRYP CheckFramebufferStatusEXT)(GLenum target); /* 837 */
+ void (GLAPIENTRYP DeleteFramebuffersEXT)(GLsizei n, const GLuint * framebuffers); /* 838 */
+ void (GLAPIENTRYP DeleteRenderbuffersEXT)(GLsizei n, const GLuint * renderbuffers); /* 839 */
+ void (GLAPIENTRYP FramebufferRenderbufferEXT)(GLenum target, GLenum attachment, GLenum renderbuffertarget, GLuint renderbuffer); /* 840 */
+ void (GLAPIENTRYP FramebufferTexture1DEXT)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); /* 841 */
+ void (GLAPIENTRYP FramebufferTexture2DEXT)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level); /* 842 */
+ void (GLAPIENTRYP FramebufferTexture3DEXT)(GLenum target, GLenum attachment, GLenum textarget, GLuint texture, GLint level, GLint zoffset); /* 843 */
+ void (GLAPIENTRYP GenFramebuffersEXT)(GLsizei n, GLuint * framebuffers); /* 844 */
+ void (GLAPIENTRYP GenRenderbuffersEXT)(GLsizei n, GLuint * renderbuffers); /* 845 */
+ void (GLAPIENTRYP GenerateMipmapEXT)(GLenum target); /* 846 */
+ void (GLAPIENTRYP GetFramebufferAttachmentParameterivEXT)(GLenum target, GLenum attachment, GLenum pname, GLint * params); /* 847 */
+ void (GLAPIENTRYP GetRenderbufferParameterivEXT)(GLenum target, GLenum pname, GLint * params); /* 848 */
+ GLboolean (GLAPIENTRYP IsFramebufferEXT)(GLuint framebuffer); /* 849 */
+ GLboolean (GLAPIENTRYP IsRenderbufferEXT)(GLuint renderbuffer); /* 850 */
+ void (GLAPIENTRYP RenderbufferStorageEXT)(GLenum target, GLenum internalformat, GLsizei width, GLsizei height); /* 851 */
+ void (GLAPIENTRYP BlitFramebufferEXT)(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter); /* 852 */
+ void (GLAPIENTRYP BufferParameteriAPPLE)(GLenum target, GLenum pname, GLint param); /* 853 */
+ void (GLAPIENTRYP FlushMappedBufferRangeAPPLE)(GLenum target, GLintptr offset, GLsizeiptr size); /* 854 */
+ void (GLAPIENTRYP BindFragDataLocationEXT)(GLuint program, GLuint colorNumber, const GLchar * name); /* 855 */
+ GLint (GLAPIENTRYP GetFragDataLocationEXT)(GLuint program, const GLchar * name); /* 856 */
+ void (GLAPIENTRYP GetUniformuivEXT)(GLuint program, GLint location, GLuint * params); /* 857 */
+ void (GLAPIENTRYP GetVertexAttribIivEXT)(GLuint index, GLenum pname, GLint * params); /* 858 */
+ void (GLAPIENTRYP GetVertexAttribIuivEXT)(GLuint index, GLenum pname, GLuint * params); /* 859 */
+ void (GLAPIENTRYP Uniform1uiEXT)(GLint location, GLuint x); /* 860 */
+ void (GLAPIENTRYP Uniform1uivEXT)(GLint location, GLsizei count, const GLuint * value); /* 861 */
+ void (GLAPIENTRYP Uniform2uiEXT)(GLint location, GLuint x, GLuint y); /* 862 */
+ void (GLAPIENTRYP Uniform2uivEXT)(GLint location, GLsizei count, const GLuint * value); /* 863 */
+ void (GLAPIENTRYP Uniform3uiEXT)(GLint location, GLuint x, GLuint y, GLuint z); /* 864 */
+ void (GLAPIENTRYP Uniform3uivEXT)(GLint location, GLsizei count, const GLuint * value); /* 865 */
+ void (GLAPIENTRYP Uniform4uiEXT)(GLint location, GLuint x, GLuint y, GLuint z, GLuint w); /* 866 */
+ void (GLAPIENTRYP Uniform4uivEXT)(GLint location, GLsizei count, const GLuint * value); /* 867 */
+ void (GLAPIENTRYP VertexAttribI1iEXT)(GLuint index, GLint x); /* 868 */
+ void (GLAPIENTRYP VertexAttribI1ivEXT)(GLuint index, const GLint * v); /* 869 */
+ void (GLAPIENTRYP VertexAttribI1uiEXT)(GLuint index, GLuint x); /* 870 */
+ void (GLAPIENTRYP VertexAttribI1uivEXT)(GLuint index, const GLuint * v); /* 871 */
+ void (GLAPIENTRYP VertexAttribI2iEXT)(GLuint index, GLint x, GLint y); /* 872 */
+ void (GLAPIENTRYP VertexAttribI2ivEXT)(GLuint index, const GLint * v); /* 873 */
+ void (GLAPIENTRYP VertexAttribI2uiEXT)(GLuint index, GLuint x, GLuint y); /* 874 */
+ void (GLAPIENTRYP VertexAttribI2uivEXT)(GLuint index, const GLuint * v); /* 875 */
+ void (GLAPIENTRYP VertexAttribI3iEXT)(GLuint index, GLint x, GLint y, GLint z); /* 876 */
+ void (GLAPIENTRYP VertexAttribI3ivEXT)(GLuint index, const GLint * v); /* 877 */
+ void (GLAPIENTRYP VertexAttribI3uiEXT)(GLuint index, GLuint x, GLuint y, GLuint z); /* 878 */
+ void (GLAPIENTRYP VertexAttribI3uivEXT)(GLuint index, const GLuint * v); /* 879 */
+ void (GLAPIENTRYP VertexAttribI4bvEXT)(GLuint index, const GLbyte * v); /* 880 */
+ void (GLAPIENTRYP VertexAttribI4iEXT)(GLuint index, GLint x, GLint y, GLint z, GLint w); /* 881 */
+ void (GLAPIENTRYP VertexAttribI4ivEXT)(GLuint index, const GLint * v); /* 882 */
+ void (GLAPIENTRYP VertexAttribI4svEXT)(GLuint index, const GLshort * v); /* 883 */
+ void (GLAPIENTRYP VertexAttribI4ubvEXT)(GLuint index, const GLubyte * v); /* 884 */
+ void (GLAPIENTRYP VertexAttribI4uiEXT)(GLuint index, GLuint x, GLuint y, GLuint z, GLuint w); /* 885 */
+ void (GLAPIENTRYP VertexAttribI4uivEXT)(GLuint index, const GLuint * v); /* 886 */
+ void (GLAPIENTRYP VertexAttribI4usvEXT)(GLuint index, const GLushort * v); /* 887 */
+ void (GLAPIENTRYP VertexAttribIPointerEXT)(GLuint index, GLint size, GLenum type, GLsizei stride, const GLvoid * pointer); /* 888 */
+ void (GLAPIENTRYP FramebufferTextureLayerEXT)(GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer); /* 889 */
+ void (GLAPIENTRYP ColorMaskIndexedEXT)(GLuint buf, GLboolean r, GLboolean g, GLboolean b, GLboolean a); /* 890 */
+ void (GLAPIENTRYP DisableIndexedEXT)(GLenum target, GLuint index); /* 891 */
+ void (GLAPIENTRYP EnableIndexedEXT)(GLenum target, GLuint index); /* 892 */
+ void (GLAPIENTRYP GetBooleanIndexedvEXT)(GLenum value, GLuint index, GLboolean * data); /* 893 */
+ void (GLAPIENTRYP GetIntegerIndexedvEXT)(GLenum value, GLuint index, GLint * data); /* 894 */
+ GLboolean (GLAPIENTRYP IsEnabledIndexedEXT)(GLenum target, GLuint index); /* 895 */
+ void (GLAPIENTRYP ClearColorIiEXT)(GLint r, GLint g, GLint b, GLint a); /* 896 */
+ void (GLAPIENTRYP ClearColorIuiEXT)(GLuint r, GLuint g, GLuint b, GLuint a); /* 897 */
+ void (GLAPIENTRYP GetTexParameterIivEXT)(GLenum target, GLenum pname, GLint * params); /* 898 */
+ void (GLAPIENTRYP GetTexParameterIuivEXT)(GLenum target, GLenum pname, GLuint * params); /* 899 */
+ void (GLAPIENTRYP TexParameterIivEXT)(GLenum target, GLenum pname, const GLint * params); /* 900 */
+ void (GLAPIENTRYP TexParameterIuivEXT)(GLenum target, GLenum pname, const GLuint * params); /* 901 */
+ void (GLAPIENTRYP BeginConditionalRenderNV)(GLuint query, GLenum mode); /* 902 */
+ void (GLAPIENTRYP EndConditionalRenderNV)(void); /* 903 */
+ void (GLAPIENTRYP BeginTransformFeedbackEXT)(GLenum mode); /* 904 */
+ void (GLAPIENTRYP BindBufferBaseEXT)(GLenum target, GLuint index, GLuint buffer); /* 905 */
+ void (GLAPIENTRYP BindBufferOffsetEXT)(GLenum target, GLuint index, GLuint buffer, GLintptr offset); /* 906 */
+ void (GLAPIENTRYP BindBufferRangeEXT)(GLenum target, GLuint index, GLuint buffer, GLintptr offset, GLsizeiptr size); /* 907 */
+ void (GLAPIENTRYP EndTransformFeedbackEXT)(void); /* 908 */
+ void (GLAPIENTRYP GetTransformFeedbackVaryingEXT)(GLuint program, GLuint index, GLsizei bufSize, GLsizei * length, GLsizei * size, GLenum * type, GLchar * name); /* 909 */
+ void (GLAPIENTRYP TransformFeedbackVaryingsEXT)(GLuint program, GLsizei count, const char ** varyings, GLenum bufferMode); /* 910 */
+ void (GLAPIENTRYP ProvokingVertexEXT)(GLenum mode); /* 911 */
+ void (GLAPIENTRYP GetTexParameterPointervAPPLE)(GLenum target, GLenum pname, GLvoid ** params); /* 912 */
+ void (GLAPIENTRYP TextureRangeAPPLE)(GLenum target, GLsizei length, GLvoid * pointer); /* 913 */
+ void (GLAPIENTRYP GetObjectParameterivAPPLE)(GLenum objectType, GLuint name, GLenum pname, GLint * value); /* 914 */
+ GLenum (GLAPIENTRYP ObjectPurgeableAPPLE)(GLenum objectType, GLuint name, GLenum option); /* 915 */
+ GLenum (GLAPIENTRYP ObjectUnpurgeableAPPLE)(GLenum objectType, GLuint name, GLenum option); /* 916 */
+ void (GLAPIENTRYP ActiveProgramEXT)(GLuint program); /* 917 */
+ GLuint (GLAPIENTRYP CreateShaderProgramEXT)(GLenum type, const GLchar * string); /* 918 */
+ void (GLAPIENTRYP UseShaderProgramEXT)(GLenum type, GLuint program); /* 919 */
+ void (GLAPIENTRYP TextureBarrierNV)(void); /* 920 */
+ void (GLAPIENTRYP StencilFuncSeparateATI)(GLenum frontfunc, GLenum backfunc, GLint ref, GLuint mask); /* 921 */
+ void (GLAPIENTRYP ProgramEnvParameters4fvEXT)(GLenum target, GLuint index, GLsizei count, const GLfloat * params); /* 922 */
+ void (GLAPIENTRYP ProgramLocalParameters4fvEXT)(GLenum target, GLuint index, GLsizei count, const GLfloat * params); /* 923 */
+ void (GLAPIENTRYP GetQueryObjecti64vEXT)(GLuint id, GLenum pname, GLint64EXT * params); /* 924 */
+ void (GLAPIENTRYP GetQueryObjectui64vEXT)(GLuint id, GLenum pname, GLuint64EXT * params); /* 925 */
+ void (GLAPIENTRYP EGLImageTargetRenderbufferStorageOES)(GLenum target, GLvoid * writeOffset); /* 926 */
+ void (GLAPIENTRYP EGLImageTargetTexture2DOES)(GLenum target, GLvoid * writeOffset); /* 927 */
};
#endif /* !defined( _GLAPI_TABLE_H_ ) */
diff --git a/xorg-server/glx/glprocs.h b/xorg-server/glx/glprocs.h
index ce607a862..b7b9a75ac 100644
--- a/xorg-server/glx/glprocs.h
+++ b/xorg-server/glx/glprocs.h
@@ -678,6 +678,26 @@ static const char gl_string_table[] =
"glGetShaderPrecisionFormat\0"
"glReleaseShaderCompiler\0"
"glShaderBinary\0"
+ "glGetGraphicsResetStatusARB\0"
+ "glGetnColorTableARB\0"
+ "glGetnCompressedTexImageARB\0"
+ "glGetnConvolutionFilterARB\0"
+ "glGetnHistogramARB\0"
+ "glGetnMapdvARB\0"
+ "glGetnMapfvARB\0"
+ "glGetnMapivARB\0"
+ "glGetnMinmaxARB\0"
+ "glGetnPixelMapfvARB\0"
+ "glGetnPixelMapuivARB\0"
+ "glGetnPixelMapusvARB\0"
+ "glGetnPolygonStippleARB\0"
+ "glGetnSeparableFilterARB\0"
+ "glGetnTexImageARB\0"
+ "glGetnUniformdvARB\0"
+ "glGetnUniformfvARB\0"
+ "glGetnUniformivARB\0"
+ "glGetnUniformuivARB\0"
+ "glReadnPixelsARB\0"
"glPolygonOffsetEXT\0"
"glGetPixelTexGenParameterfvSGIS\0"
"glGetPixelTexGenParameterivSGIS\0"
@@ -1336,41 +1356,41 @@ static const char gl_string_table[] =
#define gl_dispatch_stub_364 mgl_dispatch_stub_364
#define gl_dispatch_stub_365 mgl_dispatch_stub_365
#define gl_dispatch_stub_366 mgl_dispatch_stub_366
-#define gl_dispatch_stub_627 mgl_dispatch_stub_627
-#define gl_dispatch_stub_628 mgl_dispatch_stub_628
-#define gl_dispatch_stub_629 mgl_dispatch_stub_629
-#define gl_dispatch_stub_630 mgl_dispatch_stub_630
-#define gl_dispatch_stub_631 mgl_dispatch_stub_631
-#define gl_dispatch_stub_632 mgl_dispatch_stub_632
-#define gl_dispatch_stub_633 mgl_dispatch_stub_633
-#define gl_dispatch_stub_634 mgl_dispatch_stub_634
-#define gl_dispatch_stub_669 mgl_dispatch_stub_669
-#define gl_dispatch_stub_711 mgl_dispatch_stub_711
-#define gl_dispatch_stub_712 mgl_dispatch_stub_712
-#define gl_dispatch_stub_713 mgl_dispatch_stub_713
-#define gl_dispatch_stub_714 mgl_dispatch_stub_714
-#define gl_dispatch_stub_715 mgl_dispatch_stub_715
-#define gl_dispatch_stub_716 mgl_dispatch_stub_716
-#define gl_dispatch_stub_717 mgl_dispatch_stub_717
-#define gl_dispatch_stub_718 mgl_dispatch_stub_718
-#define gl_dispatch_stub_719 mgl_dispatch_stub_719
-#define gl_dispatch_stub_800 mgl_dispatch_stub_800
-#define gl_dispatch_stub_801 mgl_dispatch_stub_801
-#define gl_dispatch_stub_802 mgl_dispatch_stub_802
-#define gl_dispatch_stub_803 mgl_dispatch_stub_803
-#define gl_dispatch_stub_804 mgl_dispatch_stub_804
-#define gl_dispatch_stub_813 mgl_dispatch_stub_813
-#define gl_dispatch_stub_814 mgl_dispatch_stub_814
-#define gl_dispatch_stub_832 mgl_dispatch_stub_832
+#define gl_dispatch_stub_647 mgl_dispatch_stub_647
+#define gl_dispatch_stub_648 mgl_dispatch_stub_648
+#define gl_dispatch_stub_649 mgl_dispatch_stub_649
+#define gl_dispatch_stub_650 mgl_dispatch_stub_650
+#define gl_dispatch_stub_651 mgl_dispatch_stub_651
+#define gl_dispatch_stub_652 mgl_dispatch_stub_652
+#define gl_dispatch_stub_653 mgl_dispatch_stub_653
+#define gl_dispatch_stub_654 mgl_dispatch_stub_654
+#define gl_dispatch_stub_689 mgl_dispatch_stub_689
+#define gl_dispatch_stub_731 mgl_dispatch_stub_731
+#define gl_dispatch_stub_732 mgl_dispatch_stub_732
+#define gl_dispatch_stub_733 mgl_dispatch_stub_733
+#define gl_dispatch_stub_734 mgl_dispatch_stub_734
+#define gl_dispatch_stub_735 mgl_dispatch_stub_735
+#define gl_dispatch_stub_736 mgl_dispatch_stub_736
+#define gl_dispatch_stub_737 mgl_dispatch_stub_737
+#define gl_dispatch_stub_738 mgl_dispatch_stub_738
+#define gl_dispatch_stub_739 mgl_dispatch_stub_739
+#define gl_dispatch_stub_820 mgl_dispatch_stub_820
+#define gl_dispatch_stub_821 mgl_dispatch_stub_821
+#define gl_dispatch_stub_822 mgl_dispatch_stub_822
+#define gl_dispatch_stub_823 mgl_dispatch_stub_823
+#define gl_dispatch_stub_824 mgl_dispatch_stub_824
#define gl_dispatch_stub_833 mgl_dispatch_stub_833
#define gl_dispatch_stub_834 mgl_dispatch_stub_834
-#define gl_dispatch_stub_892 mgl_dispatch_stub_892
-#define gl_dispatch_stub_893 mgl_dispatch_stub_893
-#define gl_dispatch_stub_901 mgl_dispatch_stub_901
-#define gl_dispatch_stub_902 mgl_dispatch_stub_902
-#define gl_dispatch_stub_903 mgl_dispatch_stub_903
-#define gl_dispatch_stub_904 mgl_dispatch_stub_904
-#define gl_dispatch_stub_905 mgl_dispatch_stub_905
+#define gl_dispatch_stub_852 mgl_dispatch_stub_852
+#define gl_dispatch_stub_853 mgl_dispatch_stub_853
+#define gl_dispatch_stub_854 mgl_dispatch_stub_854
+#define gl_dispatch_stub_912 mgl_dispatch_stub_912
+#define gl_dispatch_stub_913 mgl_dispatch_stub_913
+#define gl_dispatch_stub_921 mgl_dispatch_stub_921
+#define gl_dispatch_stub_922 mgl_dispatch_stub_922
+#define gl_dispatch_stub_923 mgl_dispatch_stub_923
+#define gl_dispatch_stub_924 mgl_dispatch_stub_924
+#define gl_dispatch_stub_925 mgl_dispatch_stub_925
#endif /* USE_MGL_NAMESPACE */
@@ -1388,41 +1408,41 @@ void GLAPIENTRY gl_dispatch_stub_363(GLenum target, GLenum pname, GLint * params
void GLAPIENTRY gl_dispatch_stub_364(GLenum target, GLboolean reset, GLenum format, GLenum type, GLvoid * values);
void GLAPIENTRY gl_dispatch_stub_365(GLenum target, GLenum pname, GLfloat * params);
void GLAPIENTRY gl_dispatch_stub_366(GLenum target, GLenum pname, GLint * params);
-void GLAPIENTRY gl_dispatch_stub_627(GLenum pname, GLfloat * params);
-void GLAPIENTRY gl_dispatch_stub_628(GLenum pname, GLint * params);
-void GLAPIENTRY gl_dispatch_stub_629(GLenum pname, GLfloat param);
-void GLAPIENTRY gl_dispatch_stub_630(GLenum pname, const GLfloat * params);
-void GLAPIENTRY gl_dispatch_stub_631(GLenum pname, GLint param);
-void GLAPIENTRY gl_dispatch_stub_632(GLenum pname, const GLint * params);
-void GLAPIENTRY gl_dispatch_stub_633(GLclampf value, GLboolean invert);
-void GLAPIENTRY gl_dispatch_stub_634(GLenum pattern);
-void GLAPIENTRY gl_dispatch_stub_669(GLenum mode);
-void GLAPIENTRY gl_dispatch_stub_711(const GLenum * mode, const GLint * first, const GLsizei * count, GLsizei primcount, GLint modestride);
-void GLAPIENTRY gl_dispatch_stub_712(const GLenum * mode, const GLsizei * count, GLenum type, const GLvoid * const * indices, GLsizei primcount, GLint modestride);
-void GLAPIENTRY gl_dispatch_stub_713(GLsizei n, const GLuint * fences);
-void GLAPIENTRY gl_dispatch_stub_714(GLuint fence);
-void GLAPIENTRY gl_dispatch_stub_715(GLsizei n, GLuint * fences);
-void GLAPIENTRY gl_dispatch_stub_716(GLuint fence, GLenum pname, GLint * params);
-GLboolean GLAPIENTRY gl_dispatch_stub_717(GLuint fence);
-void GLAPIENTRY gl_dispatch_stub_718(GLuint fence, GLenum condition);
-GLboolean GLAPIENTRY gl_dispatch_stub_719(GLuint fence);
-void GLAPIENTRY gl_dispatch_stub_800(GLenum face);
-void GLAPIENTRY gl_dispatch_stub_801(GLuint array);
-void GLAPIENTRY gl_dispatch_stub_802(GLsizei n, const GLuint * arrays);
-void GLAPIENTRY gl_dispatch_stub_803(GLsizei n, GLuint * arrays);
-GLboolean GLAPIENTRY gl_dispatch_stub_804(GLuint array);
-void GLAPIENTRY gl_dispatch_stub_813(GLclampd zmin, GLclampd zmax);
-void GLAPIENTRY gl_dispatch_stub_814(GLenum modeRGB, GLenum modeA);
-void GLAPIENTRY gl_dispatch_stub_832(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
-void GLAPIENTRY gl_dispatch_stub_833(GLenum target, GLenum pname, GLint param);
-void GLAPIENTRY gl_dispatch_stub_834(GLenum target, GLintptr offset, GLsizeiptr size);
-void GLAPIENTRY gl_dispatch_stub_892(GLenum target, GLenum pname, GLvoid ** params);
-void GLAPIENTRY gl_dispatch_stub_893(GLenum target, GLsizei length, GLvoid * pointer);
-void GLAPIENTRY gl_dispatch_stub_901(GLenum frontfunc, GLenum backfunc, GLint ref, GLuint mask);
-void GLAPIENTRY gl_dispatch_stub_902(GLenum target, GLuint index, GLsizei count, const GLfloat * params);
-void GLAPIENTRY gl_dispatch_stub_903(GLenum target, GLuint index, GLsizei count, const GLfloat * params);
-void GLAPIENTRY gl_dispatch_stub_904(GLuint id, GLenum pname, GLint64EXT * params);
-void GLAPIENTRY gl_dispatch_stub_905(GLuint id, GLenum pname, GLuint64EXT * params);
+void GLAPIENTRY gl_dispatch_stub_647(GLenum pname, GLfloat * params);
+void GLAPIENTRY gl_dispatch_stub_648(GLenum pname, GLint * params);
+void GLAPIENTRY gl_dispatch_stub_649(GLenum pname, GLfloat param);
+void GLAPIENTRY gl_dispatch_stub_650(GLenum pname, const GLfloat * params);
+void GLAPIENTRY gl_dispatch_stub_651(GLenum pname, GLint param);
+void GLAPIENTRY gl_dispatch_stub_652(GLenum pname, const GLint * params);
+void GLAPIENTRY gl_dispatch_stub_653(GLclampf value, GLboolean invert);
+void GLAPIENTRY gl_dispatch_stub_654(GLenum pattern);
+void GLAPIENTRY gl_dispatch_stub_689(GLenum mode);
+void GLAPIENTRY gl_dispatch_stub_731(const GLenum * mode, const GLint * first, const GLsizei * count, GLsizei primcount, GLint modestride);
+void GLAPIENTRY gl_dispatch_stub_732(const GLenum * mode, const GLsizei * count, GLenum type, const GLvoid * const * indices, GLsizei primcount, GLint modestride);
+void GLAPIENTRY gl_dispatch_stub_733(GLsizei n, const GLuint * fences);
+void GLAPIENTRY gl_dispatch_stub_734(GLuint fence);
+void GLAPIENTRY gl_dispatch_stub_735(GLsizei n, GLuint * fences);
+void GLAPIENTRY gl_dispatch_stub_736(GLuint fence, GLenum pname, GLint * params);
+GLboolean GLAPIENTRY gl_dispatch_stub_737(GLuint fence);
+void GLAPIENTRY gl_dispatch_stub_738(GLuint fence, GLenum condition);
+GLboolean GLAPIENTRY gl_dispatch_stub_739(GLuint fence);
+void GLAPIENTRY gl_dispatch_stub_820(GLenum face);
+void GLAPIENTRY gl_dispatch_stub_821(GLuint array);
+void GLAPIENTRY gl_dispatch_stub_822(GLsizei n, const GLuint * arrays);
+void GLAPIENTRY gl_dispatch_stub_823(GLsizei n, GLuint * arrays);
+GLboolean GLAPIENTRY gl_dispatch_stub_824(GLuint array);
+void GLAPIENTRY gl_dispatch_stub_833(GLclampd zmin, GLclampd zmax);
+void GLAPIENTRY gl_dispatch_stub_834(GLenum modeRGB, GLenum modeA);
+void GLAPIENTRY gl_dispatch_stub_852(GLint srcX0, GLint srcY0, GLint srcX1, GLint srcY1, GLint dstX0, GLint dstY0, GLint dstX1, GLint dstY1, GLbitfield mask, GLenum filter);
+void GLAPIENTRY gl_dispatch_stub_853(GLenum target, GLenum pname, GLint param);
+void GLAPIENTRY gl_dispatch_stub_854(GLenum target, GLintptr offset, GLsizeiptr size);
+void GLAPIENTRY gl_dispatch_stub_912(GLenum target, GLenum pname, GLvoid ** params);
+void GLAPIENTRY gl_dispatch_stub_913(GLenum target, GLsizei length, GLvoid * pointer);
+void GLAPIENTRY gl_dispatch_stub_921(GLenum frontfunc, GLenum backfunc, GLint ref, GLuint mask);
+void GLAPIENTRY gl_dispatch_stub_922(GLenum target, GLuint index, GLsizei count, const GLfloat * params);
+void GLAPIENTRY gl_dispatch_stub_923(GLenum target, GLuint index, GLsizei count, const GLfloat * params);
+void GLAPIENTRY gl_dispatch_stub_924(GLuint id, GLenum pname, GLint64EXT * params);
+void GLAPIENTRY gl_dispatch_stub_925(GLuint id, GLenum pname, GLuint64EXT * params);
#endif /* defined(NEED_FUNCTION_POINTER) || defined(GLX_INDIRECT_RENDERING) */
static const glprocs_table_t static_functions[] = {
@@ -2052,647 +2072,667 @@ static const glprocs_table_t static_functions[] = {
NAME_FUNC_OFFSET(10200, glGetShaderPrecisionFormat, glGetShaderPrecisionFormat, NULL, 623),
NAME_FUNC_OFFSET(10227, glReleaseShaderCompiler, glReleaseShaderCompiler, NULL, 624),
NAME_FUNC_OFFSET(10251, glShaderBinary, glShaderBinary, NULL, 625),
- NAME_FUNC_OFFSET(10266, glPolygonOffsetEXT, glPolygonOffsetEXT, NULL, 626),
- NAME_FUNC_OFFSET(10285, gl_dispatch_stub_627, gl_dispatch_stub_627, NULL, 627),
- NAME_FUNC_OFFSET(10317, gl_dispatch_stub_628, gl_dispatch_stub_628, NULL, 628),
- NAME_FUNC_OFFSET(10349, gl_dispatch_stub_629, gl_dispatch_stub_629, NULL, 629),
- NAME_FUNC_OFFSET(10377, gl_dispatch_stub_630, gl_dispatch_stub_630, NULL, 630),
- NAME_FUNC_OFFSET(10406, gl_dispatch_stub_631, gl_dispatch_stub_631, NULL, 631),
- NAME_FUNC_OFFSET(10434, gl_dispatch_stub_632, gl_dispatch_stub_632, NULL, 632),
- NAME_FUNC_OFFSET(10463, gl_dispatch_stub_633, gl_dispatch_stub_633, NULL, 633),
- NAME_FUNC_OFFSET(10480, gl_dispatch_stub_634, gl_dispatch_stub_634, NULL, 634),
- NAME_FUNC_OFFSET(10500, glColorPointerEXT, glColorPointerEXT, NULL, 635),
- NAME_FUNC_OFFSET(10518, glEdgeFlagPointerEXT, glEdgeFlagPointerEXT, NULL, 636),
- NAME_FUNC_OFFSET(10539, glIndexPointerEXT, glIndexPointerEXT, NULL, 637),
- NAME_FUNC_OFFSET(10557, glNormalPointerEXT, glNormalPointerEXT, NULL, 638),
- NAME_FUNC_OFFSET(10576, glTexCoordPointerEXT, glTexCoordPointerEXT, NULL, 639),
- NAME_FUNC_OFFSET(10597, glVertexPointerEXT, glVertexPointerEXT, NULL, 640),
- NAME_FUNC_OFFSET(10616, glPointParameterfEXT, glPointParameterfEXT, NULL, 641),
- NAME_FUNC_OFFSET(10637, glPointParameterfvEXT, glPointParameterfvEXT, NULL, 642),
- NAME_FUNC_OFFSET(10659, glLockArraysEXT, glLockArraysEXT, NULL, 643),
- NAME_FUNC_OFFSET(10675, glUnlockArraysEXT, glUnlockArraysEXT, NULL, 644),
- NAME_FUNC_OFFSET(10693, glSecondaryColor3bEXT, glSecondaryColor3bEXT, NULL, 645),
- NAME_FUNC_OFFSET(10715, glSecondaryColor3bvEXT, glSecondaryColor3bvEXT, NULL, 646),
- NAME_FUNC_OFFSET(10738, glSecondaryColor3dEXT, glSecondaryColor3dEXT, NULL, 647),
- NAME_FUNC_OFFSET(10760, glSecondaryColor3dvEXT, glSecondaryColor3dvEXT, NULL, 648),
- NAME_FUNC_OFFSET(10783, glSecondaryColor3fEXT, glSecondaryColor3fEXT, NULL, 649),
- NAME_FUNC_OFFSET(10805, glSecondaryColor3fvEXT, glSecondaryColor3fvEXT, NULL, 650),
- NAME_FUNC_OFFSET(10828, glSecondaryColor3iEXT, glSecondaryColor3iEXT, NULL, 651),
- NAME_FUNC_OFFSET(10850, glSecondaryColor3ivEXT, glSecondaryColor3ivEXT, NULL, 652),
- NAME_FUNC_OFFSET(10873, glSecondaryColor3sEXT, glSecondaryColor3sEXT, NULL, 653),
- NAME_FUNC_OFFSET(10895, glSecondaryColor3svEXT, glSecondaryColor3svEXT, NULL, 654),
- NAME_FUNC_OFFSET(10918, glSecondaryColor3ubEXT, glSecondaryColor3ubEXT, NULL, 655),
- NAME_FUNC_OFFSET(10941, glSecondaryColor3ubvEXT, glSecondaryColor3ubvEXT, NULL, 656),
- NAME_FUNC_OFFSET(10965, glSecondaryColor3uiEXT, glSecondaryColor3uiEXT, NULL, 657),
- NAME_FUNC_OFFSET(10988, glSecondaryColor3uivEXT, glSecondaryColor3uivEXT, NULL, 658),
- NAME_FUNC_OFFSET(11012, glSecondaryColor3usEXT, glSecondaryColor3usEXT, NULL, 659),
- NAME_FUNC_OFFSET(11035, glSecondaryColor3usvEXT, glSecondaryColor3usvEXT, NULL, 660),
- NAME_FUNC_OFFSET(11059, glSecondaryColorPointerEXT, glSecondaryColorPointerEXT, NULL, 661),
- NAME_FUNC_OFFSET(11086, glMultiDrawArraysEXT, glMultiDrawArraysEXT, NULL, 662),
- NAME_FUNC_OFFSET(11107, glMultiDrawElementsEXT, glMultiDrawElementsEXT, NULL, 663),
- NAME_FUNC_OFFSET(11130, glFogCoordPointerEXT, glFogCoordPointerEXT, NULL, 664),
- NAME_FUNC_OFFSET(11151, glFogCoorddEXT, glFogCoorddEXT, NULL, 665),
- NAME_FUNC_OFFSET(11166, glFogCoorddvEXT, glFogCoorddvEXT, NULL, 666),
- NAME_FUNC_OFFSET(11182, glFogCoordfEXT, glFogCoordfEXT, NULL, 667),
- NAME_FUNC_OFFSET(11197, glFogCoordfvEXT, glFogCoordfvEXT, NULL, 668),
- NAME_FUNC_OFFSET(11213, gl_dispatch_stub_669, gl_dispatch_stub_669, NULL, 669),
- NAME_FUNC_OFFSET(11231, glBlendFuncSeparateEXT, glBlendFuncSeparateEXT, NULL, 670),
- NAME_FUNC_OFFSET(11254, glFlushVertexArrayRangeNV, glFlushVertexArrayRangeNV, NULL, 671),
- NAME_FUNC_OFFSET(11280, glVertexArrayRangeNV, glVertexArrayRangeNV, NULL, 672),
- NAME_FUNC_OFFSET(11301, glCombinerInputNV, glCombinerInputNV, NULL, 673),
- NAME_FUNC_OFFSET(11319, glCombinerOutputNV, glCombinerOutputNV, NULL, 674),
- NAME_FUNC_OFFSET(11338, glCombinerParameterfNV, glCombinerParameterfNV, NULL, 675),
- NAME_FUNC_OFFSET(11361, glCombinerParameterfvNV, glCombinerParameterfvNV, NULL, 676),
- NAME_FUNC_OFFSET(11385, glCombinerParameteriNV, glCombinerParameteriNV, NULL, 677),
- NAME_FUNC_OFFSET(11408, glCombinerParameterivNV, glCombinerParameterivNV, NULL, 678),
- NAME_FUNC_OFFSET(11432, glFinalCombinerInputNV, glFinalCombinerInputNV, NULL, 679),
- NAME_FUNC_OFFSET(11455, glGetCombinerInputParameterfvNV, glGetCombinerInputParameterfvNV, NULL, 680),
- NAME_FUNC_OFFSET(11487, glGetCombinerInputParameterivNV, glGetCombinerInputParameterivNV, NULL, 681),
- NAME_FUNC_OFFSET(11519, glGetCombinerOutputParameterfvNV, glGetCombinerOutputParameterfvNV, NULL, 682),
- NAME_FUNC_OFFSET(11552, glGetCombinerOutputParameterivNV, glGetCombinerOutputParameterivNV, NULL, 683),
- NAME_FUNC_OFFSET(11585, glGetFinalCombinerInputParameterfvNV, glGetFinalCombinerInputParameterfvNV, NULL, 684),
- NAME_FUNC_OFFSET(11622, glGetFinalCombinerInputParameterivNV, glGetFinalCombinerInputParameterivNV, NULL, 685),
- NAME_FUNC_OFFSET(11659, glResizeBuffersMESA, glResizeBuffersMESA, NULL, 686),
- NAME_FUNC_OFFSET(11679, glWindowPos2dMESA, glWindowPos2dMESA, NULL, 687),
- NAME_FUNC_OFFSET(11697, glWindowPos2dvMESA, glWindowPos2dvMESA, NULL, 688),
- NAME_FUNC_OFFSET(11716, glWindowPos2fMESA, glWindowPos2fMESA, NULL, 689),
- NAME_FUNC_OFFSET(11734, glWindowPos2fvMESA, glWindowPos2fvMESA, NULL, 690),
- NAME_FUNC_OFFSET(11753, glWindowPos2iMESA, glWindowPos2iMESA, NULL, 691),
- NAME_FUNC_OFFSET(11771, glWindowPos2ivMESA, glWindowPos2ivMESA, NULL, 692),
- NAME_FUNC_OFFSET(11790, glWindowPos2sMESA, glWindowPos2sMESA, NULL, 693),
- NAME_FUNC_OFFSET(11808, glWindowPos2svMESA, glWindowPos2svMESA, NULL, 694),
- NAME_FUNC_OFFSET(11827, glWindowPos3dMESA, glWindowPos3dMESA, NULL, 695),
- NAME_FUNC_OFFSET(11845, glWindowPos3dvMESA, glWindowPos3dvMESA, NULL, 696),
- NAME_FUNC_OFFSET(11864, glWindowPos3fMESA, glWindowPos3fMESA, NULL, 697),
- NAME_FUNC_OFFSET(11882, glWindowPos3fvMESA, glWindowPos3fvMESA, NULL, 698),
- NAME_FUNC_OFFSET(11901, glWindowPos3iMESA, glWindowPos3iMESA, NULL, 699),
- NAME_FUNC_OFFSET(11919, glWindowPos3ivMESA, glWindowPos3ivMESA, NULL, 700),
- NAME_FUNC_OFFSET(11938, glWindowPos3sMESA, glWindowPos3sMESA, NULL, 701),
- NAME_FUNC_OFFSET(11956, glWindowPos3svMESA, glWindowPos3svMESA, NULL, 702),
- NAME_FUNC_OFFSET(11975, glWindowPos4dMESA, glWindowPos4dMESA, NULL, 703),
- NAME_FUNC_OFFSET(11993, glWindowPos4dvMESA, glWindowPos4dvMESA, NULL, 704),
- NAME_FUNC_OFFSET(12012, glWindowPos4fMESA, glWindowPos4fMESA, NULL, 705),
- NAME_FUNC_OFFSET(12030, glWindowPos4fvMESA, glWindowPos4fvMESA, NULL, 706),
- NAME_FUNC_OFFSET(12049, glWindowPos4iMESA, glWindowPos4iMESA, NULL, 707),
- NAME_FUNC_OFFSET(12067, glWindowPos4ivMESA, glWindowPos4ivMESA, NULL, 708),
- NAME_FUNC_OFFSET(12086, glWindowPos4sMESA, glWindowPos4sMESA, NULL, 709),
- NAME_FUNC_OFFSET(12104, glWindowPos4svMESA, glWindowPos4svMESA, NULL, 710),
- NAME_FUNC_OFFSET(12123, gl_dispatch_stub_711, gl_dispatch_stub_711, NULL, 711),
- NAME_FUNC_OFFSET(12148, gl_dispatch_stub_712, gl_dispatch_stub_712, NULL, 712),
- NAME_FUNC_OFFSET(12175, gl_dispatch_stub_713, gl_dispatch_stub_713, NULL, 713),
- NAME_FUNC_OFFSET(12192, gl_dispatch_stub_714, gl_dispatch_stub_714, NULL, 714),
- NAME_FUNC_OFFSET(12208, gl_dispatch_stub_715, gl_dispatch_stub_715, NULL, 715),
- NAME_FUNC_OFFSET(12222, gl_dispatch_stub_716, gl_dispatch_stub_716, NULL, 716),
- NAME_FUNC_OFFSET(12237, gl_dispatch_stub_717, gl_dispatch_stub_717, NULL, 717),
- NAME_FUNC_OFFSET(12249, gl_dispatch_stub_718, gl_dispatch_stub_718, NULL, 718),
- NAME_FUNC_OFFSET(12262, gl_dispatch_stub_719, gl_dispatch_stub_719, NULL, 719),
- NAME_FUNC_OFFSET(12276, glAreProgramsResidentNV, glAreProgramsResidentNV, NULL, 720),
- NAME_FUNC_OFFSET(12300, glBindProgramNV, glBindProgramNV, NULL, 721),
- NAME_FUNC_OFFSET(12316, glDeleteProgramsNV, glDeleteProgramsNV, NULL, 722),
- NAME_FUNC_OFFSET(12335, glExecuteProgramNV, glExecuteProgramNV, NULL, 723),
- NAME_FUNC_OFFSET(12354, glGenProgramsNV, glGenProgramsNV, NULL, 724),
- NAME_FUNC_OFFSET(12370, glGetProgramParameterdvNV, glGetProgramParameterdvNV, NULL, 725),
- NAME_FUNC_OFFSET(12396, glGetProgramParameterfvNV, glGetProgramParameterfvNV, NULL, 726),
- NAME_FUNC_OFFSET(12422, glGetProgramStringNV, glGetProgramStringNV, NULL, 727),
- NAME_FUNC_OFFSET(12443, glGetProgramivNV, glGetProgramivNV, NULL, 728),
- NAME_FUNC_OFFSET(12460, glGetTrackMatrixivNV, glGetTrackMatrixivNV, NULL, 729),
- NAME_FUNC_OFFSET(12481, glGetVertexAttribPointervNV, glGetVertexAttribPointervNV, NULL, 730),
- NAME_FUNC_OFFSET(12509, glGetVertexAttribdvNV, glGetVertexAttribdvNV, NULL, 731),
- NAME_FUNC_OFFSET(12531, glGetVertexAttribfvNV, glGetVertexAttribfvNV, NULL, 732),
- NAME_FUNC_OFFSET(12553, glGetVertexAttribivNV, glGetVertexAttribivNV, NULL, 733),
- NAME_FUNC_OFFSET(12575, glIsProgramNV, glIsProgramNV, NULL, 734),
- NAME_FUNC_OFFSET(12589, glLoadProgramNV, glLoadProgramNV, NULL, 735),
- NAME_FUNC_OFFSET(12605, glProgramParameters4dvNV, glProgramParameters4dvNV, NULL, 736),
- NAME_FUNC_OFFSET(12630, glProgramParameters4fvNV, glProgramParameters4fvNV, NULL, 737),
- NAME_FUNC_OFFSET(12655, glRequestResidentProgramsNV, glRequestResidentProgramsNV, NULL, 738),
- NAME_FUNC_OFFSET(12683, glTrackMatrixNV, glTrackMatrixNV, NULL, 739),
- NAME_FUNC_OFFSET(12699, glVertexAttrib1dNV, glVertexAttrib1dNV, NULL, 740),
- NAME_FUNC_OFFSET(12718, glVertexAttrib1dvNV, glVertexAttrib1dvNV, NULL, 741),
- NAME_FUNC_OFFSET(12738, glVertexAttrib1fNV, glVertexAttrib1fNV, NULL, 742),
- NAME_FUNC_OFFSET(12757, glVertexAttrib1fvNV, glVertexAttrib1fvNV, NULL, 743),
- NAME_FUNC_OFFSET(12777, glVertexAttrib1sNV, glVertexAttrib1sNV, NULL, 744),
- NAME_FUNC_OFFSET(12796, glVertexAttrib1svNV, glVertexAttrib1svNV, NULL, 745),
- NAME_FUNC_OFFSET(12816, glVertexAttrib2dNV, glVertexAttrib2dNV, NULL, 746),
- NAME_FUNC_OFFSET(12835, glVertexAttrib2dvNV, glVertexAttrib2dvNV, NULL, 747),
- NAME_FUNC_OFFSET(12855, glVertexAttrib2fNV, glVertexAttrib2fNV, NULL, 748),
- NAME_FUNC_OFFSET(12874, glVertexAttrib2fvNV, glVertexAttrib2fvNV, NULL, 749),
- NAME_FUNC_OFFSET(12894, glVertexAttrib2sNV, glVertexAttrib2sNV, NULL, 750),
- NAME_FUNC_OFFSET(12913, glVertexAttrib2svNV, glVertexAttrib2svNV, NULL, 751),
- NAME_FUNC_OFFSET(12933, glVertexAttrib3dNV, glVertexAttrib3dNV, NULL, 752),
- NAME_FUNC_OFFSET(12952, glVertexAttrib3dvNV, glVertexAttrib3dvNV, NULL, 753),
- NAME_FUNC_OFFSET(12972, glVertexAttrib3fNV, glVertexAttrib3fNV, NULL, 754),
- NAME_FUNC_OFFSET(12991, glVertexAttrib3fvNV, glVertexAttrib3fvNV, NULL, 755),
- NAME_FUNC_OFFSET(13011, glVertexAttrib3sNV, glVertexAttrib3sNV, NULL, 756),
- NAME_FUNC_OFFSET(13030, glVertexAttrib3svNV, glVertexAttrib3svNV, NULL, 757),
- NAME_FUNC_OFFSET(13050, glVertexAttrib4dNV, glVertexAttrib4dNV, NULL, 758),
- NAME_FUNC_OFFSET(13069, glVertexAttrib4dvNV, glVertexAttrib4dvNV, NULL, 759),
- NAME_FUNC_OFFSET(13089, glVertexAttrib4fNV, glVertexAttrib4fNV, NULL, 760),
- NAME_FUNC_OFFSET(13108, glVertexAttrib4fvNV, glVertexAttrib4fvNV, NULL, 761),
- NAME_FUNC_OFFSET(13128, glVertexAttrib4sNV, glVertexAttrib4sNV, NULL, 762),
- NAME_FUNC_OFFSET(13147, glVertexAttrib4svNV, glVertexAttrib4svNV, NULL, 763),
- NAME_FUNC_OFFSET(13167, glVertexAttrib4ubNV, glVertexAttrib4ubNV, NULL, 764),
- NAME_FUNC_OFFSET(13187, glVertexAttrib4ubvNV, glVertexAttrib4ubvNV, NULL, 765),
- NAME_FUNC_OFFSET(13208, glVertexAttribPointerNV, glVertexAttribPointerNV, NULL, 766),
- NAME_FUNC_OFFSET(13232, glVertexAttribs1dvNV, glVertexAttribs1dvNV, NULL, 767),
- NAME_FUNC_OFFSET(13253, glVertexAttribs1fvNV, glVertexAttribs1fvNV, NULL, 768),
- NAME_FUNC_OFFSET(13274, glVertexAttribs1svNV, glVertexAttribs1svNV, NULL, 769),
- NAME_FUNC_OFFSET(13295, glVertexAttribs2dvNV, glVertexAttribs2dvNV, NULL, 770),
- NAME_FUNC_OFFSET(13316, glVertexAttribs2fvNV, glVertexAttribs2fvNV, NULL, 771),
- NAME_FUNC_OFFSET(13337, glVertexAttribs2svNV, glVertexAttribs2svNV, NULL, 772),
- NAME_FUNC_OFFSET(13358, glVertexAttribs3dvNV, glVertexAttribs3dvNV, NULL, 773),
- NAME_FUNC_OFFSET(13379, glVertexAttribs3fvNV, glVertexAttribs3fvNV, NULL, 774),
- NAME_FUNC_OFFSET(13400, glVertexAttribs3svNV, glVertexAttribs3svNV, NULL, 775),
- NAME_FUNC_OFFSET(13421, glVertexAttribs4dvNV, glVertexAttribs4dvNV, NULL, 776),
- NAME_FUNC_OFFSET(13442, glVertexAttribs4fvNV, glVertexAttribs4fvNV, NULL, 777),
- NAME_FUNC_OFFSET(13463, glVertexAttribs4svNV, glVertexAttribs4svNV, NULL, 778),
- NAME_FUNC_OFFSET(13484, glVertexAttribs4ubvNV, glVertexAttribs4ubvNV, NULL, 779),
- NAME_FUNC_OFFSET(13506, glGetTexBumpParameterfvATI, glGetTexBumpParameterfvATI, NULL, 780),
- NAME_FUNC_OFFSET(13533, glGetTexBumpParameterivATI, glGetTexBumpParameterivATI, NULL, 781),
- NAME_FUNC_OFFSET(13560, glTexBumpParameterfvATI, glTexBumpParameterfvATI, NULL, 782),
- NAME_FUNC_OFFSET(13584, glTexBumpParameterivATI, glTexBumpParameterivATI, NULL, 783),
- NAME_FUNC_OFFSET(13608, glAlphaFragmentOp1ATI, glAlphaFragmentOp1ATI, NULL, 784),
- NAME_FUNC_OFFSET(13630, glAlphaFragmentOp2ATI, glAlphaFragmentOp2ATI, NULL, 785),
- NAME_FUNC_OFFSET(13652, glAlphaFragmentOp3ATI, glAlphaFragmentOp3ATI, NULL, 786),
- NAME_FUNC_OFFSET(13674, glBeginFragmentShaderATI, glBeginFragmentShaderATI, NULL, 787),
- NAME_FUNC_OFFSET(13699, glBindFragmentShaderATI, glBindFragmentShaderATI, NULL, 788),
- NAME_FUNC_OFFSET(13723, glColorFragmentOp1ATI, glColorFragmentOp1ATI, NULL, 789),
- NAME_FUNC_OFFSET(13745, glColorFragmentOp2ATI, glColorFragmentOp2ATI, NULL, 790),
- NAME_FUNC_OFFSET(13767, glColorFragmentOp3ATI, glColorFragmentOp3ATI, NULL, 791),
- NAME_FUNC_OFFSET(13789, glDeleteFragmentShaderATI, glDeleteFragmentShaderATI, NULL, 792),
- NAME_FUNC_OFFSET(13815, glEndFragmentShaderATI, glEndFragmentShaderATI, NULL, 793),
- NAME_FUNC_OFFSET(13838, glGenFragmentShadersATI, glGenFragmentShadersATI, NULL, 794),
- NAME_FUNC_OFFSET(13862, glPassTexCoordATI, glPassTexCoordATI, NULL, 795),
- NAME_FUNC_OFFSET(13880, glSampleMapATI, glSampleMapATI, NULL, 796),
- NAME_FUNC_OFFSET(13895, glSetFragmentShaderConstantATI, glSetFragmentShaderConstantATI, NULL, 797),
- NAME_FUNC_OFFSET(13926, glPointParameteriNV, glPointParameteriNV, NULL, 798),
- NAME_FUNC_OFFSET(13946, glPointParameterivNV, glPointParameterivNV, NULL, 799),
- NAME_FUNC_OFFSET(13967, gl_dispatch_stub_800, gl_dispatch_stub_800, NULL, 800),
- NAME_FUNC_OFFSET(13990, gl_dispatch_stub_801, gl_dispatch_stub_801, NULL, 801),
- NAME_FUNC_OFFSET(14013, gl_dispatch_stub_802, gl_dispatch_stub_802, NULL, 802),
- NAME_FUNC_OFFSET(14039, gl_dispatch_stub_803, gl_dispatch_stub_803, NULL, 803),
- NAME_FUNC_OFFSET(14062, gl_dispatch_stub_804, gl_dispatch_stub_804, NULL, 804),
- NAME_FUNC_OFFSET(14083, glGetProgramNamedParameterdvNV, glGetProgramNamedParameterdvNV, NULL, 805),
- NAME_FUNC_OFFSET(14114, glGetProgramNamedParameterfvNV, glGetProgramNamedParameterfvNV, NULL, 806),
- NAME_FUNC_OFFSET(14145, glProgramNamedParameter4dNV, glProgramNamedParameter4dNV, NULL, 807),
- NAME_FUNC_OFFSET(14173, glProgramNamedParameter4dvNV, glProgramNamedParameter4dvNV, NULL, 808),
- NAME_FUNC_OFFSET(14202, glProgramNamedParameter4fNV, glProgramNamedParameter4fNV, NULL, 809),
- NAME_FUNC_OFFSET(14230, glProgramNamedParameter4fvNV, glProgramNamedParameter4fvNV, NULL, 810),
- NAME_FUNC_OFFSET(14259, glPrimitiveRestartIndexNV, glPrimitiveRestartIndexNV, NULL, 811),
- NAME_FUNC_OFFSET(14285, glPrimitiveRestartNV, glPrimitiveRestartNV, NULL, 812),
- NAME_FUNC_OFFSET(14306, gl_dispatch_stub_813, gl_dispatch_stub_813, NULL, 813),
- NAME_FUNC_OFFSET(14323, gl_dispatch_stub_814, gl_dispatch_stub_814, NULL, 814),
- NAME_FUNC_OFFSET(14350, glBindFramebufferEXT, glBindFramebufferEXT, NULL, 815),
- NAME_FUNC_OFFSET(14371, glBindRenderbufferEXT, glBindRenderbufferEXT, NULL, 816),
- NAME_FUNC_OFFSET(14393, glCheckFramebufferStatusEXT, glCheckFramebufferStatusEXT, NULL, 817),
- NAME_FUNC_OFFSET(14421, glDeleteFramebuffersEXT, glDeleteFramebuffersEXT, NULL, 818),
- NAME_FUNC_OFFSET(14445, glDeleteRenderbuffersEXT, glDeleteRenderbuffersEXT, NULL, 819),
- NAME_FUNC_OFFSET(14470, glFramebufferRenderbufferEXT, glFramebufferRenderbufferEXT, NULL, 820),
- NAME_FUNC_OFFSET(14499, glFramebufferTexture1DEXT, glFramebufferTexture1DEXT, NULL, 821),
- NAME_FUNC_OFFSET(14525, glFramebufferTexture2DEXT, glFramebufferTexture2DEXT, NULL, 822),
- NAME_FUNC_OFFSET(14551, glFramebufferTexture3DEXT, glFramebufferTexture3DEXT, NULL, 823),
- NAME_FUNC_OFFSET(14577, glGenFramebuffersEXT, glGenFramebuffersEXT, NULL, 824),
- NAME_FUNC_OFFSET(14598, glGenRenderbuffersEXT, glGenRenderbuffersEXT, NULL, 825),
- NAME_FUNC_OFFSET(14620, glGenerateMipmapEXT, glGenerateMipmapEXT, NULL, 826),
- NAME_FUNC_OFFSET(14640, glGetFramebufferAttachmentParameterivEXT, glGetFramebufferAttachmentParameterivEXT, NULL, 827),
- NAME_FUNC_OFFSET(14681, glGetRenderbufferParameterivEXT, glGetRenderbufferParameterivEXT, NULL, 828),
- NAME_FUNC_OFFSET(14713, glIsFramebufferEXT, glIsFramebufferEXT, NULL, 829),
- NAME_FUNC_OFFSET(14732, glIsRenderbufferEXT, glIsRenderbufferEXT, NULL, 830),
- NAME_FUNC_OFFSET(14752, glRenderbufferStorageEXT, glRenderbufferStorageEXT, NULL, 831),
- NAME_FUNC_OFFSET(14777, gl_dispatch_stub_832, gl_dispatch_stub_832, NULL, 832),
- NAME_FUNC_OFFSET(14798, gl_dispatch_stub_833, gl_dispatch_stub_833, NULL, 833),
- NAME_FUNC_OFFSET(14822, gl_dispatch_stub_834, gl_dispatch_stub_834, NULL, 834),
- NAME_FUNC_OFFSET(14852, glBindFragDataLocationEXT, glBindFragDataLocationEXT, NULL, 835),
- NAME_FUNC_OFFSET(14878, glGetFragDataLocationEXT, glGetFragDataLocationEXT, NULL, 836),
- NAME_FUNC_OFFSET(14903, glGetUniformuivEXT, glGetUniformuivEXT, NULL, 837),
- NAME_FUNC_OFFSET(14922, glGetVertexAttribIivEXT, glGetVertexAttribIivEXT, NULL, 838),
- NAME_FUNC_OFFSET(14946, glGetVertexAttribIuivEXT, glGetVertexAttribIuivEXT, NULL, 839),
- NAME_FUNC_OFFSET(14971, glUniform1uiEXT, glUniform1uiEXT, NULL, 840),
- NAME_FUNC_OFFSET(14987, glUniform1uivEXT, glUniform1uivEXT, NULL, 841),
- NAME_FUNC_OFFSET(15004, glUniform2uiEXT, glUniform2uiEXT, NULL, 842),
- NAME_FUNC_OFFSET(15020, glUniform2uivEXT, glUniform2uivEXT, NULL, 843),
- NAME_FUNC_OFFSET(15037, glUniform3uiEXT, glUniform3uiEXT, NULL, 844),
- NAME_FUNC_OFFSET(15053, glUniform3uivEXT, glUniform3uivEXT, NULL, 845),
- NAME_FUNC_OFFSET(15070, glUniform4uiEXT, glUniform4uiEXT, NULL, 846),
- NAME_FUNC_OFFSET(15086, glUniform4uivEXT, glUniform4uivEXT, NULL, 847),
- NAME_FUNC_OFFSET(15103, glVertexAttribI1iEXT, glVertexAttribI1iEXT, NULL, 848),
- NAME_FUNC_OFFSET(15124, glVertexAttribI1ivEXT, glVertexAttribI1ivEXT, NULL, 849),
- NAME_FUNC_OFFSET(15146, glVertexAttribI1uiEXT, glVertexAttribI1uiEXT, NULL, 850),
- NAME_FUNC_OFFSET(15168, glVertexAttribI1uivEXT, glVertexAttribI1uivEXT, NULL, 851),
- NAME_FUNC_OFFSET(15191, glVertexAttribI2iEXT, glVertexAttribI2iEXT, NULL, 852),
- NAME_FUNC_OFFSET(15212, glVertexAttribI2ivEXT, glVertexAttribI2ivEXT, NULL, 853),
- NAME_FUNC_OFFSET(15234, glVertexAttribI2uiEXT, glVertexAttribI2uiEXT, NULL, 854),
- NAME_FUNC_OFFSET(15256, glVertexAttribI2uivEXT, glVertexAttribI2uivEXT, NULL, 855),
- NAME_FUNC_OFFSET(15279, glVertexAttribI3iEXT, glVertexAttribI3iEXT, NULL, 856),
- NAME_FUNC_OFFSET(15300, glVertexAttribI3ivEXT, glVertexAttribI3ivEXT, NULL, 857),
- NAME_FUNC_OFFSET(15322, glVertexAttribI3uiEXT, glVertexAttribI3uiEXT, NULL, 858),
- NAME_FUNC_OFFSET(15344, glVertexAttribI3uivEXT, glVertexAttribI3uivEXT, NULL, 859),
- NAME_FUNC_OFFSET(15367, glVertexAttribI4bvEXT, glVertexAttribI4bvEXT, NULL, 860),
- NAME_FUNC_OFFSET(15389, glVertexAttribI4iEXT, glVertexAttribI4iEXT, NULL, 861),
- NAME_FUNC_OFFSET(15410, glVertexAttribI4ivEXT, glVertexAttribI4ivEXT, NULL, 862),
- NAME_FUNC_OFFSET(15432, glVertexAttribI4svEXT, glVertexAttribI4svEXT, NULL, 863),
- NAME_FUNC_OFFSET(15454, glVertexAttribI4ubvEXT, glVertexAttribI4ubvEXT, NULL, 864),
- NAME_FUNC_OFFSET(15477, glVertexAttribI4uiEXT, glVertexAttribI4uiEXT, NULL, 865),
- NAME_FUNC_OFFSET(15499, glVertexAttribI4uivEXT, glVertexAttribI4uivEXT, NULL, 866),
- NAME_FUNC_OFFSET(15522, glVertexAttribI4usvEXT, glVertexAttribI4usvEXT, NULL, 867),
- NAME_FUNC_OFFSET(15545, glVertexAttribIPointerEXT, glVertexAttribIPointerEXT, NULL, 868),
- NAME_FUNC_OFFSET(15571, glFramebufferTextureLayerEXT, glFramebufferTextureLayerEXT, NULL, 869),
- NAME_FUNC_OFFSET(15600, glColorMaskIndexedEXT, glColorMaskIndexedEXT, NULL, 870),
- NAME_FUNC_OFFSET(15622, glDisableIndexedEXT, glDisableIndexedEXT, NULL, 871),
- NAME_FUNC_OFFSET(15642, glEnableIndexedEXT, glEnableIndexedEXT, NULL, 872),
- NAME_FUNC_OFFSET(15661, glGetBooleanIndexedvEXT, glGetBooleanIndexedvEXT, NULL, 873),
- NAME_FUNC_OFFSET(15685, glGetIntegerIndexedvEXT, glGetIntegerIndexedvEXT, NULL, 874),
- NAME_FUNC_OFFSET(15709, glIsEnabledIndexedEXT, glIsEnabledIndexedEXT, NULL, 875),
- NAME_FUNC_OFFSET(15731, glClearColorIiEXT, glClearColorIiEXT, NULL, 876),
- NAME_FUNC_OFFSET(15749, glClearColorIuiEXT, glClearColorIuiEXT, NULL, 877),
- NAME_FUNC_OFFSET(15768, glGetTexParameterIivEXT, glGetTexParameterIivEXT, NULL, 878),
- NAME_FUNC_OFFSET(15792, glGetTexParameterIuivEXT, glGetTexParameterIuivEXT, NULL, 879),
- NAME_FUNC_OFFSET(15817, glTexParameterIivEXT, glTexParameterIivEXT, NULL, 880),
- NAME_FUNC_OFFSET(15838, glTexParameterIuivEXT, glTexParameterIuivEXT, NULL, 881),
- NAME_FUNC_OFFSET(15860, glBeginConditionalRenderNV, glBeginConditionalRenderNV, NULL, 882),
- NAME_FUNC_OFFSET(15887, glEndConditionalRenderNV, glEndConditionalRenderNV, NULL, 883),
- NAME_FUNC_OFFSET(15912, glBeginTransformFeedbackEXT, glBeginTransformFeedbackEXT, NULL, 884),
- NAME_FUNC_OFFSET(15940, glBindBufferBaseEXT, glBindBufferBaseEXT, NULL, 885),
- NAME_FUNC_OFFSET(15960, glBindBufferOffsetEXT, glBindBufferOffsetEXT, NULL, 886),
- NAME_FUNC_OFFSET(15982, glBindBufferRangeEXT, glBindBufferRangeEXT, NULL, 887),
- NAME_FUNC_OFFSET(16003, glEndTransformFeedbackEXT, glEndTransformFeedbackEXT, NULL, 888),
- NAME_FUNC_OFFSET(16029, glGetTransformFeedbackVaryingEXT, glGetTransformFeedbackVaryingEXT, NULL, 889),
- NAME_FUNC_OFFSET(16062, glTransformFeedbackVaryingsEXT, glTransformFeedbackVaryingsEXT, NULL, 890),
- NAME_FUNC_OFFSET(16093, glProvokingVertexEXT, glProvokingVertexEXT, NULL, 891),
- NAME_FUNC_OFFSET(16114, gl_dispatch_stub_892, gl_dispatch_stub_892, NULL, 892),
- NAME_FUNC_OFFSET(16145, gl_dispatch_stub_893, gl_dispatch_stub_893, NULL, 893),
- NAME_FUNC_OFFSET(16165, glGetObjectParameterivAPPLE, glGetObjectParameterivAPPLE, NULL, 894),
- NAME_FUNC_OFFSET(16193, glObjectPurgeableAPPLE, glObjectPurgeableAPPLE, NULL, 895),
- NAME_FUNC_OFFSET(16216, glObjectUnpurgeableAPPLE, glObjectUnpurgeableAPPLE, NULL, 896),
- NAME_FUNC_OFFSET(16241, glActiveProgramEXT, glActiveProgramEXT, NULL, 897),
- NAME_FUNC_OFFSET(16260, glCreateShaderProgramEXT, glCreateShaderProgramEXT, NULL, 898),
- NAME_FUNC_OFFSET(16285, glUseShaderProgramEXT, glUseShaderProgramEXT, NULL, 899),
- NAME_FUNC_OFFSET(16307, glTextureBarrierNV, glTextureBarrierNV, NULL, 900),
- NAME_FUNC_OFFSET(16326, gl_dispatch_stub_901, gl_dispatch_stub_901, NULL, 901),
- NAME_FUNC_OFFSET(16351, gl_dispatch_stub_902, gl_dispatch_stub_902, NULL, 902),
- NAME_FUNC_OFFSET(16380, gl_dispatch_stub_903, gl_dispatch_stub_903, NULL, 903),
- NAME_FUNC_OFFSET(16411, gl_dispatch_stub_904, gl_dispatch_stub_904, NULL, 904),
- NAME_FUNC_OFFSET(16435, gl_dispatch_stub_905, gl_dispatch_stub_905, NULL, 905),
- NAME_FUNC_OFFSET(16460, glEGLImageTargetRenderbufferStorageOES, glEGLImageTargetRenderbufferStorageOES, NULL, 906),
- NAME_FUNC_OFFSET(16499, glEGLImageTargetTexture2DOES, glEGLImageTargetTexture2DOES, NULL, 907),
- NAME_FUNC_OFFSET(16528, glArrayElement, glArrayElement, NULL, 306),
- NAME_FUNC_OFFSET(16546, glBindTexture, glBindTexture, NULL, 307),
- NAME_FUNC_OFFSET(16563, glDrawArrays, glDrawArrays, NULL, 310),
- NAME_FUNC_OFFSET(16579, glAreTexturesResident, glAreTexturesResidentEXT, glAreTexturesResidentEXT, 322),
- NAME_FUNC_OFFSET(16604, glCopyTexImage1D, glCopyTexImage1D, NULL, 323),
- NAME_FUNC_OFFSET(16624, glCopyTexImage2D, glCopyTexImage2D, NULL, 324),
- NAME_FUNC_OFFSET(16644, glCopyTexSubImage1D, glCopyTexSubImage1D, NULL, 325),
- NAME_FUNC_OFFSET(16667, glCopyTexSubImage2D, glCopyTexSubImage2D, NULL, 326),
- NAME_FUNC_OFFSET(16690, glDeleteTextures, glDeleteTexturesEXT, glDeleteTexturesEXT, 327),
- NAME_FUNC_OFFSET(16710, glGenTextures, glGenTexturesEXT, glGenTexturesEXT, 328),
- NAME_FUNC_OFFSET(16727, glGetPointerv, glGetPointerv, NULL, 329),
- NAME_FUNC_OFFSET(16744, glIsTexture, glIsTextureEXT, glIsTextureEXT, 330),
- NAME_FUNC_OFFSET(16759, glPrioritizeTextures, glPrioritizeTextures, NULL, 331),
- NAME_FUNC_OFFSET(16783, glTexSubImage1D, glTexSubImage1D, NULL, 332),
- NAME_FUNC_OFFSET(16802, glTexSubImage2D, glTexSubImage2D, NULL, 333),
- NAME_FUNC_OFFSET(16821, glBlendColor, glBlendColor, NULL, 336),
- NAME_FUNC_OFFSET(16837, glBlendEquation, glBlendEquation, NULL, 337),
- NAME_FUNC_OFFSET(16856, glDrawRangeElements, glDrawRangeElements, NULL, 338),
- NAME_FUNC_OFFSET(16879, glColorTable, glColorTable, NULL, 339),
- NAME_FUNC_OFFSET(16895, glColorTable, glColorTable, NULL, 339),
- NAME_FUNC_OFFSET(16911, glColorTableParameterfv, glColorTableParameterfv, NULL, 340),
- NAME_FUNC_OFFSET(16938, glColorTableParameteriv, glColorTableParameteriv, NULL, 341),
- NAME_FUNC_OFFSET(16965, glCopyColorTable, glCopyColorTable, NULL, 342),
- NAME_FUNC_OFFSET(16985, glGetColorTable, glGetColorTableEXT, glGetColorTableEXT, 343),
- NAME_FUNC_OFFSET(17004, glGetColorTable, glGetColorTableEXT, glGetColorTableEXT, 343),
- NAME_FUNC_OFFSET(17023, glGetColorTableParameterfv, glGetColorTableParameterfvEXT, glGetColorTableParameterfvEXT, 344),
- NAME_FUNC_OFFSET(17053, glGetColorTableParameterfv, glGetColorTableParameterfvEXT, glGetColorTableParameterfvEXT, 344),
- NAME_FUNC_OFFSET(17083, glGetColorTableParameteriv, glGetColorTableParameterivEXT, glGetColorTableParameterivEXT, 345),
- NAME_FUNC_OFFSET(17113, glGetColorTableParameteriv, glGetColorTableParameterivEXT, glGetColorTableParameterivEXT, 345),
- NAME_FUNC_OFFSET(17143, glColorSubTable, glColorSubTable, NULL, 346),
- NAME_FUNC_OFFSET(17162, glCopyColorSubTable, glCopyColorSubTable, NULL, 347),
- NAME_FUNC_OFFSET(17185, glConvolutionFilter1D, glConvolutionFilter1D, NULL, 348),
- NAME_FUNC_OFFSET(17210, glConvolutionFilter2D, glConvolutionFilter2D, NULL, 349),
- NAME_FUNC_OFFSET(17235, glConvolutionParameterf, glConvolutionParameterf, NULL, 350),
- NAME_FUNC_OFFSET(17262, glConvolutionParameterfv, glConvolutionParameterfv, NULL, 351),
- NAME_FUNC_OFFSET(17290, glConvolutionParameteri, glConvolutionParameteri, NULL, 352),
- NAME_FUNC_OFFSET(17317, glConvolutionParameteriv, glConvolutionParameteriv, NULL, 353),
- NAME_FUNC_OFFSET(17345, glCopyConvolutionFilter1D, glCopyConvolutionFilter1D, NULL, 354),
- NAME_FUNC_OFFSET(17374, glCopyConvolutionFilter2D, glCopyConvolutionFilter2D, NULL, 355),
- NAME_FUNC_OFFSET(17403, glGetConvolutionFilter, gl_dispatch_stub_356, gl_dispatch_stub_356, 356),
- NAME_FUNC_OFFSET(17429, glGetConvolutionParameterfv, gl_dispatch_stub_357, gl_dispatch_stub_357, 357),
- NAME_FUNC_OFFSET(17460, glGetConvolutionParameteriv, gl_dispatch_stub_358, gl_dispatch_stub_358, 358),
- NAME_FUNC_OFFSET(17491, glGetSeparableFilter, gl_dispatch_stub_359, gl_dispatch_stub_359, 359),
- NAME_FUNC_OFFSET(17515, glSeparableFilter2D, glSeparableFilter2D, NULL, 360),
- NAME_FUNC_OFFSET(17538, glGetHistogram, gl_dispatch_stub_361, gl_dispatch_stub_361, 361),
- NAME_FUNC_OFFSET(17556, glGetHistogramParameterfv, gl_dispatch_stub_362, gl_dispatch_stub_362, 362),
- NAME_FUNC_OFFSET(17585, glGetHistogramParameteriv, gl_dispatch_stub_363, gl_dispatch_stub_363, 363),
- NAME_FUNC_OFFSET(17614, glGetMinmax, gl_dispatch_stub_364, gl_dispatch_stub_364, 364),
- NAME_FUNC_OFFSET(17629, glGetMinmaxParameterfv, gl_dispatch_stub_365, gl_dispatch_stub_365, 365),
- NAME_FUNC_OFFSET(17655, glGetMinmaxParameteriv, gl_dispatch_stub_366, gl_dispatch_stub_366, 366),
- NAME_FUNC_OFFSET(17681, glHistogram, glHistogram, NULL, 367),
- NAME_FUNC_OFFSET(17696, glMinmax, glMinmax, NULL, 368),
- NAME_FUNC_OFFSET(17708, glResetHistogram, glResetHistogram, NULL, 369),
- NAME_FUNC_OFFSET(17728, glResetMinmax, glResetMinmax, NULL, 370),
- NAME_FUNC_OFFSET(17745, glTexImage3D, glTexImage3D, NULL, 371),
- NAME_FUNC_OFFSET(17761, glTexSubImage3D, glTexSubImage3D, NULL, 372),
- NAME_FUNC_OFFSET(17780, glCopyTexSubImage3D, glCopyTexSubImage3D, NULL, 373),
- NAME_FUNC_OFFSET(17803, glActiveTextureARB, glActiveTextureARB, NULL, 374),
- NAME_FUNC_OFFSET(17819, glClientActiveTextureARB, glClientActiveTextureARB, NULL, 375),
- NAME_FUNC_OFFSET(17841, glMultiTexCoord1dARB, glMultiTexCoord1dARB, NULL, 376),
- NAME_FUNC_OFFSET(17859, glMultiTexCoord1dvARB, glMultiTexCoord1dvARB, NULL, 377),
- NAME_FUNC_OFFSET(17878, glMultiTexCoord1fARB, glMultiTexCoord1fARB, NULL, 378),
- NAME_FUNC_OFFSET(17896, glMultiTexCoord1fvARB, glMultiTexCoord1fvARB, NULL, 379),
- NAME_FUNC_OFFSET(17915, glMultiTexCoord1iARB, glMultiTexCoord1iARB, NULL, 380),
- NAME_FUNC_OFFSET(17933, glMultiTexCoord1ivARB, glMultiTexCoord1ivARB, NULL, 381),
- NAME_FUNC_OFFSET(17952, glMultiTexCoord1sARB, glMultiTexCoord1sARB, NULL, 382),
- NAME_FUNC_OFFSET(17970, glMultiTexCoord1svARB, glMultiTexCoord1svARB, NULL, 383),
- NAME_FUNC_OFFSET(17989, glMultiTexCoord2dARB, glMultiTexCoord2dARB, NULL, 384),
- NAME_FUNC_OFFSET(18007, glMultiTexCoord2dvARB, glMultiTexCoord2dvARB, NULL, 385),
- NAME_FUNC_OFFSET(18026, glMultiTexCoord2fARB, glMultiTexCoord2fARB, NULL, 386),
- NAME_FUNC_OFFSET(18044, glMultiTexCoord2fvARB, glMultiTexCoord2fvARB, NULL, 387),
- NAME_FUNC_OFFSET(18063, glMultiTexCoord2iARB, glMultiTexCoord2iARB, NULL, 388),
- NAME_FUNC_OFFSET(18081, glMultiTexCoord2ivARB, glMultiTexCoord2ivARB, NULL, 389),
- NAME_FUNC_OFFSET(18100, glMultiTexCoord2sARB, glMultiTexCoord2sARB, NULL, 390),
- NAME_FUNC_OFFSET(18118, glMultiTexCoord2svARB, glMultiTexCoord2svARB, NULL, 391),
- NAME_FUNC_OFFSET(18137, glMultiTexCoord3dARB, glMultiTexCoord3dARB, NULL, 392),
- NAME_FUNC_OFFSET(18155, glMultiTexCoord3dvARB, glMultiTexCoord3dvARB, NULL, 393),
- NAME_FUNC_OFFSET(18174, glMultiTexCoord3fARB, glMultiTexCoord3fARB, NULL, 394),
- NAME_FUNC_OFFSET(18192, glMultiTexCoord3fvARB, glMultiTexCoord3fvARB, NULL, 395),
- NAME_FUNC_OFFSET(18211, glMultiTexCoord3iARB, glMultiTexCoord3iARB, NULL, 396),
- NAME_FUNC_OFFSET(18229, glMultiTexCoord3ivARB, glMultiTexCoord3ivARB, NULL, 397),
- NAME_FUNC_OFFSET(18248, glMultiTexCoord3sARB, glMultiTexCoord3sARB, NULL, 398),
- NAME_FUNC_OFFSET(18266, glMultiTexCoord3svARB, glMultiTexCoord3svARB, NULL, 399),
- NAME_FUNC_OFFSET(18285, glMultiTexCoord4dARB, glMultiTexCoord4dARB, NULL, 400),
- NAME_FUNC_OFFSET(18303, glMultiTexCoord4dvARB, glMultiTexCoord4dvARB, NULL, 401),
- NAME_FUNC_OFFSET(18322, glMultiTexCoord4fARB, glMultiTexCoord4fARB, NULL, 402),
- NAME_FUNC_OFFSET(18340, glMultiTexCoord4fvARB, glMultiTexCoord4fvARB, NULL, 403),
- NAME_FUNC_OFFSET(18359, glMultiTexCoord4iARB, glMultiTexCoord4iARB, NULL, 404),
- NAME_FUNC_OFFSET(18377, glMultiTexCoord4ivARB, glMultiTexCoord4ivARB, NULL, 405),
- NAME_FUNC_OFFSET(18396, glMultiTexCoord4sARB, glMultiTexCoord4sARB, NULL, 406),
- NAME_FUNC_OFFSET(18414, glMultiTexCoord4svARB, glMultiTexCoord4svARB, NULL, 407),
- NAME_FUNC_OFFSET(18433, glStencilOpSeparate, glStencilOpSeparate, NULL, 423),
- NAME_FUNC_OFFSET(18456, glLoadTransposeMatrixdARB, glLoadTransposeMatrixdARB, NULL, 441),
- NAME_FUNC_OFFSET(18479, glLoadTransposeMatrixfARB, glLoadTransposeMatrixfARB, NULL, 442),
- NAME_FUNC_OFFSET(18502, glMultTransposeMatrixdARB, glMultTransposeMatrixdARB, NULL, 443),
- NAME_FUNC_OFFSET(18525, glMultTransposeMatrixfARB, glMultTransposeMatrixfARB, NULL, 444),
- NAME_FUNC_OFFSET(18548, glSampleCoverageARB, glSampleCoverageARB, NULL, 445),
- NAME_FUNC_OFFSET(18565, glCompressedTexImage1DARB, glCompressedTexImage1DARB, NULL, 446),
- NAME_FUNC_OFFSET(18588, glCompressedTexImage2DARB, glCompressedTexImage2DARB, NULL, 447),
- NAME_FUNC_OFFSET(18611, glCompressedTexImage3DARB, glCompressedTexImage3DARB, NULL, 448),
- NAME_FUNC_OFFSET(18634, glCompressedTexSubImage1DARB, glCompressedTexSubImage1DARB, NULL, 449),
- NAME_FUNC_OFFSET(18660, glCompressedTexSubImage2DARB, glCompressedTexSubImage2DARB, NULL, 450),
- NAME_FUNC_OFFSET(18686, glCompressedTexSubImage3DARB, glCompressedTexSubImage3DARB, NULL, 451),
- NAME_FUNC_OFFSET(18712, glGetCompressedTexImageARB, glGetCompressedTexImageARB, NULL, 452),
- NAME_FUNC_OFFSET(18736, glDisableVertexAttribArrayARB, glDisableVertexAttribArrayARB, NULL, 453),
- NAME_FUNC_OFFSET(18763, glEnableVertexAttribArrayARB, glEnableVertexAttribArrayARB, NULL, 454),
- NAME_FUNC_OFFSET(18789, glGetVertexAttribdvARB, glGetVertexAttribdvARB, NULL, 461),
- NAME_FUNC_OFFSET(18809, glGetVertexAttribfvARB, glGetVertexAttribfvARB, NULL, 462),
- NAME_FUNC_OFFSET(18829, glGetVertexAttribivARB, glGetVertexAttribivARB, NULL, 463),
- NAME_FUNC_OFFSET(18849, glProgramEnvParameter4dARB, glProgramEnvParameter4dARB, NULL, 464),
- NAME_FUNC_OFFSET(18872, glProgramEnvParameter4dvARB, glProgramEnvParameter4dvARB, NULL, 465),
- NAME_FUNC_OFFSET(18896, glProgramEnvParameter4fARB, glProgramEnvParameter4fARB, NULL, 466),
- NAME_FUNC_OFFSET(18919, glProgramEnvParameter4fvARB, glProgramEnvParameter4fvARB, NULL, 467),
- NAME_FUNC_OFFSET(18943, glVertexAttrib1dARB, glVertexAttrib1dARB, NULL, 473),
- NAME_FUNC_OFFSET(18960, glVertexAttrib1dvARB, glVertexAttrib1dvARB, NULL, 474),
- NAME_FUNC_OFFSET(18978, glVertexAttrib1fARB, glVertexAttrib1fARB, NULL, 475),
- NAME_FUNC_OFFSET(18995, glVertexAttrib1fvARB, glVertexAttrib1fvARB, NULL, 476),
- NAME_FUNC_OFFSET(19013, glVertexAttrib1sARB, glVertexAttrib1sARB, NULL, 477),
- NAME_FUNC_OFFSET(19030, glVertexAttrib1svARB, glVertexAttrib1svARB, NULL, 478),
- NAME_FUNC_OFFSET(19048, glVertexAttrib2dARB, glVertexAttrib2dARB, NULL, 479),
- NAME_FUNC_OFFSET(19065, glVertexAttrib2dvARB, glVertexAttrib2dvARB, NULL, 480),
- NAME_FUNC_OFFSET(19083, glVertexAttrib2fARB, glVertexAttrib2fARB, NULL, 481),
- NAME_FUNC_OFFSET(19100, glVertexAttrib2fvARB, glVertexAttrib2fvARB, NULL, 482),
- NAME_FUNC_OFFSET(19118, glVertexAttrib2sARB, glVertexAttrib2sARB, NULL, 483),
- NAME_FUNC_OFFSET(19135, glVertexAttrib2svARB, glVertexAttrib2svARB, NULL, 484),
- NAME_FUNC_OFFSET(19153, glVertexAttrib3dARB, glVertexAttrib3dARB, NULL, 485),
- NAME_FUNC_OFFSET(19170, glVertexAttrib3dvARB, glVertexAttrib3dvARB, NULL, 486),
- NAME_FUNC_OFFSET(19188, glVertexAttrib3fARB, glVertexAttrib3fARB, NULL, 487),
- NAME_FUNC_OFFSET(19205, glVertexAttrib3fvARB, glVertexAttrib3fvARB, NULL, 488),
- NAME_FUNC_OFFSET(19223, glVertexAttrib3sARB, glVertexAttrib3sARB, NULL, 489),
- NAME_FUNC_OFFSET(19240, glVertexAttrib3svARB, glVertexAttrib3svARB, NULL, 490),
- NAME_FUNC_OFFSET(19258, glVertexAttrib4NbvARB, glVertexAttrib4NbvARB, NULL, 491),
- NAME_FUNC_OFFSET(19277, glVertexAttrib4NivARB, glVertexAttrib4NivARB, NULL, 492),
- NAME_FUNC_OFFSET(19296, glVertexAttrib4NsvARB, glVertexAttrib4NsvARB, NULL, 493),
- NAME_FUNC_OFFSET(19315, glVertexAttrib4NubARB, glVertexAttrib4NubARB, NULL, 494),
- NAME_FUNC_OFFSET(19334, glVertexAttrib4NubvARB, glVertexAttrib4NubvARB, NULL, 495),
- NAME_FUNC_OFFSET(19354, glVertexAttrib4NuivARB, glVertexAttrib4NuivARB, NULL, 496),
- NAME_FUNC_OFFSET(19374, glVertexAttrib4NusvARB, glVertexAttrib4NusvARB, NULL, 497),
- NAME_FUNC_OFFSET(19394, glVertexAttrib4bvARB, glVertexAttrib4bvARB, NULL, 498),
- NAME_FUNC_OFFSET(19412, glVertexAttrib4dARB, glVertexAttrib4dARB, NULL, 499),
- NAME_FUNC_OFFSET(19429, glVertexAttrib4dvARB, glVertexAttrib4dvARB, NULL, 500),
- NAME_FUNC_OFFSET(19447, glVertexAttrib4fARB, glVertexAttrib4fARB, NULL, 501),
- NAME_FUNC_OFFSET(19464, glVertexAttrib4fvARB, glVertexAttrib4fvARB, NULL, 502),
- NAME_FUNC_OFFSET(19482, glVertexAttrib4ivARB, glVertexAttrib4ivARB, NULL, 503),
- NAME_FUNC_OFFSET(19500, glVertexAttrib4sARB, glVertexAttrib4sARB, NULL, 504),
- NAME_FUNC_OFFSET(19517, glVertexAttrib4svARB, glVertexAttrib4svARB, NULL, 505),
- NAME_FUNC_OFFSET(19535, glVertexAttrib4ubvARB, glVertexAttrib4ubvARB, NULL, 506),
- NAME_FUNC_OFFSET(19554, glVertexAttrib4uivARB, glVertexAttrib4uivARB, NULL, 507),
- NAME_FUNC_OFFSET(19573, glVertexAttrib4usvARB, glVertexAttrib4usvARB, NULL, 508),
- NAME_FUNC_OFFSET(19592, glVertexAttribPointerARB, glVertexAttribPointerARB, NULL, 509),
- NAME_FUNC_OFFSET(19614, glBindBufferARB, glBindBufferARB, NULL, 510),
- NAME_FUNC_OFFSET(19627, glBufferDataARB, glBufferDataARB, NULL, 511),
- NAME_FUNC_OFFSET(19640, glBufferSubDataARB, glBufferSubDataARB, NULL, 512),
- NAME_FUNC_OFFSET(19656, glDeleteBuffersARB, glDeleteBuffersARB, NULL, 513),
- NAME_FUNC_OFFSET(19672, glGenBuffersARB, glGenBuffersARB, NULL, 514),
- NAME_FUNC_OFFSET(19685, glGetBufferParameterivARB, glGetBufferParameterivARB, NULL, 515),
- NAME_FUNC_OFFSET(19708, glGetBufferPointervARB, glGetBufferPointervARB, NULL, 516),
- NAME_FUNC_OFFSET(19728, glGetBufferSubDataARB, glGetBufferSubDataARB, NULL, 517),
- NAME_FUNC_OFFSET(19747, glIsBufferARB, glIsBufferARB, NULL, 518),
- NAME_FUNC_OFFSET(19758, glMapBufferARB, glMapBufferARB, NULL, 519),
- NAME_FUNC_OFFSET(19770, glUnmapBufferARB, glUnmapBufferARB, NULL, 520),
- NAME_FUNC_OFFSET(19784, glBeginQueryARB, glBeginQueryARB, NULL, 521),
- NAME_FUNC_OFFSET(19797, glDeleteQueriesARB, glDeleteQueriesARB, NULL, 522),
- NAME_FUNC_OFFSET(19813, glEndQueryARB, glEndQueryARB, NULL, 523),
- NAME_FUNC_OFFSET(19824, glGenQueriesARB, glGenQueriesARB, NULL, 524),
- NAME_FUNC_OFFSET(19837, glGetQueryObjectivARB, glGetQueryObjectivARB, NULL, 525),
- NAME_FUNC_OFFSET(19856, glGetQueryObjectuivARB, glGetQueryObjectuivARB, NULL, 526),
- NAME_FUNC_OFFSET(19876, glGetQueryivARB, glGetQueryivARB, NULL, 527),
- NAME_FUNC_OFFSET(19889, glIsQueryARB, glIsQueryARB, NULL, 528),
- NAME_FUNC_OFFSET(19899, glCompileShaderARB, glCompileShaderARB, NULL, 530),
- NAME_FUNC_OFFSET(19915, glGetActiveUniformARB, glGetActiveUniformARB, NULL, 535),
- NAME_FUNC_OFFSET(19934, glGetShaderSourceARB, glGetShaderSourceARB, NULL, 541),
- NAME_FUNC_OFFSET(19952, glGetUniformLocationARB, glGetUniformLocationARB, NULL, 542),
- NAME_FUNC_OFFSET(19973, glGetUniformfvARB, glGetUniformfvARB, NULL, 543),
- NAME_FUNC_OFFSET(19988, glGetUniformivARB, glGetUniformivARB, NULL, 544),
- NAME_FUNC_OFFSET(20003, glLinkProgramARB, glLinkProgramARB, NULL, 545),
- NAME_FUNC_OFFSET(20017, glShaderSourceARB, glShaderSourceARB, NULL, 546),
- NAME_FUNC_OFFSET(20032, glUniform1fARB, glUniform1fARB, NULL, 547),
- NAME_FUNC_OFFSET(20044, glUniform1fvARB, glUniform1fvARB, NULL, 548),
- NAME_FUNC_OFFSET(20057, glUniform1iARB, glUniform1iARB, NULL, 549),
- NAME_FUNC_OFFSET(20069, glUniform1ivARB, glUniform1ivARB, NULL, 550),
- NAME_FUNC_OFFSET(20082, glUniform2fARB, glUniform2fARB, NULL, 551),
- NAME_FUNC_OFFSET(20094, glUniform2fvARB, glUniform2fvARB, NULL, 552),
- NAME_FUNC_OFFSET(20107, glUniform2iARB, glUniform2iARB, NULL, 553),
- NAME_FUNC_OFFSET(20119, glUniform2ivARB, glUniform2ivARB, NULL, 554),
- NAME_FUNC_OFFSET(20132, glUniform3fARB, glUniform3fARB, NULL, 555),
- NAME_FUNC_OFFSET(20144, glUniform3fvARB, glUniform3fvARB, NULL, 556),
- NAME_FUNC_OFFSET(20157, glUniform3iARB, glUniform3iARB, NULL, 557),
- NAME_FUNC_OFFSET(20169, glUniform3ivARB, glUniform3ivARB, NULL, 558),
- NAME_FUNC_OFFSET(20182, glUniform4fARB, glUniform4fARB, NULL, 559),
- NAME_FUNC_OFFSET(20194, glUniform4fvARB, glUniform4fvARB, NULL, 560),
- NAME_FUNC_OFFSET(20207, glUniform4iARB, glUniform4iARB, NULL, 561),
- NAME_FUNC_OFFSET(20219, glUniform4ivARB, glUniform4ivARB, NULL, 562),
- NAME_FUNC_OFFSET(20232, glUniformMatrix2fvARB, glUniformMatrix2fvARB, NULL, 563),
- NAME_FUNC_OFFSET(20251, glUniformMatrix3fvARB, glUniformMatrix3fvARB, NULL, 564),
- NAME_FUNC_OFFSET(20270, glUniformMatrix4fvARB, glUniformMatrix4fvARB, NULL, 565),
- NAME_FUNC_OFFSET(20289, glUseProgramObjectARB, glUseProgramObjectARB, NULL, 566),
- NAME_FUNC_OFFSET(20302, glValidateProgramARB, glValidateProgramARB, NULL, 567),
- NAME_FUNC_OFFSET(20320, glBindAttribLocationARB, glBindAttribLocationARB, NULL, 568),
- NAME_FUNC_OFFSET(20341, glGetActiveAttribARB, glGetActiveAttribARB, NULL, 569),
- NAME_FUNC_OFFSET(20359, glGetAttribLocationARB, glGetAttribLocationARB, NULL, 570),
- NAME_FUNC_OFFSET(20379, glDrawBuffersARB, glDrawBuffersARB, NULL, 571),
- NAME_FUNC_OFFSET(20393, glDrawBuffersARB, glDrawBuffersARB, NULL, 571),
- NAME_FUNC_OFFSET(20410, glDrawArraysInstancedARB, glDrawArraysInstancedARB, NULL, 573),
- NAME_FUNC_OFFSET(20435, glDrawArraysInstancedARB, glDrawArraysInstancedARB, NULL, 573),
- NAME_FUNC_OFFSET(20457, glDrawElementsInstancedARB, glDrawElementsInstancedARB, NULL, 574),
- NAME_FUNC_OFFSET(20484, glDrawElementsInstancedARB, glDrawElementsInstancedARB, NULL, 574),
- NAME_FUNC_OFFSET(20508, glRenderbufferStorageMultisample, glRenderbufferStorageMultisample, NULL, 575),
- NAME_FUNC_OFFSET(20544, gl_dispatch_stub_633, gl_dispatch_stub_633, NULL, 633),
- NAME_FUNC_OFFSET(20560, gl_dispatch_stub_634, gl_dispatch_stub_634, NULL, 634),
- NAME_FUNC_OFFSET(20579, glPointParameterfEXT, glPointParameterfEXT, NULL, 641),
- NAME_FUNC_OFFSET(20597, glPointParameterfEXT, glPointParameterfEXT, NULL, 641),
- NAME_FUNC_OFFSET(20618, glPointParameterfEXT, glPointParameterfEXT, NULL, 641),
- NAME_FUNC_OFFSET(20640, glPointParameterfvEXT, glPointParameterfvEXT, NULL, 642),
- NAME_FUNC_OFFSET(20659, glPointParameterfvEXT, glPointParameterfvEXT, NULL, 642),
- NAME_FUNC_OFFSET(20681, glPointParameterfvEXT, glPointParameterfvEXT, NULL, 642),
- NAME_FUNC_OFFSET(20704, glSecondaryColor3bEXT, glSecondaryColor3bEXT, NULL, 645),
- NAME_FUNC_OFFSET(20723, glSecondaryColor3bvEXT, glSecondaryColor3bvEXT, NULL, 646),
- NAME_FUNC_OFFSET(20743, glSecondaryColor3dEXT, glSecondaryColor3dEXT, NULL, 647),
- NAME_FUNC_OFFSET(20762, glSecondaryColor3dvEXT, glSecondaryColor3dvEXT, NULL, 648),
- NAME_FUNC_OFFSET(20782, glSecondaryColor3fEXT, glSecondaryColor3fEXT, NULL, 649),
- NAME_FUNC_OFFSET(20801, glSecondaryColor3fvEXT, glSecondaryColor3fvEXT, NULL, 650),
- NAME_FUNC_OFFSET(20821, glSecondaryColor3iEXT, glSecondaryColor3iEXT, NULL, 651),
- NAME_FUNC_OFFSET(20840, glSecondaryColor3ivEXT, glSecondaryColor3ivEXT, NULL, 652),
- NAME_FUNC_OFFSET(20860, glSecondaryColor3sEXT, glSecondaryColor3sEXT, NULL, 653),
- NAME_FUNC_OFFSET(20879, glSecondaryColor3svEXT, glSecondaryColor3svEXT, NULL, 654),
- NAME_FUNC_OFFSET(20899, glSecondaryColor3ubEXT, glSecondaryColor3ubEXT, NULL, 655),
- NAME_FUNC_OFFSET(20919, glSecondaryColor3ubvEXT, glSecondaryColor3ubvEXT, NULL, 656),
- NAME_FUNC_OFFSET(20940, glSecondaryColor3uiEXT, glSecondaryColor3uiEXT, NULL, 657),
- NAME_FUNC_OFFSET(20960, glSecondaryColor3uivEXT, glSecondaryColor3uivEXT, NULL, 658),
- NAME_FUNC_OFFSET(20981, glSecondaryColor3usEXT, glSecondaryColor3usEXT, NULL, 659),
- NAME_FUNC_OFFSET(21001, glSecondaryColor3usvEXT, glSecondaryColor3usvEXT, NULL, 660),
- NAME_FUNC_OFFSET(21022, glSecondaryColorPointerEXT, glSecondaryColorPointerEXT, NULL, 661),
- NAME_FUNC_OFFSET(21046, glMultiDrawArraysEXT, glMultiDrawArraysEXT, NULL, 662),
- NAME_FUNC_OFFSET(21064, glMultiDrawElementsEXT, glMultiDrawElementsEXT, NULL, 663),
- NAME_FUNC_OFFSET(21084, glFogCoordPointerEXT, glFogCoordPointerEXT, NULL, 664),
- NAME_FUNC_OFFSET(21102, glFogCoorddEXT, glFogCoorddEXT, NULL, 665),
- NAME_FUNC_OFFSET(21114, glFogCoorddvEXT, glFogCoorddvEXT, NULL, 666),
- NAME_FUNC_OFFSET(21127, glFogCoordfEXT, glFogCoordfEXT, NULL, 667),
- NAME_FUNC_OFFSET(21139, glFogCoordfvEXT, glFogCoordfvEXT, NULL, 668),
- NAME_FUNC_OFFSET(21152, glBlendFuncSeparateEXT, glBlendFuncSeparateEXT, NULL, 670),
- NAME_FUNC_OFFSET(21172, glBlendFuncSeparateEXT, glBlendFuncSeparateEXT, NULL, 670),
- NAME_FUNC_OFFSET(21196, glWindowPos2dMESA, glWindowPos2dMESA, NULL, 687),
- NAME_FUNC_OFFSET(21210, glWindowPos2dMESA, glWindowPos2dMESA, NULL, 687),
- NAME_FUNC_OFFSET(21227, glWindowPos2dvMESA, glWindowPos2dvMESA, NULL, 688),
- NAME_FUNC_OFFSET(21242, glWindowPos2dvMESA, glWindowPos2dvMESA, NULL, 688),
- NAME_FUNC_OFFSET(21260, glWindowPos2fMESA, glWindowPos2fMESA, NULL, 689),
- NAME_FUNC_OFFSET(21274, glWindowPos2fMESA, glWindowPos2fMESA, NULL, 689),
- NAME_FUNC_OFFSET(21291, glWindowPos2fvMESA, glWindowPos2fvMESA, NULL, 690),
- NAME_FUNC_OFFSET(21306, glWindowPos2fvMESA, glWindowPos2fvMESA, NULL, 690),
- NAME_FUNC_OFFSET(21324, glWindowPos2iMESA, glWindowPos2iMESA, NULL, 691),
- NAME_FUNC_OFFSET(21338, glWindowPos2iMESA, glWindowPos2iMESA, NULL, 691),
- NAME_FUNC_OFFSET(21355, glWindowPos2ivMESA, glWindowPos2ivMESA, NULL, 692),
- NAME_FUNC_OFFSET(21370, glWindowPos2ivMESA, glWindowPos2ivMESA, NULL, 692),
- NAME_FUNC_OFFSET(21388, glWindowPos2sMESA, glWindowPos2sMESA, NULL, 693),
- NAME_FUNC_OFFSET(21402, glWindowPos2sMESA, glWindowPos2sMESA, NULL, 693),
- NAME_FUNC_OFFSET(21419, glWindowPos2svMESA, glWindowPos2svMESA, NULL, 694),
- NAME_FUNC_OFFSET(21434, glWindowPos2svMESA, glWindowPos2svMESA, NULL, 694),
- NAME_FUNC_OFFSET(21452, glWindowPos3dMESA, glWindowPos3dMESA, NULL, 695),
- NAME_FUNC_OFFSET(21466, glWindowPos3dMESA, glWindowPos3dMESA, NULL, 695),
- NAME_FUNC_OFFSET(21483, glWindowPos3dvMESA, glWindowPos3dvMESA, NULL, 696),
- NAME_FUNC_OFFSET(21498, glWindowPos3dvMESA, glWindowPos3dvMESA, NULL, 696),
- NAME_FUNC_OFFSET(21516, glWindowPos3fMESA, glWindowPos3fMESA, NULL, 697),
- NAME_FUNC_OFFSET(21530, glWindowPos3fMESA, glWindowPos3fMESA, NULL, 697),
- NAME_FUNC_OFFSET(21547, glWindowPos3fvMESA, glWindowPos3fvMESA, NULL, 698),
- NAME_FUNC_OFFSET(21562, glWindowPos3fvMESA, glWindowPos3fvMESA, NULL, 698),
- NAME_FUNC_OFFSET(21580, glWindowPos3iMESA, glWindowPos3iMESA, NULL, 699),
- NAME_FUNC_OFFSET(21594, glWindowPos3iMESA, glWindowPos3iMESA, NULL, 699),
- NAME_FUNC_OFFSET(21611, glWindowPos3ivMESA, glWindowPos3ivMESA, NULL, 700),
- NAME_FUNC_OFFSET(21626, glWindowPos3ivMESA, glWindowPos3ivMESA, NULL, 700),
- NAME_FUNC_OFFSET(21644, glWindowPos3sMESA, glWindowPos3sMESA, NULL, 701),
- NAME_FUNC_OFFSET(21658, glWindowPos3sMESA, glWindowPos3sMESA, NULL, 701),
- NAME_FUNC_OFFSET(21675, glWindowPos3svMESA, glWindowPos3svMESA, NULL, 702),
- NAME_FUNC_OFFSET(21690, glWindowPos3svMESA, glWindowPos3svMESA, NULL, 702),
- NAME_FUNC_OFFSET(21708, glBindProgramNV, glBindProgramNV, NULL, 721),
- NAME_FUNC_OFFSET(21725, glDeleteProgramsNV, glDeleteProgramsNV, NULL, 722),
- NAME_FUNC_OFFSET(21745, glGenProgramsNV, glGenProgramsNV, NULL, 724),
- NAME_FUNC_OFFSET(21762, glGetVertexAttribPointervNV, glGetVertexAttribPointervNV, NULL, 730),
- NAME_FUNC_OFFSET(21788, glGetVertexAttribPointervNV, glGetVertexAttribPointervNV, NULL, 730),
- NAME_FUNC_OFFSET(21817, glIsProgramNV, glIsProgramNV, NULL, 734),
- NAME_FUNC_OFFSET(21832, glPointParameteriNV, glPointParameteriNV, NULL, 798),
- NAME_FUNC_OFFSET(21850, glPointParameterivNV, glPointParameterivNV, NULL, 799),
- NAME_FUNC_OFFSET(21869, gl_dispatch_stub_802, gl_dispatch_stub_802, NULL, 802),
- NAME_FUNC_OFFSET(21890, gl_dispatch_stub_804, gl_dispatch_stub_804, NULL, 804),
- NAME_FUNC_OFFSET(21906, glPrimitiveRestartIndexNV, glPrimitiveRestartIndexNV, NULL, 811),
- NAME_FUNC_OFFSET(21930, gl_dispatch_stub_814, gl_dispatch_stub_814, NULL, 814),
- NAME_FUNC_OFFSET(21954, gl_dispatch_stub_814, gl_dispatch_stub_814, NULL, 814),
- NAME_FUNC_OFFSET(21981, glBindFramebufferEXT, glBindFramebufferEXT, NULL, 815),
- NAME_FUNC_OFFSET(21999, glBindRenderbufferEXT, glBindRenderbufferEXT, NULL, 816),
- NAME_FUNC_OFFSET(22018, glCheckFramebufferStatusEXT, glCheckFramebufferStatusEXT, NULL, 817),
- NAME_FUNC_OFFSET(22043, glDeleteFramebuffersEXT, glDeleteFramebuffersEXT, NULL, 818),
- NAME_FUNC_OFFSET(22064, glDeleteRenderbuffersEXT, glDeleteRenderbuffersEXT, NULL, 819),
- NAME_FUNC_OFFSET(22086, glFramebufferRenderbufferEXT, glFramebufferRenderbufferEXT, NULL, 820),
- NAME_FUNC_OFFSET(22112, glFramebufferTexture1DEXT, glFramebufferTexture1DEXT, NULL, 821),
- NAME_FUNC_OFFSET(22135, glFramebufferTexture2DEXT, glFramebufferTexture2DEXT, NULL, 822),
- NAME_FUNC_OFFSET(22158, glFramebufferTexture3DEXT, glFramebufferTexture3DEXT, NULL, 823),
- NAME_FUNC_OFFSET(22181, glGenFramebuffersEXT, glGenFramebuffersEXT, NULL, 824),
- NAME_FUNC_OFFSET(22199, glGenRenderbuffersEXT, glGenRenderbuffersEXT, NULL, 825),
- NAME_FUNC_OFFSET(22218, glGenerateMipmapEXT, glGenerateMipmapEXT, NULL, 826),
- NAME_FUNC_OFFSET(22235, glGetFramebufferAttachmentParameterivEXT, glGetFramebufferAttachmentParameterivEXT, NULL, 827),
- NAME_FUNC_OFFSET(22273, glGetRenderbufferParameterivEXT, glGetRenderbufferParameterivEXT, NULL, 828),
- NAME_FUNC_OFFSET(22302, glIsFramebufferEXT, glIsFramebufferEXT, NULL, 829),
- NAME_FUNC_OFFSET(22318, glIsRenderbufferEXT, glIsRenderbufferEXT, NULL, 830),
- NAME_FUNC_OFFSET(22335, glRenderbufferStorageEXT, glRenderbufferStorageEXT, NULL, 831),
- NAME_FUNC_OFFSET(22357, gl_dispatch_stub_832, gl_dispatch_stub_832, NULL, 832),
- NAME_FUNC_OFFSET(22375, glBindFragDataLocationEXT, glBindFragDataLocationEXT, NULL, 835),
- NAME_FUNC_OFFSET(22398, glGetFragDataLocationEXT, glGetFragDataLocationEXT, NULL, 836),
- NAME_FUNC_OFFSET(22420, glGetUniformuivEXT, glGetUniformuivEXT, NULL, 837),
- NAME_FUNC_OFFSET(22436, glGetVertexAttribIivEXT, glGetVertexAttribIivEXT, NULL, 838),
- NAME_FUNC_OFFSET(22457, glGetVertexAttribIuivEXT, glGetVertexAttribIuivEXT, NULL, 839),
- NAME_FUNC_OFFSET(22479, glUniform1uiEXT, glUniform1uiEXT, NULL, 840),
- NAME_FUNC_OFFSET(22492, glUniform1uivEXT, glUniform1uivEXT, NULL, 841),
- NAME_FUNC_OFFSET(22506, glUniform2uiEXT, glUniform2uiEXT, NULL, 842),
- NAME_FUNC_OFFSET(22519, glUniform2uivEXT, glUniform2uivEXT, NULL, 843),
- NAME_FUNC_OFFSET(22533, glUniform3uiEXT, glUniform3uiEXT, NULL, 844),
- NAME_FUNC_OFFSET(22546, glUniform3uivEXT, glUniform3uivEXT, NULL, 845),
- NAME_FUNC_OFFSET(22560, glUniform4uiEXT, glUniform4uiEXT, NULL, 846),
- NAME_FUNC_OFFSET(22573, glUniform4uivEXT, glUniform4uivEXT, NULL, 847),
- NAME_FUNC_OFFSET(22587, glVertexAttribI1iEXT, glVertexAttribI1iEXT, NULL, 848),
- NAME_FUNC_OFFSET(22605, glVertexAttribI1ivEXT, glVertexAttribI1ivEXT, NULL, 849),
- NAME_FUNC_OFFSET(22624, glVertexAttribI1uiEXT, glVertexAttribI1uiEXT, NULL, 850),
- NAME_FUNC_OFFSET(22643, glVertexAttribI1uivEXT, glVertexAttribI1uivEXT, NULL, 851),
- NAME_FUNC_OFFSET(22663, glVertexAttribI2iEXT, glVertexAttribI2iEXT, NULL, 852),
- NAME_FUNC_OFFSET(22681, glVertexAttribI2ivEXT, glVertexAttribI2ivEXT, NULL, 853),
- NAME_FUNC_OFFSET(22700, glVertexAttribI2uiEXT, glVertexAttribI2uiEXT, NULL, 854),
- NAME_FUNC_OFFSET(22719, glVertexAttribI2uivEXT, glVertexAttribI2uivEXT, NULL, 855),
- NAME_FUNC_OFFSET(22739, glVertexAttribI3iEXT, glVertexAttribI3iEXT, NULL, 856),
- NAME_FUNC_OFFSET(22757, glVertexAttribI3ivEXT, glVertexAttribI3ivEXT, NULL, 857),
- NAME_FUNC_OFFSET(22776, glVertexAttribI3uiEXT, glVertexAttribI3uiEXT, NULL, 858),
- NAME_FUNC_OFFSET(22795, glVertexAttribI3uivEXT, glVertexAttribI3uivEXT, NULL, 859),
- NAME_FUNC_OFFSET(22815, glVertexAttribI4bvEXT, glVertexAttribI4bvEXT, NULL, 860),
- NAME_FUNC_OFFSET(22834, glVertexAttribI4iEXT, glVertexAttribI4iEXT, NULL, 861),
- NAME_FUNC_OFFSET(22852, glVertexAttribI4ivEXT, glVertexAttribI4ivEXT, NULL, 862),
- NAME_FUNC_OFFSET(22871, glVertexAttribI4svEXT, glVertexAttribI4svEXT, NULL, 863),
- NAME_FUNC_OFFSET(22890, glVertexAttribI4ubvEXT, glVertexAttribI4ubvEXT, NULL, 864),
- NAME_FUNC_OFFSET(22910, glVertexAttribI4uiEXT, glVertexAttribI4uiEXT, NULL, 865),
- NAME_FUNC_OFFSET(22929, glVertexAttribI4uivEXT, glVertexAttribI4uivEXT, NULL, 866),
- NAME_FUNC_OFFSET(22949, glVertexAttribI4usvEXT, glVertexAttribI4usvEXT, NULL, 867),
- NAME_FUNC_OFFSET(22969, glVertexAttribIPointerEXT, glVertexAttribIPointerEXT, NULL, 868),
- NAME_FUNC_OFFSET(22992, glFramebufferTextureLayerEXT, glFramebufferTextureLayerEXT, NULL, 869),
- NAME_FUNC_OFFSET(23018, glColorMaskIndexedEXT, glColorMaskIndexedEXT, NULL, 870),
- NAME_FUNC_OFFSET(23031, glDisableIndexedEXT, glDisableIndexedEXT, NULL, 871),
- NAME_FUNC_OFFSET(23042, glEnableIndexedEXT, glEnableIndexedEXT, NULL, 872),
- NAME_FUNC_OFFSET(23052, glGetBooleanIndexedvEXT, glGetBooleanIndexedvEXT, NULL, 873),
- NAME_FUNC_OFFSET(23068, glGetIntegerIndexedvEXT, glGetIntegerIndexedvEXT, NULL, 874),
- NAME_FUNC_OFFSET(23084, glIsEnabledIndexedEXT, glIsEnabledIndexedEXT, NULL, 875),
- NAME_FUNC_OFFSET(23097, glGetTexParameterIivEXT, glGetTexParameterIivEXT, NULL, 878),
- NAME_FUNC_OFFSET(23118, glGetTexParameterIuivEXT, glGetTexParameterIuivEXT, NULL, 879),
- NAME_FUNC_OFFSET(23140, glTexParameterIivEXT, glTexParameterIivEXT, NULL, 880),
- NAME_FUNC_OFFSET(23158, glTexParameterIuivEXT, glTexParameterIuivEXT, NULL, 881),
- NAME_FUNC_OFFSET(23177, glBeginConditionalRenderNV, glBeginConditionalRenderNV, NULL, 882),
- NAME_FUNC_OFFSET(23202, glEndConditionalRenderNV, glEndConditionalRenderNV, NULL, 883),
- NAME_FUNC_OFFSET(23225, glBeginTransformFeedbackEXT, glBeginTransformFeedbackEXT, NULL, 884),
- NAME_FUNC_OFFSET(23250, glBindBufferBaseEXT, glBindBufferBaseEXT, NULL, 885),
- NAME_FUNC_OFFSET(23267, glBindBufferRangeEXT, glBindBufferRangeEXT, NULL, 887),
- NAME_FUNC_OFFSET(23285, glEndTransformFeedbackEXT, glEndTransformFeedbackEXT, NULL, 888),
- NAME_FUNC_OFFSET(23308, glGetTransformFeedbackVaryingEXT, glGetTransformFeedbackVaryingEXT, NULL, 889),
- NAME_FUNC_OFFSET(23338, glTransformFeedbackVaryingsEXT, glTransformFeedbackVaryingsEXT, NULL, 890),
- NAME_FUNC_OFFSET(23366, glProvokingVertexEXT, glProvokingVertexEXT, NULL, 891),
+ NAME_FUNC_OFFSET(10266, glGetGraphicsResetStatusARB, glGetGraphicsResetStatusARB, NULL, 626),
+ NAME_FUNC_OFFSET(10294, glGetnColorTableARB, glGetnColorTableARB, NULL, 627),
+ NAME_FUNC_OFFSET(10314, glGetnCompressedTexImageARB, glGetnCompressedTexImageARB, NULL, 628),
+ NAME_FUNC_OFFSET(10342, glGetnConvolutionFilterARB, glGetnConvolutionFilterARB, NULL, 629),
+ NAME_FUNC_OFFSET(10369, glGetnHistogramARB, glGetnHistogramARB, NULL, 630),
+ NAME_FUNC_OFFSET(10388, glGetnMapdvARB, glGetnMapdvARB, NULL, 631),
+ NAME_FUNC_OFFSET(10403, glGetnMapfvARB, glGetnMapfvARB, NULL, 632),
+ NAME_FUNC_OFFSET(10418, glGetnMapivARB, glGetnMapivARB, NULL, 633),
+ NAME_FUNC_OFFSET(10433, glGetnMinmaxARB, glGetnMinmaxARB, NULL, 634),
+ NAME_FUNC_OFFSET(10449, glGetnPixelMapfvARB, glGetnPixelMapfvARB, NULL, 635),
+ NAME_FUNC_OFFSET(10469, glGetnPixelMapuivARB, glGetnPixelMapuivARB, NULL, 636),
+ NAME_FUNC_OFFSET(10490, glGetnPixelMapusvARB, glGetnPixelMapusvARB, NULL, 637),
+ NAME_FUNC_OFFSET(10511, glGetnPolygonStippleARB, glGetnPolygonStippleARB, NULL, 638),
+ NAME_FUNC_OFFSET(10535, glGetnSeparableFilterARB, glGetnSeparableFilterARB, NULL, 639),
+ NAME_FUNC_OFFSET(10560, glGetnTexImageARB, glGetnTexImageARB, NULL, 640),
+ NAME_FUNC_OFFSET(10578, glGetnUniformdvARB, glGetnUniformdvARB, NULL, 641),
+ NAME_FUNC_OFFSET(10597, glGetnUniformfvARB, glGetnUniformfvARB, NULL, 642),
+ NAME_FUNC_OFFSET(10616, glGetnUniformivARB, glGetnUniformivARB, NULL, 643),
+ NAME_FUNC_OFFSET(10635, glGetnUniformuivARB, glGetnUniformuivARB, NULL, 644),
+ NAME_FUNC_OFFSET(10655, glReadnPixelsARB, glReadnPixelsARB, NULL, 645),
+ NAME_FUNC_OFFSET(10672, glPolygonOffsetEXT, glPolygonOffsetEXT, NULL, 646),
+ NAME_FUNC_OFFSET(10691, gl_dispatch_stub_647, gl_dispatch_stub_647, NULL, 647),
+ NAME_FUNC_OFFSET(10723, gl_dispatch_stub_648, gl_dispatch_stub_648, NULL, 648),
+ NAME_FUNC_OFFSET(10755, gl_dispatch_stub_649, gl_dispatch_stub_649, NULL, 649),
+ NAME_FUNC_OFFSET(10783, gl_dispatch_stub_650, gl_dispatch_stub_650, NULL, 650),
+ NAME_FUNC_OFFSET(10812, gl_dispatch_stub_651, gl_dispatch_stub_651, NULL, 651),
+ NAME_FUNC_OFFSET(10840, gl_dispatch_stub_652, gl_dispatch_stub_652, NULL, 652),
+ NAME_FUNC_OFFSET(10869, gl_dispatch_stub_653, gl_dispatch_stub_653, NULL, 653),
+ NAME_FUNC_OFFSET(10886, gl_dispatch_stub_654, gl_dispatch_stub_654, NULL, 654),
+ NAME_FUNC_OFFSET(10906, glColorPointerEXT, glColorPointerEXT, NULL, 655),
+ NAME_FUNC_OFFSET(10924, glEdgeFlagPointerEXT, glEdgeFlagPointerEXT, NULL, 656),
+ NAME_FUNC_OFFSET(10945, glIndexPointerEXT, glIndexPointerEXT, NULL, 657),
+ NAME_FUNC_OFFSET(10963, glNormalPointerEXT, glNormalPointerEXT, NULL, 658),
+ NAME_FUNC_OFFSET(10982, glTexCoordPointerEXT, glTexCoordPointerEXT, NULL, 659),
+ NAME_FUNC_OFFSET(11003, glVertexPointerEXT, glVertexPointerEXT, NULL, 660),
+ NAME_FUNC_OFFSET(11022, glPointParameterfEXT, glPointParameterfEXT, NULL, 661),
+ NAME_FUNC_OFFSET(11043, glPointParameterfvEXT, glPointParameterfvEXT, NULL, 662),
+ NAME_FUNC_OFFSET(11065, glLockArraysEXT, glLockArraysEXT, NULL, 663),
+ NAME_FUNC_OFFSET(11081, glUnlockArraysEXT, glUnlockArraysEXT, NULL, 664),
+ NAME_FUNC_OFFSET(11099, glSecondaryColor3bEXT, glSecondaryColor3bEXT, NULL, 665),
+ NAME_FUNC_OFFSET(11121, glSecondaryColor3bvEXT, glSecondaryColor3bvEXT, NULL, 666),
+ NAME_FUNC_OFFSET(11144, glSecondaryColor3dEXT, glSecondaryColor3dEXT, NULL, 667),
+ NAME_FUNC_OFFSET(11166, glSecondaryColor3dvEXT, glSecondaryColor3dvEXT, NULL, 668),
+ NAME_FUNC_OFFSET(11189, glSecondaryColor3fEXT, glSecondaryColor3fEXT, NULL, 669),
+ NAME_FUNC_OFFSET(11211, glSecondaryColor3fvEXT, glSecondaryColor3fvEXT, NULL, 670),
+ NAME_FUNC_OFFSET(11234, glSecondaryColor3iEXT, glSecondaryColor3iEXT, NULL, 671),
+ NAME_FUNC_OFFSET(11256, glSecondaryColor3ivEXT, glSecondaryColor3ivEXT, NULL, 672),
+ NAME_FUNC_OFFSET(11279, glSecondaryColor3sEXT, glSecondaryColor3sEXT, NULL, 673),
+ NAME_FUNC_OFFSET(11301, glSecondaryColor3svEXT, glSecondaryColor3svEXT, NULL, 674),
+ NAME_FUNC_OFFSET(11324, glSecondaryColor3ubEXT, glSecondaryColor3ubEXT, NULL, 675),
+ NAME_FUNC_OFFSET(11347, glSecondaryColor3ubvEXT, glSecondaryColor3ubvEXT, NULL, 676),
+ NAME_FUNC_OFFSET(11371, glSecondaryColor3uiEXT, glSecondaryColor3uiEXT, NULL, 677),
+ NAME_FUNC_OFFSET(11394, glSecondaryColor3uivEXT, glSecondaryColor3uivEXT, NULL, 678),
+ NAME_FUNC_OFFSET(11418, glSecondaryColor3usEXT, glSecondaryColor3usEXT, NULL, 679),
+ NAME_FUNC_OFFSET(11441, glSecondaryColor3usvEXT, glSecondaryColor3usvEXT, NULL, 680),
+ NAME_FUNC_OFFSET(11465, glSecondaryColorPointerEXT, glSecondaryColorPointerEXT, NULL, 681),
+ NAME_FUNC_OFFSET(11492, glMultiDrawArraysEXT, glMultiDrawArraysEXT, NULL, 682),
+ NAME_FUNC_OFFSET(11513, glMultiDrawElementsEXT, glMultiDrawElementsEXT, NULL, 683),
+ NAME_FUNC_OFFSET(11536, glFogCoordPointerEXT, glFogCoordPointerEXT, NULL, 684),
+ NAME_FUNC_OFFSET(11557, glFogCoorddEXT, glFogCoorddEXT, NULL, 685),
+ NAME_FUNC_OFFSET(11572, glFogCoorddvEXT, glFogCoorddvEXT, NULL, 686),
+ NAME_FUNC_OFFSET(11588, glFogCoordfEXT, glFogCoordfEXT, NULL, 687),
+ NAME_FUNC_OFFSET(11603, glFogCoordfvEXT, glFogCoordfvEXT, NULL, 688),
+ NAME_FUNC_OFFSET(11619, gl_dispatch_stub_689, gl_dispatch_stub_689, NULL, 689),
+ NAME_FUNC_OFFSET(11637, glBlendFuncSeparateEXT, glBlendFuncSeparateEXT, NULL, 690),
+ NAME_FUNC_OFFSET(11660, glFlushVertexArrayRangeNV, glFlushVertexArrayRangeNV, NULL, 691),
+ NAME_FUNC_OFFSET(11686, glVertexArrayRangeNV, glVertexArrayRangeNV, NULL, 692),
+ NAME_FUNC_OFFSET(11707, glCombinerInputNV, glCombinerInputNV, NULL, 693),
+ NAME_FUNC_OFFSET(11725, glCombinerOutputNV, glCombinerOutputNV, NULL, 694),
+ NAME_FUNC_OFFSET(11744, glCombinerParameterfNV, glCombinerParameterfNV, NULL, 695),
+ NAME_FUNC_OFFSET(11767, glCombinerParameterfvNV, glCombinerParameterfvNV, NULL, 696),
+ NAME_FUNC_OFFSET(11791, glCombinerParameteriNV, glCombinerParameteriNV, NULL, 697),
+ NAME_FUNC_OFFSET(11814, glCombinerParameterivNV, glCombinerParameterivNV, NULL, 698),
+ NAME_FUNC_OFFSET(11838, glFinalCombinerInputNV, glFinalCombinerInputNV, NULL, 699),
+ NAME_FUNC_OFFSET(11861, glGetCombinerInputParameterfvNV, glGetCombinerInputParameterfvNV, NULL, 700),
+ NAME_FUNC_OFFSET(11893, glGetCombinerInputParameterivNV, glGetCombinerInputParameterivNV, NULL, 701),
+ NAME_FUNC_OFFSET(11925, glGetCombinerOutputParameterfvNV, glGetCombinerOutputParameterfvNV, NULL, 702),
+ NAME_FUNC_OFFSET(11958, glGetCombinerOutputParameterivNV, glGetCombinerOutputParameterivNV, NULL, 703),
+ NAME_FUNC_OFFSET(11991, glGetFinalCombinerInputParameterfvNV, glGetFinalCombinerInputParameterfvNV, NULL, 704),
+ NAME_FUNC_OFFSET(12028, glGetFinalCombinerInputParameterivNV, glGetFinalCombinerInputParameterivNV, NULL, 705),
+ NAME_FUNC_OFFSET(12065, glResizeBuffersMESA, glResizeBuffersMESA, NULL, 706),
+ NAME_FUNC_OFFSET(12085, glWindowPos2dMESA, glWindowPos2dMESA, NULL, 707),
+ NAME_FUNC_OFFSET(12103, glWindowPos2dvMESA, glWindowPos2dvMESA, NULL, 708),
+ NAME_FUNC_OFFSET(12122, glWindowPos2fMESA, glWindowPos2fMESA, NULL, 709),
+ NAME_FUNC_OFFSET(12140, glWindowPos2fvMESA, glWindowPos2fvMESA, NULL, 710),
+ NAME_FUNC_OFFSET(12159, glWindowPos2iMESA, glWindowPos2iMESA, NULL, 711),
+ NAME_FUNC_OFFSET(12177, glWindowPos2ivMESA, glWindowPos2ivMESA, NULL, 712),
+ NAME_FUNC_OFFSET(12196, glWindowPos2sMESA, glWindowPos2sMESA, NULL, 713),
+ NAME_FUNC_OFFSET(12214, glWindowPos2svMESA, glWindowPos2svMESA, NULL, 714),
+ NAME_FUNC_OFFSET(12233, glWindowPos3dMESA, glWindowPos3dMESA, NULL, 715),
+ NAME_FUNC_OFFSET(12251, glWindowPos3dvMESA, glWindowPos3dvMESA, NULL, 716),
+ NAME_FUNC_OFFSET(12270, glWindowPos3fMESA, glWindowPos3fMESA, NULL, 717),
+ NAME_FUNC_OFFSET(12288, glWindowPos3fvMESA, glWindowPos3fvMESA, NULL, 718),
+ NAME_FUNC_OFFSET(12307, glWindowPos3iMESA, glWindowPos3iMESA, NULL, 719),
+ NAME_FUNC_OFFSET(12325, glWindowPos3ivMESA, glWindowPos3ivMESA, NULL, 720),
+ NAME_FUNC_OFFSET(12344, glWindowPos3sMESA, glWindowPos3sMESA, NULL, 721),
+ NAME_FUNC_OFFSET(12362, glWindowPos3svMESA, glWindowPos3svMESA, NULL, 722),
+ NAME_FUNC_OFFSET(12381, glWindowPos4dMESA, glWindowPos4dMESA, NULL, 723),
+ NAME_FUNC_OFFSET(12399, glWindowPos4dvMESA, glWindowPos4dvMESA, NULL, 724),
+ NAME_FUNC_OFFSET(12418, glWindowPos4fMESA, glWindowPos4fMESA, NULL, 725),
+ NAME_FUNC_OFFSET(12436, glWindowPos4fvMESA, glWindowPos4fvMESA, NULL, 726),
+ NAME_FUNC_OFFSET(12455, glWindowPos4iMESA, glWindowPos4iMESA, NULL, 727),
+ NAME_FUNC_OFFSET(12473, glWindowPos4ivMESA, glWindowPos4ivMESA, NULL, 728),
+ NAME_FUNC_OFFSET(12492, glWindowPos4sMESA, glWindowPos4sMESA, NULL, 729),
+ NAME_FUNC_OFFSET(12510, glWindowPos4svMESA, glWindowPos4svMESA, NULL, 730),
+ NAME_FUNC_OFFSET(12529, gl_dispatch_stub_731, gl_dispatch_stub_731, NULL, 731),
+ NAME_FUNC_OFFSET(12554, gl_dispatch_stub_732, gl_dispatch_stub_732, NULL, 732),
+ NAME_FUNC_OFFSET(12581, gl_dispatch_stub_733, gl_dispatch_stub_733, NULL, 733),
+ NAME_FUNC_OFFSET(12598, gl_dispatch_stub_734, gl_dispatch_stub_734, NULL, 734),
+ NAME_FUNC_OFFSET(12614, gl_dispatch_stub_735, gl_dispatch_stub_735, NULL, 735),
+ NAME_FUNC_OFFSET(12628, gl_dispatch_stub_736, gl_dispatch_stub_736, NULL, 736),
+ NAME_FUNC_OFFSET(12643, gl_dispatch_stub_737, gl_dispatch_stub_737, NULL, 737),
+ NAME_FUNC_OFFSET(12655, gl_dispatch_stub_738, gl_dispatch_stub_738, NULL, 738),
+ NAME_FUNC_OFFSET(12668, gl_dispatch_stub_739, gl_dispatch_stub_739, NULL, 739),
+ NAME_FUNC_OFFSET(12682, glAreProgramsResidentNV, glAreProgramsResidentNV, NULL, 740),
+ NAME_FUNC_OFFSET(12706, glBindProgramNV, glBindProgramNV, NULL, 741),
+ NAME_FUNC_OFFSET(12722, glDeleteProgramsNV, glDeleteProgramsNV, NULL, 742),
+ NAME_FUNC_OFFSET(12741, glExecuteProgramNV, glExecuteProgramNV, NULL, 743),
+ NAME_FUNC_OFFSET(12760, glGenProgramsNV, glGenProgramsNV, NULL, 744),
+ NAME_FUNC_OFFSET(12776, glGetProgramParameterdvNV, glGetProgramParameterdvNV, NULL, 745),
+ NAME_FUNC_OFFSET(12802, glGetProgramParameterfvNV, glGetProgramParameterfvNV, NULL, 746),
+ NAME_FUNC_OFFSET(12828, glGetProgramStringNV, glGetProgramStringNV, NULL, 747),
+ NAME_FUNC_OFFSET(12849, glGetProgramivNV, glGetProgramivNV, NULL, 748),
+ NAME_FUNC_OFFSET(12866, glGetTrackMatrixivNV, glGetTrackMatrixivNV, NULL, 749),
+ NAME_FUNC_OFFSET(12887, glGetVertexAttribPointervNV, glGetVertexAttribPointervNV, NULL, 750),
+ NAME_FUNC_OFFSET(12915, glGetVertexAttribdvNV, glGetVertexAttribdvNV, NULL, 751),
+ NAME_FUNC_OFFSET(12937, glGetVertexAttribfvNV, glGetVertexAttribfvNV, NULL, 752),
+ NAME_FUNC_OFFSET(12959, glGetVertexAttribivNV, glGetVertexAttribivNV, NULL, 753),
+ NAME_FUNC_OFFSET(12981, glIsProgramNV, glIsProgramNV, NULL, 754),
+ NAME_FUNC_OFFSET(12995, glLoadProgramNV, glLoadProgramNV, NULL, 755),
+ NAME_FUNC_OFFSET(13011, glProgramParameters4dvNV, glProgramParameters4dvNV, NULL, 756),
+ NAME_FUNC_OFFSET(13036, glProgramParameters4fvNV, glProgramParameters4fvNV, NULL, 757),
+ NAME_FUNC_OFFSET(13061, glRequestResidentProgramsNV, glRequestResidentProgramsNV, NULL, 758),
+ NAME_FUNC_OFFSET(13089, glTrackMatrixNV, glTrackMatrixNV, NULL, 759),
+ NAME_FUNC_OFFSET(13105, glVertexAttrib1dNV, glVertexAttrib1dNV, NULL, 760),
+ NAME_FUNC_OFFSET(13124, glVertexAttrib1dvNV, glVertexAttrib1dvNV, NULL, 761),
+ NAME_FUNC_OFFSET(13144, glVertexAttrib1fNV, glVertexAttrib1fNV, NULL, 762),
+ NAME_FUNC_OFFSET(13163, glVertexAttrib1fvNV, glVertexAttrib1fvNV, NULL, 763),
+ NAME_FUNC_OFFSET(13183, glVertexAttrib1sNV, glVertexAttrib1sNV, NULL, 764),
+ NAME_FUNC_OFFSET(13202, glVertexAttrib1svNV, glVertexAttrib1svNV, NULL, 765),
+ NAME_FUNC_OFFSET(13222, glVertexAttrib2dNV, glVertexAttrib2dNV, NULL, 766),
+ NAME_FUNC_OFFSET(13241, glVertexAttrib2dvNV, glVertexAttrib2dvNV, NULL, 767),
+ NAME_FUNC_OFFSET(13261, glVertexAttrib2fNV, glVertexAttrib2fNV, NULL, 768),
+ NAME_FUNC_OFFSET(13280, glVertexAttrib2fvNV, glVertexAttrib2fvNV, NULL, 769),
+ NAME_FUNC_OFFSET(13300, glVertexAttrib2sNV, glVertexAttrib2sNV, NULL, 770),
+ NAME_FUNC_OFFSET(13319, glVertexAttrib2svNV, glVertexAttrib2svNV, NULL, 771),
+ NAME_FUNC_OFFSET(13339, glVertexAttrib3dNV, glVertexAttrib3dNV, NULL, 772),
+ NAME_FUNC_OFFSET(13358, glVertexAttrib3dvNV, glVertexAttrib3dvNV, NULL, 773),
+ NAME_FUNC_OFFSET(13378, glVertexAttrib3fNV, glVertexAttrib3fNV, NULL, 774),
+ NAME_FUNC_OFFSET(13397, glVertexAttrib3fvNV, glVertexAttrib3fvNV, NULL, 775),
+ NAME_FUNC_OFFSET(13417, glVertexAttrib3sNV, glVertexAttrib3sNV, NULL, 776),
+ NAME_FUNC_OFFSET(13436, glVertexAttrib3svNV, glVertexAttrib3svNV, NULL, 777),
+ NAME_FUNC_OFFSET(13456, glVertexAttrib4dNV, glVertexAttrib4dNV, NULL, 778),
+ NAME_FUNC_OFFSET(13475, glVertexAttrib4dvNV, glVertexAttrib4dvNV, NULL, 779),
+ NAME_FUNC_OFFSET(13495, glVertexAttrib4fNV, glVertexAttrib4fNV, NULL, 780),
+ NAME_FUNC_OFFSET(13514, glVertexAttrib4fvNV, glVertexAttrib4fvNV, NULL, 781),
+ NAME_FUNC_OFFSET(13534, glVertexAttrib4sNV, glVertexAttrib4sNV, NULL, 782),
+ NAME_FUNC_OFFSET(13553, glVertexAttrib4svNV, glVertexAttrib4svNV, NULL, 783),
+ NAME_FUNC_OFFSET(13573, glVertexAttrib4ubNV, glVertexAttrib4ubNV, NULL, 784),
+ NAME_FUNC_OFFSET(13593, glVertexAttrib4ubvNV, glVertexAttrib4ubvNV, NULL, 785),
+ NAME_FUNC_OFFSET(13614, glVertexAttribPointerNV, glVertexAttribPointerNV, NULL, 786),
+ NAME_FUNC_OFFSET(13638, glVertexAttribs1dvNV, glVertexAttribs1dvNV, NULL, 787),
+ NAME_FUNC_OFFSET(13659, glVertexAttribs1fvNV, glVertexAttribs1fvNV, NULL, 788),
+ NAME_FUNC_OFFSET(13680, glVertexAttribs1svNV, glVertexAttribs1svNV, NULL, 789),
+ NAME_FUNC_OFFSET(13701, glVertexAttribs2dvNV, glVertexAttribs2dvNV, NULL, 790),
+ NAME_FUNC_OFFSET(13722, glVertexAttribs2fvNV, glVertexAttribs2fvNV, NULL, 791),
+ NAME_FUNC_OFFSET(13743, glVertexAttribs2svNV, glVertexAttribs2svNV, NULL, 792),
+ NAME_FUNC_OFFSET(13764, glVertexAttribs3dvNV, glVertexAttribs3dvNV, NULL, 793),
+ NAME_FUNC_OFFSET(13785, glVertexAttribs3fvNV, glVertexAttribs3fvNV, NULL, 794),
+ NAME_FUNC_OFFSET(13806, glVertexAttribs3svNV, glVertexAttribs3svNV, NULL, 795),
+ NAME_FUNC_OFFSET(13827, glVertexAttribs4dvNV, glVertexAttribs4dvNV, NULL, 796),
+ NAME_FUNC_OFFSET(13848, glVertexAttribs4fvNV, glVertexAttribs4fvNV, NULL, 797),
+ NAME_FUNC_OFFSET(13869, glVertexAttribs4svNV, glVertexAttribs4svNV, NULL, 798),
+ NAME_FUNC_OFFSET(13890, glVertexAttribs4ubvNV, glVertexAttribs4ubvNV, NULL, 799),
+ NAME_FUNC_OFFSET(13912, glGetTexBumpParameterfvATI, glGetTexBumpParameterfvATI, NULL, 800),
+ NAME_FUNC_OFFSET(13939, glGetTexBumpParameterivATI, glGetTexBumpParameterivATI, NULL, 801),
+ NAME_FUNC_OFFSET(13966, glTexBumpParameterfvATI, glTexBumpParameterfvATI, NULL, 802),
+ NAME_FUNC_OFFSET(13990, glTexBumpParameterivATI, glTexBumpParameterivATI, NULL, 803),
+ NAME_FUNC_OFFSET(14014, glAlphaFragmentOp1ATI, glAlphaFragmentOp1ATI, NULL, 804),
+ NAME_FUNC_OFFSET(14036, glAlphaFragmentOp2ATI, glAlphaFragmentOp2ATI, NULL, 805),
+ NAME_FUNC_OFFSET(14058, glAlphaFragmentOp3ATI, glAlphaFragmentOp3ATI, NULL, 806),
+ NAME_FUNC_OFFSET(14080, glBeginFragmentShaderATI, glBeginFragmentShaderATI, NULL, 807),
+ NAME_FUNC_OFFSET(14105, glBindFragmentShaderATI, glBindFragmentShaderATI, NULL, 808),
+ NAME_FUNC_OFFSET(14129, glColorFragmentOp1ATI, glColorFragmentOp1ATI, NULL, 809),
+ NAME_FUNC_OFFSET(14151, glColorFragmentOp2ATI, glColorFragmentOp2ATI, NULL, 810),
+ NAME_FUNC_OFFSET(14173, glColorFragmentOp3ATI, glColorFragmentOp3ATI, NULL, 811),
+ NAME_FUNC_OFFSET(14195, glDeleteFragmentShaderATI, glDeleteFragmentShaderATI, NULL, 812),
+ NAME_FUNC_OFFSET(14221, glEndFragmentShaderATI, glEndFragmentShaderATI, NULL, 813),
+ NAME_FUNC_OFFSET(14244, glGenFragmentShadersATI, glGenFragmentShadersATI, NULL, 814),
+ NAME_FUNC_OFFSET(14268, glPassTexCoordATI, glPassTexCoordATI, NULL, 815),
+ NAME_FUNC_OFFSET(14286, glSampleMapATI, glSampleMapATI, NULL, 816),
+ NAME_FUNC_OFFSET(14301, glSetFragmentShaderConstantATI, glSetFragmentShaderConstantATI, NULL, 817),
+ NAME_FUNC_OFFSET(14332, glPointParameteriNV, glPointParameteriNV, NULL, 818),
+ NAME_FUNC_OFFSET(14352, glPointParameterivNV, glPointParameterivNV, NULL, 819),
+ NAME_FUNC_OFFSET(14373, gl_dispatch_stub_820, gl_dispatch_stub_820, NULL, 820),
+ NAME_FUNC_OFFSET(14396, gl_dispatch_stub_821, gl_dispatch_stub_821, NULL, 821),
+ NAME_FUNC_OFFSET(14419, gl_dispatch_stub_822, gl_dispatch_stub_822, NULL, 822),
+ NAME_FUNC_OFFSET(14445, gl_dispatch_stub_823, gl_dispatch_stub_823, NULL, 823),
+ NAME_FUNC_OFFSET(14468, gl_dispatch_stub_824, gl_dispatch_stub_824, NULL, 824),
+ NAME_FUNC_OFFSET(14489, glGetProgramNamedParameterdvNV, glGetProgramNamedParameterdvNV, NULL, 825),
+ NAME_FUNC_OFFSET(14520, glGetProgramNamedParameterfvNV, glGetProgramNamedParameterfvNV, NULL, 826),
+ NAME_FUNC_OFFSET(14551, glProgramNamedParameter4dNV, glProgramNamedParameter4dNV, NULL, 827),
+ NAME_FUNC_OFFSET(14579, glProgramNamedParameter4dvNV, glProgramNamedParameter4dvNV, NULL, 828),
+ NAME_FUNC_OFFSET(14608, glProgramNamedParameter4fNV, glProgramNamedParameter4fNV, NULL, 829),
+ NAME_FUNC_OFFSET(14636, glProgramNamedParameter4fvNV, glProgramNamedParameter4fvNV, NULL, 830),
+ NAME_FUNC_OFFSET(14665, glPrimitiveRestartIndexNV, glPrimitiveRestartIndexNV, NULL, 831),
+ NAME_FUNC_OFFSET(14691, glPrimitiveRestartNV, glPrimitiveRestartNV, NULL, 832),
+ NAME_FUNC_OFFSET(14712, gl_dispatch_stub_833, gl_dispatch_stub_833, NULL, 833),
+ NAME_FUNC_OFFSET(14729, gl_dispatch_stub_834, gl_dispatch_stub_834, NULL, 834),
+ NAME_FUNC_OFFSET(14756, glBindFramebufferEXT, glBindFramebufferEXT, NULL, 835),
+ NAME_FUNC_OFFSET(14777, glBindRenderbufferEXT, glBindRenderbufferEXT, NULL, 836),
+ NAME_FUNC_OFFSET(14799, glCheckFramebufferStatusEXT, glCheckFramebufferStatusEXT, NULL, 837),
+ NAME_FUNC_OFFSET(14827, glDeleteFramebuffersEXT, glDeleteFramebuffersEXT, NULL, 838),
+ NAME_FUNC_OFFSET(14851, glDeleteRenderbuffersEXT, glDeleteRenderbuffersEXT, NULL, 839),
+ NAME_FUNC_OFFSET(14876, glFramebufferRenderbufferEXT, glFramebufferRenderbufferEXT, NULL, 840),
+ NAME_FUNC_OFFSET(14905, glFramebufferTexture1DEXT, glFramebufferTexture1DEXT, NULL, 841),
+ NAME_FUNC_OFFSET(14931, glFramebufferTexture2DEXT, glFramebufferTexture2DEXT, NULL, 842),
+ NAME_FUNC_OFFSET(14957, glFramebufferTexture3DEXT, glFramebufferTexture3DEXT, NULL, 843),
+ NAME_FUNC_OFFSET(14983, glGenFramebuffersEXT, glGenFramebuffersEXT, NULL, 844),
+ NAME_FUNC_OFFSET(15004, glGenRenderbuffersEXT, glGenRenderbuffersEXT, NULL, 845),
+ NAME_FUNC_OFFSET(15026, glGenerateMipmapEXT, glGenerateMipmapEXT, NULL, 846),
+ NAME_FUNC_OFFSET(15046, glGetFramebufferAttachmentParameterivEXT, glGetFramebufferAttachmentParameterivEXT, NULL, 847),
+ NAME_FUNC_OFFSET(15087, glGetRenderbufferParameterivEXT, glGetRenderbufferParameterivEXT, NULL, 848),
+ NAME_FUNC_OFFSET(15119, glIsFramebufferEXT, glIsFramebufferEXT, NULL, 849),
+ NAME_FUNC_OFFSET(15138, glIsRenderbufferEXT, glIsRenderbufferEXT, NULL, 850),
+ NAME_FUNC_OFFSET(15158, glRenderbufferStorageEXT, glRenderbufferStorageEXT, NULL, 851),
+ NAME_FUNC_OFFSET(15183, gl_dispatch_stub_852, gl_dispatch_stub_852, NULL, 852),
+ NAME_FUNC_OFFSET(15204, gl_dispatch_stub_853, gl_dispatch_stub_853, NULL, 853),
+ NAME_FUNC_OFFSET(15228, gl_dispatch_stub_854, gl_dispatch_stub_854, NULL, 854),
+ NAME_FUNC_OFFSET(15258, glBindFragDataLocationEXT, glBindFragDataLocationEXT, NULL, 855),
+ NAME_FUNC_OFFSET(15284, glGetFragDataLocationEXT, glGetFragDataLocationEXT, NULL, 856),
+ NAME_FUNC_OFFSET(15309, glGetUniformuivEXT, glGetUniformuivEXT, NULL, 857),
+ NAME_FUNC_OFFSET(15328, glGetVertexAttribIivEXT, glGetVertexAttribIivEXT, NULL, 858),
+ NAME_FUNC_OFFSET(15352, glGetVertexAttribIuivEXT, glGetVertexAttribIuivEXT, NULL, 859),
+ NAME_FUNC_OFFSET(15377, glUniform1uiEXT, glUniform1uiEXT, NULL, 860),
+ NAME_FUNC_OFFSET(15393, glUniform1uivEXT, glUniform1uivEXT, NULL, 861),
+ NAME_FUNC_OFFSET(15410, glUniform2uiEXT, glUniform2uiEXT, NULL, 862),
+ NAME_FUNC_OFFSET(15426, glUniform2uivEXT, glUniform2uivEXT, NULL, 863),
+ NAME_FUNC_OFFSET(15443, glUniform3uiEXT, glUniform3uiEXT, NULL, 864),
+ NAME_FUNC_OFFSET(15459, glUniform3uivEXT, glUniform3uivEXT, NULL, 865),
+ NAME_FUNC_OFFSET(15476, glUniform4uiEXT, glUniform4uiEXT, NULL, 866),
+ NAME_FUNC_OFFSET(15492, glUniform4uivEXT, glUniform4uivEXT, NULL, 867),
+ NAME_FUNC_OFFSET(15509, glVertexAttribI1iEXT, glVertexAttribI1iEXT, NULL, 868),
+ NAME_FUNC_OFFSET(15530, glVertexAttribI1ivEXT, glVertexAttribI1ivEXT, NULL, 869),
+ NAME_FUNC_OFFSET(15552, glVertexAttribI1uiEXT, glVertexAttribI1uiEXT, NULL, 870),
+ NAME_FUNC_OFFSET(15574, glVertexAttribI1uivEXT, glVertexAttribI1uivEXT, NULL, 871),
+ NAME_FUNC_OFFSET(15597, glVertexAttribI2iEXT, glVertexAttribI2iEXT, NULL, 872),
+ NAME_FUNC_OFFSET(15618, glVertexAttribI2ivEXT, glVertexAttribI2ivEXT, NULL, 873),
+ NAME_FUNC_OFFSET(15640, glVertexAttribI2uiEXT, glVertexAttribI2uiEXT, NULL, 874),
+ NAME_FUNC_OFFSET(15662, glVertexAttribI2uivEXT, glVertexAttribI2uivEXT, NULL, 875),
+ NAME_FUNC_OFFSET(15685, glVertexAttribI3iEXT, glVertexAttribI3iEXT, NULL, 876),
+ NAME_FUNC_OFFSET(15706, glVertexAttribI3ivEXT, glVertexAttribI3ivEXT, NULL, 877),
+ NAME_FUNC_OFFSET(15728, glVertexAttribI3uiEXT, glVertexAttribI3uiEXT, NULL, 878),
+ NAME_FUNC_OFFSET(15750, glVertexAttribI3uivEXT, glVertexAttribI3uivEXT, NULL, 879),
+ NAME_FUNC_OFFSET(15773, glVertexAttribI4bvEXT, glVertexAttribI4bvEXT, NULL, 880),
+ NAME_FUNC_OFFSET(15795, glVertexAttribI4iEXT, glVertexAttribI4iEXT, NULL, 881),
+ NAME_FUNC_OFFSET(15816, glVertexAttribI4ivEXT, glVertexAttribI4ivEXT, NULL, 882),
+ NAME_FUNC_OFFSET(15838, glVertexAttribI4svEXT, glVertexAttribI4svEXT, NULL, 883),
+ NAME_FUNC_OFFSET(15860, glVertexAttribI4ubvEXT, glVertexAttribI4ubvEXT, NULL, 884),
+ NAME_FUNC_OFFSET(15883, glVertexAttribI4uiEXT, glVertexAttribI4uiEXT, NULL, 885),
+ NAME_FUNC_OFFSET(15905, glVertexAttribI4uivEXT, glVertexAttribI4uivEXT, NULL, 886),
+ NAME_FUNC_OFFSET(15928, glVertexAttribI4usvEXT, glVertexAttribI4usvEXT, NULL, 887),
+ NAME_FUNC_OFFSET(15951, glVertexAttribIPointerEXT, glVertexAttribIPointerEXT, NULL, 888),
+ NAME_FUNC_OFFSET(15977, glFramebufferTextureLayerEXT, glFramebufferTextureLayerEXT, NULL, 889),
+ NAME_FUNC_OFFSET(16006, glColorMaskIndexedEXT, glColorMaskIndexedEXT, NULL, 890),
+ NAME_FUNC_OFFSET(16028, glDisableIndexedEXT, glDisableIndexedEXT, NULL, 891),
+ NAME_FUNC_OFFSET(16048, glEnableIndexedEXT, glEnableIndexedEXT, NULL, 892),
+ NAME_FUNC_OFFSET(16067, glGetBooleanIndexedvEXT, glGetBooleanIndexedvEXT, NULL, 893),
+ NAME_FUNC_OFFSET(16091, glGetIntegerIndexedvEXT, glGetIntegerIndexedvEXT, NULL, 894),
+ NAME_FUNC_OFFSET(16115, glIsEnabledIndexedEXT, glIsEnabledIndexedEXT, NULL, 895),
+ NAME_FUNC_OFFSET(16137, glClearColorIiEXT, glClearColorIiEXT, NULL, 896),
+ NAME_FUNC_OFFSET(16155, glClearColorIuiEXT, glClearColorIuiEXT, NULL, 897),
+ NAME_FUNC_OFFSET(16174, glGetTexParameterIivEXT, glGetTexParameterIivEXT, NULL, 898),
+ NAME_FUNC_OFFSET(16198, glGetTexParameterIuivEXT, glGetTexParameterIuivEXT, NULL, 899),
+ NAME_FUNC_OFFSET(16223, glTexParameterIivEXT, glTexParameterIivEXT, NULL, 900),
+ NAME_FUNC_OFFSET(16244, glTexParameterIuivEXT, glTexParameterIuivEXT, NULL, 901),
+ NAME_FUNC_OFFSET(16266, glBeginConditionalRenderNV, glBeginConditionalRenderNV, NULL, 902),
+ NAME_FUNC_OFFSET(16293, glEndConditionalRenderNV, glEndConditionalRenderNV, NULL, 903),
+ NAME_FUNC_OFFSET(16318, glBeginTransformFeedbackEXT, glBeginTransformFeedbackEXT, NULL, 904),
+ NAME_FUNC_OFFSET(16346, glBindBufferBaseEXT, glBindBufferBaseEXT, NULL, 905),
+ NAME_FUNC_OFFSET(16366, glBindBufferOffsetEXT, glBindBufferOffsetEXT, NULL, 906),
+ NAME_FUNC_OFFSET(16388, glBindBufferRangeEXT, glBindBufferRangeEXT, NULL, 907),
+ NAME_FUNC_OFFSET(16409, glEndTransformFeedbackEXT, glEndTransformFeedbackEXT, NULL, 908),
+ NAME_FUNC_OFFSET(16435, glGetTransformFeedbackVaryingEXT, glGetTransformFeedbackVaryingEXT, NULL, 909),
+ NAME_FUNC_OFFSET(16468, glTransformFeedbackVaryingsEXT, glTransformFeedbackVaryingsEXT, NULL, 910),
+ NAME_FUNC_OFFSET(16499, glProvokingVertexEXT, glProvokingVertexEXT, NULL, 911),
+ NAME_FUNC_OFFSET(16520, gl_dispatch_stub_912, gl_dispatch_stub_912, NULL, 912),
+ NAME_FUNC_OFFSET(16551, gl_dispatch_stub_913, gl_dispatch_stub_913, NULL, 913),
+ NAME_FUNC_OFFSET(16571, glGetObjectParameterivAPPLE, glGetObjectParameterivAPPLE, NULL, 914),
+ NAME_FUNC_OFFSET(16599, glObjectPurgeableAPPLE, glObjectPurgeableAPPLE, NULL, 915),
+ NAME_FUNC_OFFSET(16622, glObjectUnpurgeableAPPLE, glObjectUnpurgeableAPPLE, NULL, 916),
+ NAME_FUNC_OFFSET(16647, glActiveProgramEXT, glActiveProgramEXT, NULL, 917),
+ NAME_FUNC_OFFSET(16666, glCreateShaderProgramEXT, glCreateShaderProgramEXT, NULL, 918),
+ NAME_FUNC_OFFSET(16691, glUseShaderProgramEXT, glUseShaderProgramEXT, NULL, 919),
+ NAME_FUNC_OFFSET(16713, glTextureBarrierNV, glTextureBarrierNV, NULL, 920),
+ NAME_FUNC_OFFSET(16732, gl_dispatch_stub_921, gl_dispatch_stub_921, NULL, 921),
+ NAME_FUNC_OFFSET(16757, gl_dispatch_stub_922, gl_dispatch_stub_922, NULL, 922),
+ NAME_FUNC_OFFSET(16786, gl_dispatch_stub_923, gl_dispatch_stub_923, NULL, 923),
+ NAME_FUNC_OFFSET(16817, gl_dispatch_stub_924, gl_dispatch_stub_924, NULL, 924),
+ NAME_FUNC_OFFSET(16841, gl_dispatch_stub_925, gl_dispatch_stub_925, NULL, 925),
+ NAME_FUNC_OFFSET(16866, glEGLImageTargetRenderbufferStorageOES, glEGLImageTargetRenderbufferStorageOES, NULL, 926),
+ NAME_FUNC_OFFSET(16905, glEGLImageTargetTexture2DOES, glEGLImageTargetTexture2DOES, NULL, 927),
+ NAME_FUNC_OFFSET(16934, glArrayElement, glArrayElement, NULL, 306),
+ NAME_FUNC_OFFSET(16952, glBindTexture, glBindTexture, NULL, 307),
+ NAME_FUNC_OFFSET(16969, glDrawArrays, glDrawArrays, NULL, 310),
+ NAME_FUNC_OFFSET(16985, glAreTexturesResident, glAreTexturesResidentEXT, glAreTexturesResidentEXT, 322),
+ NAME_FUNC_OFFSET(17010, glCopyTexImage1D, glCopyTexImage1D, NULL, 323),
+ NAME_FUNC_OFFSET(17030, glCopyTexImage2D, glCopyTexImage2D, NULL, 324),
+ NAME_FUNC_OFFSET(17050, glCopyTexSubImage1D, glCopyTexSubImage1D, NULL, 325),
+ NAME_FUNC_OFFSET(17073, glCopyTexSubImage2D, glCopyTexSubImage2D, NULL, 326),
+ NAME_FUNC_OFFSET(17096, glDeleteTextures, glDeleteTexturesEXT, glDeleteTexturesEXT, 327),
+ NAME_FUNC_OFFSET(17116, glGenTextures, glGenTexturesEXT, glGenTexturesEXT, 328),
+ NAME_FUNC_OFFSET(17133, glGetPointerv, glGetPointerv, NULL, 329),
+ NAME_FUNC_OFFSET(17150, glIsTexture, glIsTextureEXT, glIsTextureEXT, 330),
+ NAME_FUNC_OFFSET(17165, glPrioritizeTextures, glPrioritizeTextures, NULL, 331),
+ NAME_FUNC_OFFSET(17189, glTexSubImage1D, glTexSubImage1D, NULL, 332),
+ NAME_FUNC_OFFSET(17208, glTexSubImage2D, glTexSubImage2D, NULL, 333),
+ NAME_FUNC_OFFSET(17227, glBlendColor, glBlendColor, NULL, 336),
+ NAME_FUNC_OFFSET(17243, glBlendEquation, glBlendEquation, NULL, 337),
+ NAME_FUNC_OFFSET(17262, glDrawRangeElements, glDrawRangeElements, NULL, 338),
+ NAME_FUNC_OFFSET(17285, glColorTable, glColorTable, NULL, 339),
+ NAME_FUNC_OFFSET(17301, glColorTable, glColorTable, NULL, 339),
+ NAME_FUNC_OFFSET(17317, glColorTableParameterfv, glColorTableParameterfv, NULL, 340),
+ NAME_FUNC_OFFSET(17344, glColorTableParameteriv, glColorTableParameteriv, NULL, 341),
+ NAME_FUNC_OFFSET(17371, glCopyColorTable, glCopyColorTable, NULL, 342),
+ NAME_FUNC_OFFSET(17391, glGetColorTable, glGetColorTableEXT, glGetColorTableEXT, 343),
+ NAME_FUNC_OFFSET(17410, glGetColorTable, glGetColorTableEXT, glGetColorTableEXT, 343),
+ NAME_FUNC_OFFSET(17429, glGetColorTableParameterfv, glGetColorTableParameterfvEXT, glGetColorTableParameterfvEXT, 344),
+ NAME_FUNC_OFFSET(17459, glGetColorTableParameterfv, glGetColorTableParameterfvEXT, glGetColorTableParameterfvEXT, 344),
+ NAME_FUNC_OFFSET(17489, glGetColorTableParameteriv, glGetColorTableParameterivEXT, glGetColorTableParameterivEXT, 345),
+ NAME_FUNC_OFFSET(17519, glGetColorTableParameteriv, glGetColorTableParameterivEXT, glGetColorTableParameterivEXT, 345),
+ NAME_FUNC_OFFSET(17549, glColorSubTable, glColorSubTable, NULL, 346),
+ NAME_FUNC_OFFSET(17568, glCopyColorSubTable, glCopyColorSubTable, NULL, 347),
+ NAME_FUNC_OFFSET(17591, glConvolutionFilter1D, glConvolutionFilter1D, NULL, 348),
+ NAME_FUNC_OFFSET(17616, glConvolutionFilter2D, glConvolutionFilter2D, NULL, 349),
+ NAME_FUNC_OFFSET(17641, glConvolutionParameterf, glConvolutionParameterf, NULL, 350),
+ NAME_FUNC_OFFSET(17668, glConvolutionParameterfv, glConvolutionParameterfv, NULL, 351),
+ NAME_FUNC_OFFSET(17696, glConvolutionParameteri, glConvolutionParameteri, NULL, 352),
+ NAME_FUNC_OFFSET(17723, glConvolutionParameteriv, glConvolutionParameteriv, NULL, 353),
+ NAME_FUNC_OFFSET(17751, glCopyConvolutionFilter1D, glCopyConvolutionFilter1D, NULL, 354),
+ NAME_FUNC_OFFSET(17780, glCopyConvolutionFilter2D, glCopyConvolutionFilter2D, NULL, 355),
+ NAME_FUNC_OFFSET(17809, glGetConvolutionFilter, gl_dispatch_stub_356, gl_dispatch_stub_356, 356),
+ NAME_FUNC_OFFSET(17835, glGetConvolutionParameterfv, gl_dispatch_stub_357, gl_dispatch_stub_357, 357),
+ NAME_FUNC_OFFSET(17866, glGetConvolutionParameteriv, gl_dispatch_stub_358, gl_dispatch_stub_358, 358),
+ NAME_FUNC_OFFSET(17897, glGetSeparableFilter, gl_dispatch_stub_359, gl_dispatch_stub_359, 359),
+ NAME_FUNC_OFFSET(17921, glSeparableFilter2D, glSeparableFilter2D, NULL, 360),
+ NAME_FUNC_OFFSET(17944, glGetHistogram, gl_dispatch_stub_361, gl_dispatch_stub_361, 361),
+ NAME_FUNC_OFFSET(17962, glGetHistogramParameterfv, gl_dispatch_stub_362, gl_dispatch_stub_362, 362),
+ NAME_FUNC_OFFSET(17991, glGetHistogramParameteriv, gl_dispatch_stub_363, gl_dispatch_stub_363, 363),
+ NAME_FUNC_OFFSET(18020, glGetMinmax, gl_dispatch_stub_364, gl_dispatch_stub_364, 364),
+ NAME_FUNC_OFFSET(18035, glGetMinmaxParameterfv, gl_dispatch_stub_365, gl_dispatch_stub_365, 365),
+ NAME_FUNC_OFFSET(18061, glGetMinmaxParameteriv, gl_dispatch_stub_366, gl_dispatch_stub_366, 366),
+ NAME_FUNC_OFFSET(18087, glHistogram, glHistogram, NULL, 367),
+ NAME_FUNC_OFFSET(18102, glMinmax, glMinmax, NULL, 368),
+ NAME_FUNC_OFFSET(18114, glResetHistogram, glResetHistogram, NULL, 369),
+ NAME_FUNC_OFFSET(18134, glResetMinmax, glResetMinmax, NULL, 370),
+ NAME_FUNC_OFFSET(18151, glTexImage3D, glTexImage3D, NULL, 371),
+ NAME_FUNC_OFFSET(18167, glTexSubImage3D, glTexSubImage3D, NULL, 372),
+ NAME_FUNC_OFFSET(18186, glCopyTexSubImage3D, glCopyTexSubImage3D, NULL, 373),
+ NAME_FUNC_OFFSET(18209, glActiveTextureARB, glActiveTextureARB, NULL, 374),
+ NAME_FUNC_OFFSET(18225, glClientActiveTextureARB, glClientActiveTextureARB, NULL, 375),
+ NAME_FUNC_OFFSET(18247, glMultiTexCoord1dARB, glMultiTexCoord1dARB, NULL, 376),
+ NAME_FUNC_OFFSET(18265, glMultiTexCoord1dvARB, glMultiTexCoord1dvARB, NULL, 377),
+ NAME_FUNC_OFFSET(18284, glMultiTexCoord1fARB, glMultiTexCoord1fARB, NULL, 378),
+ NAME_FUNC_OFFSET(18302, glMultiTexCoord1fvARB, glMultiTexCoord1fvARB, NULL, 379),
+ NAME_FUNC_OFFSET(18321, glMultiTexCoord1iARB, glMultiTexCoord1iARB, NULL, 380),
+ NAME_FUNC_OFFSET(18339, glMultiTexCoord1ivARB, glMultiTexCoord1ivARB, NULL, 381),
+ NAME_FUNC_OFFSET(18358, glMultiTexCoord1sARB, glMultiTexCoord1sARB, NULL, 382),
+ NAME_FUNC_OFFSET(18376, glMultiTexCoord1svARB, glMultiTexCoord1svARB, NULL, 383),
+ NAME_FUNC_OFFSET(18395, glMultiTexCoord2dARB, glMultiTexCoord2dARB, NULL, 384),
+ NAME_FUNC_OFFSET(18413, glMultiTexCoord2dvARB, glMultiTexCoord2dvARB, NULL, 385),
+ NAME_FUNC_OFFSET(18432, glMultiTexCoord2fARB, glMultiTexCoord2fARB, NULL, 386),
+ NAME_FUNC_OFFSET(18450, glMultiTexCoord2fvARB, glMultiTexCoord2fvARB, NULL, 387),
+ NAME_FUNC_OFFSET(18469, glMultiTexCoord2iARB, glMultiTexCoord2iARB, NULL, 388),
+ NAME_FUNC_OFFSET(18487, glMultiTexCoord2ivARB, glMultiTexCoord2ivARB, NULL, 389),
+ NAME_FUNC_OFFSET(18506, glMultiTexCoord2sARB, glMultiTexCoord2sARB, NULL, 390),
+ NAME_FUNC_OFFSET(18524, glMultiTexCoord2svARB, glMultiTexCoord2svARB, NULL, 391),
+ NAME_FUNC_OFFSET(18543, glMultiTexCoord3dARB, glMultiTexCoord3dARB, NULL, 392),
+ NAME_FUNC_OFFSET(18561, glMultiTexCoord3dvARB, glMultiTexCoord3dvARB, NULL, 393),
+ NAME_FUNC_OFFSET(18580, glMultiTexCoord3fARB, glMultiTexCoord3fARB, NULL, 394),
+ NAME_FUNC_OFFSET(18598, glMultiTexCoord3fvARB, glMultiTexCoord3fvARB, NULL, 395),
+ NAME_FUNC_OFFSET(18617, glMultiTexCoord3iARB, glMultiTexCoord3iARB, NULL, 396),
+ NAME_FUNC_OFFSET(18635, glMultiTexCoord3ivARB, glMultiTexCoord3ivARB, NULL, 397),
+ NAME_FUNC_OFFSET(18654, glMultiTexCoord3sARB, glMultiTexCoord3sARB, NULL, 398),
+ NAME_FUNC_OFFSET(18672, glMultiTexCoord3svARB, glMultiTexCoord3svARB, NULL, 399),
+ NAME_FUNC_OFFSET(18691, glMultiTexCoord4dARB, glMultiTexCoord4dARB, NULL, 400),
+ NAME_FUNC_OFFSET(18709, glMultiTexCoord4dvARB, glMultiTexCoord4dvARB, NULL, 401),
+ NAME_FUNC_OFFSET(18728, glMultiTexCoord4fARB, glMultiTexCoord4fARB, NULL, 402),
+ NAME_FUNC_OFFSET(18746, glMultiTexCoord4fvARB, glMultiTexCoord4fvARB, NULL, 403),
+ NAME_FUNC_OFFSET(18765, glMultiTexCoord4iARB, glMultiTexCoord4iARB, NULL, 404),
+ NAME_FUNC_OFFSET(18783, glMultiTexCoord4ivARB, glMultiTexCoord4ivARB, NULL, 405),
+ NAME_FUNC_OFFSET(18802, glMultiTexCoord4sARB, glMultiTexCoord4sARB, NULL, 406),
+ NAME_FUNC_OFFSET(18820, glMultiTexCoord4svARB, glMultiTexCoord4svARB, NULL, 407),
+ NAME_FUNC_OFFSET(18839, glStencilOpSeparate, glStencilOpSeparate, NULL, 423),
+ NAME_FUNC_OFFSET(18862, glLoadTransposeMatrixdARB, glLoadTransposeMatrixdARB, NULL, 441),
+ NAME_FUNC_OFFSET(18885, glLoadTransposeMatrixfARB, glLoadTransposeMatrixfARB, NULL, 442),
+ NAME_FUNC_OFFSET(18908, glMultTransposeMatrixdARB, glMultTransposeMatrixdARB, NULL, 443),
+ NAME_FUNC_OFFSET(18931, glMultTransposeMatrixfARB, glMultTransposeMatrixfARB, NULL, 444),
+ NAME_FUNC_OFFSET(18954, glSampleCoverageARB, glSampleCoverageARB, NULL, 445),
+ NAME_FUNC_OFFSET(18971, glCompressedTexImage1DARB, glCompressedTexImage1DARB, NULL, 446),
+ NAME_FUNC_OFFSET(18994, glCompressedTexImage2DARB, glCompressedTexImage2DARB, NULL, 447),
+ NAME_FUNC_OFFSET(19017, glCompressedTexImage3DARB, glCompressedTexImage3DARB, NULL, 448),
+ NAME_FUNC_OFFSET(19040, glCompressedTexSubImage1DARB, glCompressedTexSubImage1DARB, NULL, 449),
+ NAME_FUNC_OFFSET(19066, glCompressedTexSubImage2DARB, glCompressedTexSubImage2DARB, NULL, 450),
+ NAME_FUNC_OFFSET(19092, glCompressedTexSubImage3DARB, glCompressedTexSubImage3DARB, NULL, 451),
+ NAME_FUNC_OFFSET(19118, glGetCompressedTexImageARB, glGetCompressedTexImageARB, NULL, 452),
+ NAME_FUNC_OFFSET(19142, glDisableVertexAttribArrayARB, glDisableVertexAttribArrayARB, NULL, 453),
+ NAME_FUNC_OFFSET(19169, glEnableVertexAttribArrayARB, glEnableVertexAttribArrayARB, NULL, 454),
+ NAME_FUNC_OFFSET(19195, glGetVertexAttribdvARB, glGetVertexAttribdvARB, NULL, 461),
+ NAME_FUNC_OFFSET(19215, glGetVertexAttribfvARB, glGetVertexAttribfvARB, NULL, 462),
+ NAME_FUNC_OFFSET(19235, glGetVertexAttribivARB, glGetVertexAttribivARB, NULL, 463),
+ NAME_FUNC_OFFSET(19255, glProgramEnvParameter4dARB, glProgramEnvParameter4dARB, NULL, 464),
+ NAME_FUNC_OFFSET(19278, glProgramEnvParameter4dvARB, glProgramEnvParameter4dvARB, NULL, 465),
+ NAME_FUNC_OFFSET(19302, glProgramEnvParameter4fARB, glProgramEnvParameter4fARB, NULL, 466),
+ NAME_FUNC_OFFSET(19325, glProgramEnvParameter4fvARB, glProgramEnvParameter4fvARB, NULL, 467),
+ NAME_FUNC_OFFSET(19349, glVertexAttrib1dARB, glVertexAttrib1dARB, NULL, 473),
+ NAME_FUNC_OFFSET(19366, glVertexAttrib1dvARB, glVertexAttrib1dvARB, NULL, 474),
+ NAME_FUNC_OFFSET(19384, glVertexAttrib1fARB, glVertexAttrib1fARB, NULL, 475),
+ NAME_FUNC_OFFSET(19401, glVertexAttrib1fvARB, glVertexAttrib1fvARB, NULL, 476),
+ NAME_FUNC_OFFSET(19419, glVertexAttrib1sARB, glVertexAttrib1sARB, NULL, 477),
+ NAME_FUNC_OFFSET(19436, glVertexAttrib1svARB, glVertexAttrib1svARB, NULL, 478),
+ NAME_FUNC_OFFSET(19454, glVertexAttrib2dARB, glVertexAttrib2dARB, NULL, 479),
+ NAME_FUNC_OFFSET(19471, glVertexAttrib2dvARB, glVertexAttrib2dvARB, NULL, 480),
+ NAME_FUNC_OFFSET(19489, glVertexAttrib2fARB, glVertexAttrib2fARB, NULL, 481),
+ NAME_FUNC_OFFSET(19506, glVertexAttrib2fvARB, glVertexAttrib2fvARB, NULL, 482),
+ NAME_FUNC_OFFSET(19524, glVertexAttrib2sARB, glVertexAttrib2sARB, NULL, 483),
+ NAME_FUNC_OFFSET(19541, glVertexAttrib2svARB, glVertexAttrib2svARB, NULL, 484),
+ NAME_FUNC_OFFSET(19559, glVertexAttrib3dARB, glVertexAttrib3dARB, NULL, 485),
+ NAME_FUNC_OFFSET(19576, glVertexAttrib3dvARB, glVertexAttrib3dvARB, NULL, 486),
+ NAME_FUNC_OFFSET(19594, glVertexAttrib3fARB, glVertexAttrib3fARB, NULL, 487),
+ NAME_FUNC_OFFSET(19611, glVertexAttrib3fvARB, glVertexAttrib3fvARB, NULL, 488),
+ NAME_FUNC_OFFSET(19629, glVertexAttrib3sARB, glVertexAttrib3sARB, NULL, 489),
+ NAME_FUNC_OFFSET(19646, glVertexAttrib3svARB, glVertexAttrib3svARB, NULL, 490),
+ NAME_FUNC_OFFSET(19664, glVertexAttrib4NbvARB, glVertexAttrib4NbvARB, NULL, 491),
+ NAME_FUNC_OFFSET(19683, glVertexAttrib4NivARB, glVertexAttrib4NivARB, NULL, 492),
+ NAME_FUNC_OFFSET(19702, glVertexAttrib4NsvARB, glVertexAttrib4NsvARB, NULL, 493),
+ NAME_FUNC_OFFSET(19721, glVertexAttrib4NubARB, glVertexAttrib4NubARB, NULL, 494),
+ NAME_FUNC_OFFSET(19740, glVertexAttrib4NubvARB, glVertexAttrib4NubvARB, NULL, 495),
+ NAME_FUNC_OFFSET(19760, glVertexAttrib4NuivARB, glVertexAttrib4NuivARB, NULL, 496),
+ NAME_FUNC_OFFSET(19780, glVertexAttrib4NusvARB, glVertexAttrib4NusvARB, NULL, 497),
+ NAME_FUNC_OFFSET(19800, glVertexAttrib4bvARB, glVertexAttrib4bvARB, NULL, 498),
+ NAME_FUNC_OFFSET(19818, glVertexAttrib4dARB, glVertexAttrib4dARB, NULL, 499),
+ NAME_FUNC_OFFSET(19835, glVertexAttrib4dvARB, glVertexAttrib4dvARB, NULL, 500),
+ NAME_FUNC_OFFSET(19853, glVertexAttrib4fARB, glVertexAttrib4fARB, NULL, 501),
+ NAME_FUNC_OFFSET(19870, glVertexAttrib4fvARB, glVertexAttrib4fvARB, NULL, 502),
+ NAME_FUNC_OFFSET(19888, glVertexAttrib4ivARB, glVertexAttrib4ivARB, NULL, 503),
+ NAME_FUNC_OFFSET(19906, glVertexAttrib4sARB, glVertexAttrib4sARB, NULL, 504),
+ NAME_FUNC_OFFSET(19923, glVertexAttrib4svARB, glVertexAttrib4svARB, NULL, 505),
+ NAME_FUNC_OFFSET(19941, glVertexAttrib4ubvARB, glVertexAttrib4ubvARB, NULL, 506),
+ NAME_FUNC_OFFSET(19960, glVertexAttrib4uivARB, glVertexAttrib4uivARB, NULL, 507),
+ NAME_FUNC_OFFSET(19979, glVertexAttrib4usvARB, glVertexAttrib4usvARB, NULL, 508),
+ NAME_FUNC_OFFSET(19998, glVertexAttribPointerARB, glVertexAttribPointerARB, NULL, 509),
+ NAME_FUNC_OFFSET(20020, glBindBufferARB, glBindBufferARB, NULL, 510),
+ NAME_FUNC_OFFSET(20033, glBufferDataARB, glBufferDataARB, NULL, 511),
+ NAME_FUNC_OFFSET(20046, glBufferSubDataARB, glBufferSubDataARB, NULL, 512),
+ NAME_FUNC_OFFSET(20062, glDeleteBuffersARB, glDeleteBuffersARB, NULL, 513),
+ NAME_FUNC_OFFSET(20078, glGenBuffersARB, glGenBuffersARB, NULL, 514),
+ NAME_FUNC_OFFSET(20091, glGetBufferParameterivARB, glGetBufferParameterivARB, NULL, 515),
+ NAME_FUNC_OFFSET(20114, glGetBufferPointervARB, glGetBufferPointervARB, NULL, 516),
+ NAME_FUNC_OFFSET(20134, glGetBufferSubDataARB, glGetBufferSubDataARB, NULL, 517),
+ NAME_FUNC_OFFSET(20153, glIsBufferARB, glIsBufferARB, NULL, 518),
+ NAME_FUNC_OFFSET(20164, glMapBufferARB, glMapBufferARB, NULL, 519),
+ NAME_FUNC_OFFSET(20176, glUnmapBufferARB, glUnmapBufferARB, NULL, 520),
+ NAME_FUNC_OFFSET(20190, glBeginQueryARB, glBeginQueryARB, NULL, 521),
+ NAME_FUNC_OFFSET(20203, glDeleteQueriesARB, glDeleteQueriesARB, NULL, 522),
+ NAME_FUNC_OFFSET(20219, glEndQueryARB, glEndQueryARB, NULL, 523),
+ NAME_FUNC_OFFSET(20230, glGenQueriesARB, glGenQueriesARB, NULL, 524),
+ NAME_FUNC_OFFSET(20243, glGetQueryObjectivARB, glGetQueryObjectivARB, NULL, 525),
+ NAME_FUNC_OFFSET(20262, glGetQueryObjectuivARB, glGetQueryObjectuivARB, NULL, 526),
+ NAME_FUNC_OFFSET(20282, glGetQueryivARB, glGetQueryivARB, NULL, 527),
+ NAME_FUNC_OFFSET(20295, glIsQueryARB, glIsQueryARB, NULL, 528),
+ NAME_FUNC_OFFSET(20305, glCompileShaderARB, glCompileShaderARB, NULL, 530),
+ NAME_FUNC_OFFSET(20321, glGetActiveUniformARB, glGetActiveUniformARB, NULL, 535),
+ NAME_FUNC_OFFSET(20340, glGetShaderSourceARB, glGetShaderSourceARB, NULL, 541),
+ NAME_FUNC_OFFSET(20358, glGetUniformLocationARB, glGetUniformLocationARB, NULL, 542),
+ NAME_FUNC_OFFSET(20379, glGetUniformfvARB, glGetUniformfvARB, NULL, 543),
+ NAME_FUNC_OFFSET(20394, glGetUniformivARB, glGetUniformivARB, NULL, 544),
+ NAME_FUNC_OFFSET(20409, glLinkProgramARB, glLinkProgramARB, NULL, 545),
+ NAME_FUNC_OFFSET(20423, glShaderSourceARB, glShaderSourceARB, NULL, 546),
+ NAME_FUNC_OFFSET(20438, glUniform1fARB, glUniform1fARB, NULL, 547),
+ NAME_FUNC_OFFSET(20450, glUniform1fvARB, glUniform1fvARB, NULL, 548),
+ NAME_FUNC_OFFSET(20463, glUniform1iARB, glUniform1iARB, NULL, 549),
+ NAME_FUNC_OFFSET(20475, glUniform1ivARB, glUniform1ivARB, NULL, 550),
+ NAME_FUNC_OFFSET(20488, glUniform2fARB, glUniform2fARB, NULL, 551),
+ NAME_FUNC_OFFSET(20500, glUniform2fvARB, glUniform2fvARB, NULL, 552),
+ NAME_FUNC_OFFSET(20513, glUniform2iARB, glUniform2iARB, NULL, 553),
+ NAME_FUNC_OFFSET(20525, glUniform2ivARB, glUniform2ivARB, NULL, 554),
+ NAME_FUNC_OFFSET(20538, glUniform3fARB, glUniform3fARB, NULL, 555),
+ NAME_FUNC_OFFSET(20550, glUniform3fvARB, glUniform3fvARB, NULL, 556),
+ NAME_FUNC_OFFSET(20563, glUniform3iARB, glUniform3iARB, NULL, 557),
+ NAME_FUNC_OFFSET(20575, glUniform3ivARB, glUniform3ivARB, NULL, 558),
+ NAME_FUNC_OFFSET(20588, glUniform4fARB, glUniform4fARB, NULL, 559),
+ NAME_FUNC_OFFSET(20600, glUniform4fvARB, glUniform4fvARB, NULL, 560),
+ NAME_FUNC_OFFSET(20613, glUniform4iARB, glUniform4iARB, NULL, 561),
+ NAME_FUNC_OFFSET(20625, glUniform4ivARB, glUniform4ivARB, NULL, 562),
+ NAME_FUNC_OFFSET(20638, glUniformMatrix2fvARB, glUniformMatrix2fvARB, NULL, 563),
+ NAME_FUNC_OFFSET(20657, glUniformMatrix3fvARB, glUniformMatrix3fvARB, NULL, 564),
+ NAME_FUNC_OFFSET(20676, glUniformMatrix4fvARB, glUniformMatrix4fvARB, NULL, 565),
+ NAME_FUNC_OFFSET(20695, glUseProgramObjectARB, glUseProgramObjectARB, NULL, 566),
+ NAME_FUNC_OFFSET(20708, glValidateProgramARB, glValidateProgramARB, NULL, 567),
+ NAME_FUNC_OFFSET(20726, glBindAttribLocationARB, glBindAttribLocationARB, NULL, 568),
+ NAME_FUNC_OFFSET(20747, glGetActiveAttribARB, glGetActiveAttribARB, NULL, 569),
+ NAME_FUNC_OFFSET(20765, glGetAttribLocationARB, glGetAttribLocationARB, NULL, 570),
+ NAME_FUNC_OFFSET(20785, glDrawBuffersARB, glDrawBuffersARB, NULL, 571),
+ NAME_FUNC_OFFSET(20799, glDrawBuffersARB, glDrawBuffersARB, NULL, 571),
+ NAME_FUNC_OFFSET(20816, glDrawArraysInstancedARB, glDrawArraysInstancedARB, NULL, 573),
+ NAME_FUNC_OFFSET(20841, glDrawArraysInstancedARB, glDrawArraysInstancedARB, NULL, 573),
+ NAME_FUNC_OFFSET(20863, glDrawElementsInstancedARB, glDrawElementsInstancedARB, NULL, 574),
+ NAME_FUNC_OFFSET(20890, glDrawElementsInstancedARB, glDrawElementsInstancedARB, NULL, 574),
+ NAME_FUNC_OFFSET(20914, glRenderbufferStorageMultisample, glRenderbufferStorageMultisample, NULL, 575),
+ NAME_FUNC_OFFSET(20950, gl_dispatch_stub_653, gl_dispatch_stub_653, NULL, 653),
+ NAME_FUNC_OFFSET(20966, gl_dispatch_stub_654, gl_dispatch_stub_654, NULL, 654),
+ NAME_FUNC_OFFSET(20985, glPointParameterfEXT, glPointParameterfEXT, NULL, 661),
+ NAME_FUNC_OFFSET(21003, glPointParameterfEXT, glPointParameterfEXT, NULL, 661),
+ NAME_FUNC_OFFSET(21024, glPointParameterfEXT, glPointParameterfEXT, NULL, 661),
+ NAME_FUNC_OFFSET(21046, glPointParameterfvEXT, glPointParameterfvEXT, NULL, 662),
+ NAME_FUNC_OFFSET(21065, glPointParameterfvEXT, glPointParameterfvEXT, NULL, 662),
+ NAME_FUNC_OFFSET(21087, glPointParameterfvEXT, glPointParameterfvEXT, NULL, 662),
+ NAME_FUNC_OFFSET(21110, glSecondaryColor3bEXT, glSecondaryColor3bEXT, NULL, 665),
+ NAME_FUNC_OFFSET(21129, glSecondaryColor3bvEXT, glSecondaryColor3bvEXT, NULL, 666),
+ NAME_FUNC_OFFSET(21149, glSecondaryColor3dEXT, glSecondaryColor3dEXT, NULL, 667),
+ NAME_FUNC_OFFSET(21168, glSecondaryColor3dvEXT, glSecondaryColor3dvEXT, NULL, 668),
+ NAME_FUNC_OFFSET(21188, glSecondaryColor3fEXT, glSecondaryColor3fEXT, NULL, 669),
+ NAME_FUNC_OFFSET(21207, glSecondaryColor3fvEXT, glSecondaryColor3fvEXT, NULL, 670),
+ NAME_FUNC_OFFSET(21227, glSecondaryColor3iEXT, glSecondaryColor3iEXT, NULL, 671),
+ NAME_FUNC_OFFSET(21246, glSecondaryColor3ivEXT, glSecondaryColor3ivEXT, NULL, 672),
+ NAME_FUNC_OFFSET(21266, glSecondaryColor3sEXT, glSecondaryColor3sEXT, NULL, 673),
+ NAME_FUNC_OFFSET(21285, glSecondaryColor3svEXT, glSecondaryColor3svEXT, NULL, 674),
+ NAME_FUNC_OFFSET(21305, glSecondaryColor3ubEXT, glSecondaryColor3ubEXT, NULL, 675),
+ NAME_FUNC_OFFSET(21325, glSecondaryColor3ubvEXT, glSecondaryColor3ubvEXT, NULL, 676),
+ NAME_FUNC_OFFSET(21346, glSecondaryColor3uiEXT, glSecondaryColor3uiEXT, NULL, 677),
+ NAME_FUNC_OFFSET(21366, glSecondaryColor3uivEXT, glSecondaryColor3uivEXT, NULL, 678),
+ NAME_FUNC_OFFSET(21387, glSecondaryColor3usEXT, glSecondaryColor3usEXT, NULL, 679),
+ NAME_FUNC_OFFSET(21407, glSecondaryColor3usvEXT, glSecondaryColor3usvEXT, NULL, 680),
+ NAME_FUNC_OFFSET(21428, glSecondaryColorPointerEXT, glSecondaryColorPointerEXT, NULL, 681),
+ NAME_FUNC_OFFSET(21452, glMultiDrawArraysEXT, glMultiDrawArraysEXT, NULL, 682),
+ NAME_FUNC_OFFSET(21470, glMultiDrawElementsEXT, glMultiDrawElementsEXT, NULL, 683),
+ NAME_FUNC_OFFSET(21490, glFogCoordPointerEXT, glFogCoordPointerEXT, NULL, 684),
+ NAME_FUNC_OFFSET(21508, glFogCoorddEXT, glFogCoorddEXT, NULL, 685),
+ NAME_FUNC_OFFSET(21520, glFogCoorddvEXT, glFogCoorddvEXT, NULL, 686),
+ NAME_FUNC_OFFSET(21533, glFogCoordfEXT, glFogCoordfEXT, NULL, 687),
+ NAME_FUNC_OFFSET(21545, glFogCoordfvEXT, glFogCoordfvEXT, NULL, 688),
+ NAME_FUNC_OFFSET(21558, glBlendFuncSeparateEXT, glBlendFuncSeparateEXT, NULL, 690),
+ NAME_FUNC_OFFSET(21578, glBlendFuncSeparateEXT, glBlendFuncSeparateEXT, NULL, 690),
+ NAME_FUNC_OFFSET(21602, glWindowPos2dMESA, glWindowPos2dMESA, NULL, 707),
+ NAME_FUNC_OFFSET(21616, glWindowPos2dMESA, glWindowPos2dMESA, NULL, 707),
+ NAME_FUNC_OFFSET(21633, glWindowPos2dvMESA, glWindowPos2dvMESA, NULL, 708),
+ NAME_FUNC_OFFSET(21648, glWindowPos2dvMESA, glWindowPos2dvMESA, NULL, 708),
+ NAME_FUNC_OFFSET(21666, glWindowPos2fMESA, glWindowPos2fMESA, NULL, 709),
+ NAME_FUNC_OFFSET(21680, glWindowPos2fMESA, glWindowPos2fMESA, NULL, 709),
+ NAME_FUNC_OFFSET(21697, glWindowPos2fvMESA, glWindowPos2fvMESA, NULL, 710),
+ NAME_FUNC_OFFSET(21712, glWindowPos2fvMESA, glWindowPos2fvMESA, NULL, 710),
+ NAME_FUNC_OFFSET(21730, glWindowPos2iMESA, glWindowPos2iMESA, NULL, 711),
+ NAME_FUNC_OFFSET(21744, glWindowPos2iMESA, glWindowPos2iMESA, NULL, 711),
+ NAME_FUNC_OFFSET(21761, glWindowPos2ivMESA, glWindowPos2ivMESA, NULL, 712),
+ NAME_FUNC_OFFSET(21776, glWindowPos2ivMESA, glWindowPos2ivMESA, NULL, 712),
+ NAME_FUNC_OFFSET(21794, glWindowPos2sMESA, glWindowPos2sMESA, NULL, 713),
+ NAME_FUNC_OFFSET(21808, glWindowPos2sMESA, glWindowPos2sMESA, NULL, 713),
+ NAME_FUNC_OFFSET(21825, glWindowPos2svMESA, glWindowPos2svMESA, NULL, 714),
+ NAME_FUNC_OFFSET(21840, glWindowPos2svMESA, glWindowPos2svMESA, NULL, 714),
+ NAME_FUNC_OFFSET(21858, glWindowPos3dMESA, glWindowPos3dMESA, NULL, 715),
+ NAME_FUNC_OFFSET(21872, glWindowPos3dMESA, glWindowPos3dMESA, NULL, 715),
+ NAME_FUNC_OFFSET(21889, glWindowPos3dvMESA, glWindowPos3dvMESA, NULL, 716),
+ NAME_FUNC_OFFSET(21904, glWindowPos3dvMESA, glWindowPos3dvMESA, NULL, 716),
+ NAME_FUNC_OFFSET(21922, glWindowPos3fMESA, glWindowPos3fMESA, NULL, 717),
+ NAME_FUNC_OFFSET(21936, glWindowPos3fMESA, glWindowPos3fMESA, NULL, 717),
+ NAME_FUNC_OFFSET(21953, glWindowPos3fvMESA, glWindowPos3fvMESA, NULL, 718),
+ NAME_FUNC_OFFSET(21968, glWindowPos3fvMESA, glWindowPos3fvMESA, NULL, 718),
+ NAME_FUNC_OFFSET(21986, glWindowPos3iMESA, glWindowPos3iMESA, NULL, 719),
+ NAME_FUNC_OFFSET(22000, glWindowPos3iMESA, glWindowPos3iMESA, NULL, 719),
+ NAME_FUNC_OFFSET(22017, glWindowPos3ivMESA, glWindowPos3ivMESA, NULL, 720),
+ NAME_FUNC_OFFSET(22032, glWindowPos3ivMESA, glWindowPos3ivMESA, NULL, 720),
+ NAME_FUNC_OFFSET(22050, glWindowPos3sMESA, glWindowPos3sMESA, NULL, 721),
+ NAME_FUNC_OFFSET(22064, glWindowPos3sMESA, glWindowPos3sMESA, NULL, 721),
+ NAME_FUNC_OFFSET(22081, glWindowPos3svMESA, glWindowPos3svMESA, NULL, 722),
+ NAME_FUNC_OFFSET(22096, glWindowPos3svMESA, glWindowPos3svMESA, NULL, 722),
+ NAME_FUNC_OFFSET(22114, glBindProgramNV, glBindProgramNV, NULL, 741),
+ NAME_FUNC_OFFSET(22131, glDeleteProgramsNV, glDeleteProgramsNV, NULL, 742),
+ NAME_FUNC_OFFSET(22151, glGenProgramsNV, glGenProgramsNV, NULL, 744),
+ NAME_FUNC_OFFSET(22168, glGetVertexAttribPointervNV, glGetVertexAttribPointervNV, NULL, 750),
+ NAME_FUNC_OFFSET(22194, glGetVertexAttribPointervNV, glGetVertexAttribPointervNV, NULL, 750),
+ NAME_FUNC_OFFSET(22223, glIsProgramNV, glIsProgramNV, NULL, 754),
+ NAME_FUNC_OFFSET(22238, glPointParameteriNV, glPointParameteriNV, NULL, 818),
+ NAME_FUNC_OFFSET(22256, glPointParameterivNV, glPointParameterivNV, NULL, 819),
+ NAME_FUNC_OFFSET(22275, gl_dispatch_stub_822, gl_dispatch_stub_822, NULL, 822),
+ NAME_FUNC_OFFSET(22296, gl_dispatch_stub_824, gl_dispatch_stub_824, NULL, 824),
+ NAME_FUNC_OFFSET(22312, glPrimitiveRestartIndexNV, glPrimitiveRestartIndexNV, NULL, 831),
+ NAME_FUNC_OFFSET(22336, gl_dispatch_stub_834, gl_dispatch_stub_834, NULL, 834),
+ NAME_FUNC_OFFSET(22360, gl_dispatch_stub_834, gl_dispatch_stub_834, NULL, 834),
+ NAME_FUNC_OFFSET(22387, glBindFramebufferEXT, glBindFramebufferEXT, NULL, 835),
+ NAME_FUNC_OFFSET(22405, glBindRenderbufferEXT, glBindRenderbufferEXT, NULL, 836),
+ NAME_FUNC_OFFSET(22424, glCheckFramebufferStatusEXT, glCheckFramebufferStatusEXT, NULL, 837),
+ NAME_FUNC_OFFSET(22449, glDeleteFramebuffersEXT, glDeleteFramebuffersEXT, NULL, 838),
+ NAME_FUNC_OFFSET(22470, glDeleteRenderbuffersEXT, glDeleteRenderbuffersEXT, NULL, 839),
+ NAME_FUNC_OFFSET(22492, glFramebufferRenderbufferEXT, glFramebufferRenderbufferEXT, NULL, 840),
+ NAME_FUNC_OFFSET(22518, glFramebufferTexture1DEXT, glFramebufferTexture1DEXT, NULL, 841),
+ NAME_FUNC_OFFSET(22541, glFramebufferTexture2DEXT, glFramebufferTexture2DEXT, NULL, 842),
+ NAME_FUNC_OFFSET(22564, glFramebufferTexture3DEXT, glFramebufferTexture3DEXT, NULL, 843),
+ NAME_FUNC_OFFSET(22587, glGenFramebuffersEXT, glGenFramebuffersEXT, NULL, 844),
+ NAME_FUNC_OFFSET(22605, glGenRenderbuffersEXT, glGenRenderbuffersEXT, NULL, 845),
+ NAME_FUNC_OFFSET(22624, glGenerateMipmapEXT, glGenerateMipmapEXT, NULL, 846),
+ NAME_FUNC_OFFSET(22641, glGetFramebufferAttachmentParameterivEXT, glGetFramebufferAttachmentParameterivEXT, NULL, 847),
+ NAME_FUNC_OFFSET(22679, glGetRenderbufferParameterivEXT, glGetRenderbufferParameterivEXT, NULL, 848),
+ NAME_FUNC_OFFSET(22708, glIsFramebufferEXT, glIsFramebufferEXT, NULL, 849),
+ NAME_FUNC_OFFSET(22724, glIsRenderbufferEXT, glIsRenderbufferEXT, NULL, 850),
+ NAME_FUNC_OFFSET(22741, glRenderbufferStorageEXT, glRenderbufferStorageEXT, NULL, 851),
+ NAME_FUNC_OFFSET(22763, gl_dispatch_stub_852, gl_dispatch_stub_852, NULL, 852),
+ NAME_FUNC_OFFSET(22781, glBindFragDataLocationEXT, glBindFragDataLocationEXT, NULL, 855),
+ NAME_FUNC_OFFSET(22804, glGetFragDataLocationEXT, glGetFragDataLocationEXT, NULL, 856),
+ NAME_FUNC_OFFSET(22826, glGetUniformuivEXT, glGetUniformuivEXT, NULL, 857),
+ NAME_FUNC_OFFSET(22842, glGetVertexAttribIivEXT, glGetVertexAttribIivEXT, NULL, 858),
+ NAME_FUNC_OFFSET(22863, glGetVertexAttribIuivEXT, glGetVertexAttribIuivEXT, NULL, 859),
+ NAME_FUNC_OFFSET(22885, glUniform1uiEXT, glUniform1uiEXT, NULL, 860),
+ NAME_FUNC_OFFSET(22898, glUniform1uivEXT, glUniform1uivEXT, NULL, 861),
+ NAME_FUNC_OFFSET(22912, glUniform2uiEXT, glUniform2uiEXT, NULL, 862),
+ NAME_FUNC_OFFSET(22925, glUniform2uivEXT, glUniform2uivEXT, NULL, 863),
+ NAME_FUNC_OFFSET(22939, glUniform3uiEXT, glUniform3uiEXT, NULL, 864),
+ NAME_FUNC_OFFSET(22952, glUniform3uivEXT, glUniform3uivEXT, NULL, 865),
+ NAME_FUNC_OFFSET(22966, glUniform4uiEXT, glUniform4uiEXT, NULL, 866),
+ NAME_FUNC_OFFSET(22979, glUniform4uivEXT, glUniform4uivEXT, NULL, 867),
+ NAME_FUNC_OFFSET(22993, glVertexAttribI1iEXT, glVertexAttribI1iEXT, NULL, 868),
+ NAME_FUNC_OFFSET(23011, glVertexAttribI1ivEXT, glVertexAttribI1ivEXT, NULL, 869),
+ NAME_FUNC_OFFSET(23030, glVertexAttribI1uiEXT, glVertexAttribI1uiEXT, NULL, 870),
+ NAME_FUNC_OFFSET(23049, glVertexAttribI1uivEXT, glVertexAttribI1uivEXT, NULL, 871),
+ NAME_FUNC_OFFSET(23069, glVertexAttribI2iEXT, glVertexAttribI2iEXT, NULL, 872),
+ NAME_FUNC_OFFSET(23087, glVertexAttribI2ivEXT, glVertexAttribI2ivEXT, NULL, 873),
+ NAME_FUNC_OFFSET(23106, glVertexAttribI2uiEXT, glVertexAttribI2uiEXT, NULL, 874),
+ NAME_FUNC_OFFSET(23125, glVertexAttribI2uivEXT, glVertexAttribI2uivEXT, NULL, 875),
+ NAME_FUNC_OFFSET(23145, glVertexAttribI3iEXT, glVertexAttribI3iEXT, NULL, 876),
+ NAME_FUNC_OFFSET(23163, glVertexAttribI3ivEXT, glVertexAttribI3ivEXT, NULL, 877),
+ NAME_FUNC_OFFSET(23182, glVertexAttribI3uiEXT, glVertexAttribI3uiEXT, NULL, 878),
+ NAME_FUNC_OFFSET(23201, glVertexAttribI3uivEXT, glVertexAttribI3uivEXT, NULL, 879),
+ NAME_FUNC_OFFSET(23221, glVertexAttribI4bvEXT, glVertexAttribI4bvEXT, NULL, 880),
+ NAME_FUNC_OFFSET(23240, glVertexAttribI4iEXT, glVertexAttribI4iEXT, NULL, 881),
+ NAME_FUNC_OFFSET(23258, glVertexAttribI4ivEXT, glVertexAttribI4ivEXT, NULL, 882),
+ NAME_FUNC_OFFSET(23277, glVertexAttribI4svEXT, glVertexAttribI4svEXT, NULL, 883),
+ NAME_FUNC_OFFSET(23296, glVertexAttribI4ubvEXT, glVertexAttribI4ubvEXT, NULL, 884),
+ NAME_FUNC_OFFSET(23316, glVertexAttribI4uiEXT, glVertexAttribI4uiEXT, NULL, 885),
+ NAME_FUNC_OFFSET(23335, glVertexAttribI4uivEXT, glVertexAttribI4uivEXT, NULL, 886),
+ NAME_FUNC_OFFSET(23355, glVertexAttribI4usvEXT, glVertexAttribI4usvEXT, NULL, 887),
+ NAME_FUNC_OFFSET(23375, glVertexAttribIPointerEXT, glVertexAttribIPointerEXT, NULL, 888),
+ NAME_FUNC_OFFSET(23398, glFramebufferTextureLayerEXT, glFramebufferTextureLayerEXT, NULL, 889),
+ NAME_FUNC_OFFSET(23424, glColorMaskIndexedEXT, glColorMaskIndexedEXT, NULL, 890),
+ NAME_FUNC_OFFSET(23437, glDisableIndexedEXT, glDisableIndexedEXT, NULL, 891),
+ NAME_FUNC_OFFSET(23448, glEnableIndexedEXT, glEnableIndexedEXT, NULL, 892),
+ NAME_FUNC_OFFSET(23458, glGetBooleanIndexedvEXT, glGetBooleanIndexedvEXT, NULL, 893),
+ NAME_FUNC_OFFSET(23474, glGetIntegerIndexedvEXT, glGetIntegerIndexedvEXT, NULL, 894),
+ NAME_FUNC_OFFSET(23490, glIsEnabledIndexedEXT, glIsEnabledIndexedEXT, NULL, 895),
+ NAME_FUNC_OFFSET(23503, glGetTexParameterIivEXT, glGetTexParameterIivEXT, NULL, 898),
+ NAME_FUNC_OFFSET(23524, glGetTexParameterIuivEXT, glGetTexParameterIuivEXT, NULL, 899),
+ NAME_FUNC_OFFSET(23546, glTexParameterIivEXT, glTexParameterIivEXT, NULL, 900),
+ NAME_FUNC_OFFSET(23564, glTexParameterIuivEXT, glTexParameterIuivEXT, NULL, 901),
+ NAME_FUNC_OFFSET(23583, glBeginConditionalRenderNV, glBeginConditionalRenderNV, NULL, 902),
+ NAME_FUNC_OFFSET(23608, glEndConditionalRenderNV, glEndConditionalRenderNV, NULL, 903),
+ NAME_FUNC_OFFSET(23631, glBeginTransformFeedbackEXT, glBeginTransformFeedbackEXT, NULL, 904),
+ NAME_FUNC_OFFSET(23656, glBindBufferBaseEXT, glBindBufferBaseEXT, NULL, 905),
+ NAME_FUNC_OFFSET(23673, glBindBufferRangeEXT, glBindBufferRangeEXT, NULL, 907),
+ NAME_FUNC_OFFSET(23691, glEndTransformFeedbackEXT, glEndTransformFeedbackEXT, NULL, 908),
+ NAME_FUNC_OFFSET(23714, glGetTransformFeedbackVaryingEXT, glGetTransformFeedbackVaryingEXT, NULL, 909),
+ NAME_FUNC_OFFSET(23744, glTransformFeedbackVaryingsEXT, glTransformFeedbackVaryingsEXT, NULL, 910),
+ NAME_FUNC_OFFSET(23772, glProvokingVertexEXT, glProvokingVertexEXT, NULL, 911),
NAME_FUNC_OFFSET(-1, NULL, NULL, NULL, 0)
};
diff --git a/xorg-server/glx/glxcmds.c b/xorg-server/glx/glxcmds.c
index 38cb7390a..2c5e13031 100644
--- a/xorg-server/glx/glxcmds.c
+++ b/xorg-server/glx/glxcmds.c
@@ -1137,10 +1137,11 @@ DoCreateGLXDrawable(ClientPtr client, __GLXscreen *pGlxScreen,
return BadAlloc;
}
- /* Add the glx drawable under the XID of the underlying X drawable
- * too. That way we'll get a callback in DrawableGone and can
- * clean up properly when the drawable is destroyed. */
- if (drawableId != glxDrawableId &&
+ /*
+ * Windows aren't refcounted, so track both the X and the GLX window
+ * so we get called regardless of destruction order.
+ */
+ if (drawableId != glxDrawableId && type == GLX_DRAWABLE_WINDOW &&
!AddResource(pDraw->id, __glXDrawableRes, pGlxDraw)) {
pGlxDraw->destroy (pGlxDraw);
return BadAlloc;
@@ -1171,6 +1172,8 @@ DoCreateGLXPixmap(ClientPtr client, __GLXscreen *pGlxScreen, __GLXconfig *config
err = DoCreateGLXDrawable(client, pGlxScreen, config, pDraw, drawableId,
glxDrawableId, GLX_DRAWABLE_PIXMAP);
+ ((PixmapPtr)pDraw)->refcnt++;
+
return err;
}
diff --git a/xorg-server/glx/glxdri2.c b/xorg-server/glx/glxdri2.c
index db0d3d999..968141b90 100644
--- a/xorg-server/glx/glxdri2.c
+++ b/xorg-server/glx/glxdri2.c
@@ -184,6 +184,7 @@ __glXdriSwapEvent(ClientPtr client, void *data, int type, CARD64 ust,
break;
default:
/* unknown swap completion type */
+ wire.event_type = 0;
break;
}
wire.drawable = drawable->drawId;
diff --git a/xorg-server/glx/glxext.c b/xorg-server/glx/glxext.c
index 57fc23441..043e54d78 100644
--- a/xorg-server/glx/glxext.c
+++ b/xorg-server/glx/glxext.c
@@ -124,15 +124,15 @@ static Bool DrawableGone(__GLXdrawable *glxPriv, XID xid)
{
__GLXcontext *c, *next;
- /* If this drawable was created using glx 1.3 drawable
- * constructors, we added it as a glx drawable resource under both
- * its glx drawable ID and it X drawable ID. Remove the other
- * resource now so we don't a callback for freed memory. */
- if (glxPriv->drawId != glxPriv->pDraw->id) {
- if (xid == glxPriv->drawId)
- FreeResourceByType(glxPriv->pDraw->id, __glXDrawableRes, TRUE);
- else
- FreeResourceByType(glxPriv->drawId, __glXDrawableRes, TRUE);
+ if (glxPriv->type == GLX_DRAWABLE_WINDOW) {
+ /* If this was created by glXCreateWindow, free the matching resource */
+ if (glxPriv->drawId != glxPriv->pDraw->id) {
+ if (xid == glxPriv->drawId)
+ FreeResourceByType(glxPriv->pDraw->id, __glXDrawableRes, TRUE);
+ else
+ FreeResourceByType(glxPriv->drawId, __glXDrawableRes, TRUE);
+ }
+ /* otherwise this window was implicitly created by MakeCurrent */
}
for (c = glxAllContexts; c; c = next) {
@@ -151,6 +151,10 @@ static Bool DrawableGone(__GLXdrawable *glxPriv, XID xid)
c->readPriv = NULL;
}
+ /* drop our reference to any backing pixmap */
+ if (glxPriv->type == GLX_DRAWABLE_PIXMAP)
+ glxPriv->pDraw->pScreen->DestroyPixmap((PixmapPtr)glxPriv->pDraw);
+
glxPriv->destroy(glxPriv);
return True;
diff --git a/xorg-server/glx/indirect_dispatch.h b/xorg-server/glx/indirect_dispatch.h
index 21788ec77..876767cb5 100644
--- a/xorg-server/glx/indirect_dispatch.h
+++ b/xorg-server/glx/indirect_dispatch.h
@@ -28,7 +28,7 @@
#if !defined( _INDIRECT_DISPATCH_H_ )
# define _INDIRECT_DISPATCH_H_
-# if defined(__GNUC__) || (defined(__SUNPRO_C) && (__SUNPRO_C >= 0x590)) && defined(__ELF__)
+# if (defined(__GNUC__) && !defined(__CYGWIN__) && !defined(__MINGW32__)) || (defined(__SUNPRO_C) && (__SUNPRO_C >= 0x590) && defined(__ELF__))
# define HIDDEN __attribute__((visibility("hidden")))
# else
# define HIDDEN
@@ -327,8 +327,6 @@ extern HIDDEN int __glXDisp_GetMinmax(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetMinmax(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_GetMinmaxEXT(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_GetMinmaxEXT(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_ProgramEnvParameter4dvARB(GLbyte * pc);
@@ -587,6 +585,8 @@ extern HIDDEN void __glXDisp_VertexAttrib2svNV(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttrib2svNV(GLbyte * pc);
extern HIDDEN void __glXDisp_VertexAttrib4NuivARB(GLbyte * pc);
extern HIDDEN void __glXDispSwap_VertexAttrib4NuivARB(GLbyte * pc);
+extern HIDDEN int __glXDisp_GetVertexAttribdvNV(struct __GLXclientStateRec *, GLbyte *);
+extern HIDDEN int __glXDispSwap_GetVertexAttribdvNV(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDisp_DestroyWindow(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN int __glXDispSwap_DestroyWindow(struct __GLXclientStateRec *, GLbyte *);
extern HIDDEN void __glXDisp_Color4sv(GLbyte * pc);
diff --git a/xorg-server/glx/indirect_reqsize.h b/xorg-server/glx/indirect_reqsize.h
index c0e6dc863..eb0a793cd 100644
--- a/xorg-server/glx/indirect_reqsize.h
+++ b/xorg-server/glx/indirect_reqsize.h
@@ -28,7 +28,7 @@
#if !defined( _INDIRECT_REQSIZE_H_ )
# define _INDIRECT_REQSIZE_H_
-# if defined(__GNUC__) || (defined(__SUNPRO_C) && (__SUNPRO_C >= 0x590)) && defined(__ELF__)
+# if (defined(__GNUC__) && !defined(__CYGWIN__) && !defined(__MINGW32__)) || (defined(__SUNPRO_C) && (__SUNPRO_C >= 0x590) && defined(__ELF__))
# define HIDDEN __attribute__((visibility("hidden")))
# else
# define HIDDEN
diff --git a/xorg-server/glx/indirect_size.h b/xorg-server/glx/indirect_size.h
index a1b1b3fd0..df7371380 100644
--- a/xorg-server/glx/indirect_size.h
+++ b/xorg-server/glx/indirect_size.h
@@ -48,7 +48,7 @@
# define FASTCALL
# endif
-# if defined(__GNUC__) || (defined(__SUNPRO_C) && (__SUNPRO_C >= 0x590)) && defined(__ELF__)
+# if (defined(__GNUC__) && !defined(__CYGWIN__) && !defined(__MINGW32__)) || (defined(__SUNPRO_C) && (__SUNPRO_C >= 0x590) && defined(__ELF__))
# define INTERNAL __attribute__((visibility("internal")))
# else
# define INTERNAL
diff --git a/xorg-server/glx/indirect_size_get.c b/xorg-server/glx/indirect_size_get.c
index 863adbec2..ad471b54f 100644
--- a/xorg-server/glx/indirect_size_get.c
+++ b/xorg-server/glx/indirect_size_get.c
@@ -51,7 +51,7 @@
# define FASTCALL
# endif
-# if defined(__GNUC__) || (defined(__SUNPRO_C) && (__SUNPRO_C >= 0x590)) && defined(__ELF__)
+# if (defined(__GNUC__) && !defined(__CYGWIN__) && !defined(__MINGW32__)) || (defined(__SUNPRO_C) && (__SUNPRO_C >= 0x590) && defined(__ELF__))
# define INTERNAL __attribute__((visibility("internal")))
# else
# define INTERNAL
@@ -604,6 +604,7 @@ __glGetBooleanv_size( GLenum e )
case GL_OCCLUSION_TEST_HP:
case GL_OCCLUSION_TEST_RESULT_HP:
case GL_LIGHT_MODEL_COLOR_CONTROL:
+ case GL_RESET_NOTIFICATION_STRATEGY_ARB:
case GL_CURRENT_FOG_COORD:
case GL_FOG_COORDINATE_ARRAY_TYPE:
case GL_FOG_COORDINATE_ARRAY_STRIDE:
diff --git a/xorg-server/glx/indirect_size_get.h b/xorg-server/glx/indirect_size_get.h
index b8aeedae2..9225a8300 100644
--- a/xorg-server/glx/indirect_size_get.h
+++ b/xorg-server/glx/indirect_size_get.h
@@ -48,7 +48,7 @@
# define FASTCALL
# endif
-# if defined(__GNUC__) || (defined(__SUNPRO_C) && (__SUNPRO_C >= 0x590)) && defined(__ELF__)
+# if (defined(__GNUC__) && !defined(__CYGWIN__) && !defined(__MINGW32__)) || (defined(__SUNPRO_C) && (__SUNPRO_C >= 0x590) && defined(__ELF__))
# define INTERNAL __attribute__((visibility("internal")))
# else
# define INTERNAL
diff --git a/xorg-server/hw/dmx/input/dmxevents.c b/xorg-server/hw/dmx/input/dmxevents.c
index efcd07da3..c8dd92e47 100644
--- a/xorg-server/hw/dmx/input/dmxevents.c
+++ b/xorg-server/hw/dmx/input/dmxevents.c
@@ -453,8 +453,8 @@ static int dmxTranslateAndEnqueueExtEvent(DMXLocalInputInfoPtr dmxLocal,
if (block)
dmxSigioBlock();
GetEventList(&events);
- nevents = GetKeyboardValuatorEvents(events, pDevice, event,
- ke->keycode, &mask);
+ nevents = GetKeyboardEvents(events, pDevice, event,
+ ke->keycode, &mask);
for (i = 0; i < nevents; i++)
mieqEnqueue(pDevice, (InternalEvent*)(events + i)->event);
@@ -685,7 +685,7 @@ void dmxEnqueue(DevicePtr pDev, int type, int detail, KeySym keySym,
GetEventList(&events);
/*ErrorF("KEY %d sym %d\n", detail, (int) keySym);*/
- nevents = GetKeyboardEvents(events, p, type, detail);
+ nevents = GetKeyboardEvents(events, p, type, detail, NULL);
for (i = 0; i < nevents; i++)
mieqEnqueue(p, (InternalEvent*)(events + i)->event);
return;
diff --git a/xorg-server/hw/kdrive/src/kinput.c b/xorg-server/hw/kdrive/src/kinput.c
index 2ae0a201e..4b4d424d4 100644
--- a/xorg-server/hw/kdrive/src/kinput.c
+++ b/xorg-server/hw/kdrive/src/kinput.c
@@ -1827,7 +1827,7 @@ KdReleaseAllKeys (void)
if (key_is_down(ki->dixdev, key, KEY_POSTED | KEY_PROCESSED)) {
KdHandleKeyboardEvent(ki, KeyRelease, key);
GetEventList(&kdEvents);
- nEvents = GetKeyboardEvents(kdEvents, ki->dixdev, KeyRelease, key);
+ nEvents = GetKeyboardEvents(kdEvents, ki->dixdev, KeyRelease, key, NULL);
for (i = 0; i < nEvents; i++)
KdQueueEvent (ki->dixdev, (kdEvents + i)->event);
}
@@ -1887,7 +1887,7 @@ KdEnqueueKeyboardEvent(KdKeyboardInfo *ki,
GetEventList(&kdEvents);
- nEvents = GetKeyboardEvents(kdEvents, ki->dixdev, type, key_code);
+ nEvents = GetKeyboardEvents(kdEvents, ki->dixdev, type, key_code, NULL);
for (i = 0; i < nEvents; i++)
KdQueueEvent(ki->dixdev, (InternalEvent *)((kdEvents + i)->event));
}
diff --git a/xorg-server/hw/xfree86/common/xf86Configure.c b/xorg-server/hw/xfree86/common/xf86Configure.c
index bccdd403c..ba0628ffd 100644
--- a/xorg-server/hw/xfree86/common/xf86Configure.c
+++ b/xorg-server/hw/xfree86/common/xf86Configure.c
@@ -63,6 +63,9 @@ static char *DFLT_MOUSE_PROTO = "auto";
#elif defined(linux)
static char DFLT_MOUSE_DEV[] = "/dev/input/mice";
static char DFLT_MOUSE_PROTO[] = "auto";
+#elif defined(WSCONS_SUPPORT)
+static char *DFLT_MOUSE_DEV = "/dev/wsmouse";
+static char *DFLT_MOUSE_PROTO = "wsmouse";
#else
static char *DFLT_MOUSE_DEV = "/dev/mouse";
static char *DFLT_MOUSE_PROTO = "auto";
@@ -154,16 +157,6 @@ configureInputSection (void)
/* Crude mechanism to auto-detect mouse (os dependent) */
{
int fd;
-#ifdef WSCONS_SUPPORT
- fd = open("/dev/wsmouse", 0);
- if (fd >= 0) {
- DFLT_MOUSE_DEV = "/dev/wsmouse";
- DFLT_MOUSE_PROTO = "wsmouse";
- close(fd);
- } else {
- ErrorF("cannot open /dev/wsmouse\n");
- }
-#endif
fd = open(DFLT_MOUSE_DEV, 0);
if (fd != -1) {
diff --git a/xorg-server/hw/xfree86/common/xf86Events.c b/xorg-server/hw/xfree86/common/xf86Events.c
index 84c0d182a..d141ce067 100644
--- a/xorg-server/hw/xfree86/common/xf86Events.c
+++ b/xorg-server/hw/xfree86/common/xf86Events.c
@@ -1,753 +1,753 @@
-/*
- * Copyright 1990,91 by Thomas Roell, Dinkelscherben, Germany.
- *
- * Permission to use, copy, modify, distribute, and sell this software and its
- * documentation for any purpose is hereby granted without fee, provided that
- * the above copyright notice appear in all copies and that both that
- * copyright notice and this permission notice appear in supporting
- * documentation, and that the name of Thomas Roell not be used in
- * advertising or publicity pertaining to distribution of the software without
- * specific, written prior permission. Thomas Roell makes no representations
- * about the suitability of this software for any purpose. It is provided
- * "as is" without express or implied warranty.
- *
- * THOMAS ROELL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
- * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
- * EVENT SHALL THOMAS ROELL BE LIABLE FOR ANY SPECIAL, INDIRECT OR
- * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
- * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
- * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
- * PERFORMANCE OF THIS SOFTWARE.
- *
- */
-/*
- * Copyright (c) 1994-2003 by The XFree86 Project, Inc.
- *
- * 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, sublicense,
- * 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 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 NONINFRINGEMENT. IN NO EVENT SHALL
- * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) 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.
- *
- * Except as contained in this notice, the name of the copyright holder(s)
- * and author(s) shall not be used in advertising or otherwise to promote
- * the sale, use or other dealings in this Software without prior written
- * authorization from the copyright holder(s) and author(s).
- */
-
-/* [JCH-96/01/21] Extended std reverse map to four buttons. */
-
-#ifdef HAVE_XORG_CONFIG_H
-#include <xorg-config.h>
-#endif
-
-#include <X11/X.h>
-#include <X11/Xpoll.h>
-#include <X11/Xproto.h>
-#include "misc.h"
-#include "compiler.h"
-#include "xf86.h"
-#include "xf86Priv.h"
-#define XF86_OS_PRIVS
-#include "xf86_OSlib.h"
-#include <X11/keysym.h>
-
-#ifdef XFreeXDGA
-#include "dgaproc.h"
-#endif
-
-#include <X11/extensions/XI.h>
-#include <X11/extensions/XIproto.h>
-#include "inputstr.h"
-#include "xf86Xinput.h"
-
-#include "mi.h"
-#include "mipointer.h"
-
-#include "xkbsrv.h"
-#include "xkbstr.h"
-
-#ifdef DPMSExtension
-#include <X11/extensions/dpmsconst.h>
-#include "dpmsproc.h"
-#endif
-
-/*
- * This is a toggling variable:
- * FALSE = No VT switching keys have been pressed last time around
- * TRUE = Possible VT switch Pending
- * (DWH - 12/2/93)
- *
- * This has been generalised to work with Linux and *BSD+syscons (DHD)
- */
-
-Bool VTSwitchEnabled = TRUE; /* Allows run-time disabling for
- *BSD and for avoiding VT
- switches when using the DRI
- automatic full screen mode.*/
-
-extern fd_set EnabledDevices;
-
-#ifdef XF86PM
-extern void (*xf86OSPMClose)(void);
-#endif
-
-static void xf86VTSwitch(void);
-
-/*
- * Allow arbitrary drivers or other XFree86 code to register with our main
- * Wakeup handler.
- */
-typedef struct x_IHRec {
- int fd;
- InputHandlerProc ihproc;
- pointer data;
- Bool enabled;
- struct x_IHRec * next;
-} IHRec, *IHPtr;
-
-static IHPtr InputHandlers = NULL;
-
-
-Bool
-LegalModifier(unsigned int key, DeviceIntPtr pDev)
-{
- return TRUE;
-}
-
-/*
- * TimeSinceLastInputEvent --
- * Function used for screensaver purposes by the os module. Returns the
- * time in milliseconds since there last was any input.
- */
-int
-TimeSinceLastInputEvent(void)
-{
- if (xf86Info.lastEventTime == 0) {
- xf86Info.lastEventTime = GetTimeInMillis();
- }
- return GetTimeInMillis() - xf86Info.lastEventTime;
-}
-
-/*
- * SetTimeSinceLastInputEvent --
- * Set the lastEventTime to now.
- */
-void
-SetTimeSinceLastInputEvent(void)
-{
- xf86Info.lastEventTime = GetTimeInMillis();
-}
-
-/*
- * ProcessInputEvents --
- * Retrieve all waiting input events and pass them to DIX in their
- * correct chronological order. Only reads from the system pointer
- * and keyboard.
- */
-void
-ProcessInputEvents (void)
-{
- int x, y;
-
- mieqProcessInputEvents();
-
- /* FIXME: This is a problem if we have multiple pointers */
- miPointerGetPosition(inputInfo.pointer, &x, &y);
- xf86SetViewport(xf86Info.currentScreen, x, y);
-}
-
-/*
- * Handle keyboard events that cause some kind of "action"
- * (i.e., server termination, video mode changes, VT switches, etc.)
- */
-void
-xf86ProcessActionEvent(ActionEvent action, void *arg)
-{
- DebugF("ProcessActionEvent(%d,%x)\n", (int) action, arg);
- switch (action) {
- case ACTION_TERMINATE:
- if (!xf86Info.dontZap) {
-#ifdef XFreeXDGA
- DGAShutdown();
-#endif
- GiveUp(0);
- }
- break;
- case ACTION_NEXT_MODE:
- if (!xf86Info.dontZoom)
- xf86ZoomViewport(xf86Info.currentScreen, 1);
- break;
- case ACTION_PREV_MODE:
- if (!xf86Info.dontZoom)
- xf86ZoomViewport(xf86Info.currentScreen, -1);
- break;
- case ACTION_SWITCHSCREEN:
- if (VTSwitchEnabled && !xf86Info.dontVTSwitch && arg) {
- int vtno = *((int *) arg);
-
- if (vtno != xf86Info.vtno) {
- if (!xf86VTActivate(vtno)) {
- ErrorF("Failed to switch from vt%02d to vt%02d: %s\n",
- xf86Info.vtno, vtno, strerror(errno));
- }
- }
- }
- break;
- case ACTION_SWITCHSCREEN_NEXT:
- if (VTSwitchEnabled && !xf86Info.dontVTSwitch) {
- if (!xf86VTActivate(xf86Info.vtno + 1)) {
- /* If first try failed, assume this is the last VT and
- * try wrapping around to the first vt.
- */
- if (!xf86VTActivate(1)) {
- ErrorF("Failed to switch from vt%02d to next vt: %s\n",
- xf86Info.vtno, strerror(errno));
- }
- }
- }
- break;
- case ACTION_SWITCHSCREEN_PREV:
- if (VTSwitchEnabled && !xf86Info.dontVTSwitch && xf86Info.vtno > 0) {
- if (!xf86VTActivate(xf86Info.vtno - 1)) {
- /* Don't know what the maximum VT is, so can't wrap around */
- ErrorF("Failed to switch from vt%02d to previous vt: %s\n",
- xf86Info.vtno, strerror(errno));
- }
- }
- break;
- default:
- break;
- }
-}
-
-/*
- * xf86Wakeup --
- * Os wakeup handler.
- */
-
-/* ARGSUSED */
-void
-xf86Wakeup(pointer blockData, int err, pointer pReadmask)
-{
- fd_set* LastSelectMask = (fd_set*)pReadmask;
- fd_set devicesWithInput;
- InputInfoPtr pInfo;
-
- if (err >= 0) {
-
- XFD_ANDSET(&devicesWithInput, LastSelectMask, &EnabledDevices);
- if (XFD_ANYSET(&devicesWithInput)) {
- pInfo = xf86InputDevs;
- while (pInfo) {
- if (pInfo->read_input && pInfo->fd >= 0 &&
- (FD_ISSET(pInfo->fd, &devicesWithInput) != 0)) {
- int sigstate = xf86BlockSIGIO();
-
- /*
- * Remove the descriptior from the set because more than one
- * device may share the same file descriptor.
- */
- FD_CLR(pInfo->fd, &devicesWithInput);
-
- pInfo->read_input(pInfo);
- xf86UnblockSIGIO(sigstate);
- }
- pInfo = pInfo->next;
- }
- }
- }
-
- if (err >= 0) { /* we don't want the handlers called if select() */
- IHPtr ih; /* returned with an error condition, do we? */
-
- for (ih = InputHandlers; ih; ih = ih->next) {
- if (ih->enabled && ih->fd >= 0 && ih->ihproc &&
- (FD_ISSET(ih->fd, ((fd_set *)pReadmask)) != 0)) {
- ih->ihproc(ih->fd, ih->data);
- }
- }
- }
-
- if (xf86VTSwitchPending()) xf86VTSwitch();
-}
-
-
-/*
- * xf86SigioReadInput --
- * signal handler for the SIGIO signal.
- */
-static void
-xf86SigioReadInput(int fd, void *closure)
-{
- int errno_save = errno;
- InputInfoPtr pInfo = closure;
-
- pInfo->read_input(pInfo);
-
- errno = errno_save;
-}
-
-/*
- * xf86AddEnabledDevice --
- *
- */
-void
-xf86AddEnabledDevice(InputInfoPtr pInfo)
-{
- if (!xf86InstallSIGIOHandler (pInfo->fd, xf86SigioReadInput, pInfo)) {
- AddEnabledDevice(pInfo->fd);
- }
-}
-
-/*
- * xf86RemoveEnabledDevice --
- *
- */
-void
-xf86RemoveEnabledDevice(InputInfoPtr pInfo)
-{
- if (!xf86RemoveSIGIOHandler (pInfo->fd)) {
- RemoveEnabledDevice(pInfo->fd);
- }
-}
-
-static int *xf86SignalIntercept = NULL;
-
-void
-xf86InterceptSignals(int *signo)
-{
- if ((xf86SignalIntercept = signo))
- *signo = -1;
-}
-
-static void (*xf86SigIllHandler)(void) = NULL;
-
-void
-xf86InterceptSigIll(void (*sigillhandler)(void))
-{
- xf86SigIllHandler = sigillhandler;
-}
-
-/*
- * xf86SigWrapper --
- * Catch unexpected signals and exit or continue cleanly.
- */
-int
-xf86SigWrapper(int signo)
-{
- if ((signo == SIGILL) && xf86SigIllHandler) {
- (*xf86SigIllHandler)();
- return 0; /* continue */
- }
-
- if (xf86SignalIntercept && (*xf86SignalIntercept < 0)) {
- *xf86SignalIntercept = signo;
- return 0; /* continue */
- }
-
- xf86Info.caughtSignal = TRUE;
- return 1; /* abort */
-}
-
-/*
- * xf86PrintBacktrace --
- * Print a stack backtrace for debugging purposes.
- */
-void
-xf86PrintBacktrace(void)
-{
- xorg_backtrace();
-}
-
-static void
-xf86ReleaseKeys(DeviceIntPtr pDev)
-{
- KeyClassPtr keyc;
- int i, j, nevents, sigstate;
-
- if (!pDev || !pDev->key)
- return;
-
- keyc = pDev->key;
-
- /*
- * Hmm... here is the biggest hack of every time !
- * It may be possible that a switch-vt procedure has finished BEFORE
- * you released all keys neccessary to do this. That peculiar behavior
- * can fool the X-server pretty much, cause it assumes that some keys
- * were not released. TWM may stuck alsmost completly....
- * OK, what we are doing here is after returning from the vt-switch
- * exeplicitely unrelease all keyboard keys before the input-devices
- * are reenabled.
- */
-
- for (i = keyc->xkbInfo->desc->min_key_code;
- i < keyc->xkbInfo->desc->max_key_code;
- i++) {
- if (key_is_down(pDev, i, KEY_POSTED)) {
- sigstate = xf86BlockSIGIO ();
- nevents = GetKeyboardEvents(xf86Events, pDev, KeyRelease, i);
- for (j = 0; j < nevents; j++)
- mieqEnqueue(pDev, (InternalEvent*)(xf86Events + j)->event);
- xf86UnblockSIGIO(sigstate);
- }
- }
-}
-
-/*
- * xf86VTSwitch --
- * Handle requests for switching the vt.
- */
-static void
-xf86VTSwitch(void)
-{
- int i;
- static int prevSIGIO;
- InputInfoPtr pInfo;
- IHPtr ih;
-
- DebugF("xf86VTSwitch()\n");
-
-#ifdef XFreeXDGA
- if(!DGAVTSwitch())
- return;
-#endif
-
- /*
- * Since all screens are currently all in the same state it is sufficient
- * check the first. This might change in future.
- */
- if (xf86Screens[0]->vtSema) {
-
- DebugF("xf86VTSwitch: Leaving, xf86Exiting is %s\n",
- BOOLTOSTRING((dispatchException & DE_TERMINATE) ? TRUE : FALSE));
-#ifdef DPMSExtension
- if (DPMSPowerLevel != DPMSModeOn)
- DPMSSet(serverClient, DPMSModeOn);
-#endif
- for (i = 0; i < xf86NumScreens; i++) {
- if (!(dispatchException & DE_TERMINATE))
- if (xf86Screens[i]->EnableDisableFBAccess)
- (*xf86Screens[i]->EnableDisableFBAccess) (i, FALSE);
- }
-
- /*
- * Keep the order: Disable Device > LeaveVT
- * EnterVT > EnableDevice
- */
- for (ih = InputHandlers; ih; ih = ih->next)
- xf86DisableInputHandler(ih);
- for (pInfo = xf86InputDevs; pInfo; pInfo = pInfo->next) {
- if (pInfo->dev) {
- xf86ReleaseKeys(pInfo->dev);
- ProcessInputEvents();
- DisableDevice(pInfo->dev, TRUE);
- }
- }
-
- prevSIGIO = xf86BlockSIGIO();
- for (i = 0; i < xf86NumScreens; i++)
- xf86Screens[i]->LeaveVT(i, 0);
-
- xf86AccessLeave(); /* We need this here, otherwise */
-
- if (!xf86VTSwitchAway()) {
- /*
- * switch failed
- */
-
- DebugF("xf86VTSwitch: Leave failed\n");
- xf86AccessEnter();
- for (i = 0; i < xf86NumScreens; i++) {
- if (!xf86Screens[i]->EnterVT(i, 0))
- FatalError("EnterVT failed for screen %d\n", i);
- }
- if (!(dispatchException & DE_TERMINATE)) {
- for (i = 0; i < xf86NumScreens; i++) {
- if (xf86Screens[i]->EnableDisableFBAccess)
- (*xf86Screens[i]->EnableDisableFBAccess) (i, TRUE);
- }
- }
- dixSaveScreens(serverClient, SCREEN_SAVER_FORCER, ScreenSaverReset);
-
- pInfo = xf86InputDevs;
- while (pInfo) {
- if (pInfo->dev)
- EnableDevice(pInfo->dev, TRUE);
- pInfo = pInfo->next;
- }
- for (ih = InputHandlers; ih; ih = ih->next)
- xf86EnableInputHandler(ih);
-
- xf86UnblockSIGIO(prevSIGIO);
-
- } else {
-#ifdef XF86PM
- if (xf86OSPMClose)
- xf86OSPMClose();
- xf86OSPMClose = NULL;
-#endif
-
- for (i = 0; i < xf86NumScreens; i++) {
- /*
- * zero all access functions to
- * trap calls when switched away.
- */
- xf86Screens[i]->vtSema = FALSE;
- }
- if (xorgHWAccess)
- xf86DisableIO();
- }
- } else {
- DebugF("xf86VTSwitch: Entering\n");
- if (!xf86VTSwitchTo()) return;
-
-#ifdef XF86PM
- xf86OSPMClose = xf86OSPMOpen();
-#endif
-
- if (xorgHWAccess)
- xf86EnableIO();
- xf86AccessEnter();
- for (i = 0; i < xf86NumScreens; i++) {
- xf86Screens[i]->vtSema = TRUE;
- if (!xf86Screens[i]->EnterVT(i, 0))
- FatalError("EnterVT failed for screen %d\n", i);
- }
- for (i = 0; i < xf86NumScreens; i++) {
- if (xf86Screens[i]->EnableDisableFBAccess)
- (*xf86Screens[i]->EnableDisableFBAccess)(i, TRUE);
- }
-
- /* Turn screen saver off when switching back */
- dixSaveScreens(serverClient, SCREEN_SAVER_FORCER, ScreenSaverReset);
-
- pInfo = xf86InputDevs;
- while (pInfo) {
- if (pInfo->dev)
- EnableDevice(pInfo->dev, TRUE);
- pInfo = pInfo->next;
- }
-
- for (ih = InputHandlers; ih; ih = ih->next)
- xf86EnableInputHandler(ih);
-
- xf86UnblockSIGIO(prevSIGIO);
- }
-}
-
-
-/* Input handler registration */
-
-static pointer
-addInputHandler(int fd, InputHandlerProc proc, pointer data)
-{
- IHPtr ih;
-
- if (fd < 0 || !proc)
- return NULL;
-
- ih = calloc(sizeof(*ih), 1);
- if (!ih)
- return NULL;
-
- ih->fd = fd;
- ih->ihproc = proc;
- ih->data = data;
- ih->enabled = TRUE;
-
- ih->next = InputHandlers;
- InputHandlers = ih;
-
- return ih;
-}
-
-pointer
-xf86AddInputHandler(int fd, InputHandlerProc proc, pointer data)
-{
- IHPtr ih = addInputHandler(fd, proc, data);
-
- if (ih)
- AddEnabledDevice(fd);
- return ih;
-}
-
-pointer
-xf86AddGeneralHandler(int fd, InputHandlerProc proc, pointer data)
-{
- IHPtr ih = addInputHandler(fd, proc, data);
-
- if (ih)
- AddGeneralSocket(fd);
- return ih;
-}
-
-/**
- * Set the handler for the console's fd. Replaces (and returns) the previous
- * handler or NULL, whichever appropriate.
- * proc may be NULL if the server should not handle events on the console.
- */
-InputHandlerProc
-xf86SetConsoleHandler(InputHandlerProc proc, pointer data)
-{
- static InputHandlerProc handler = NULL;
- InputHandlerProc old_handler = handler;
-
- if (old_handler)
- xf86RemoveGeneralHandler(old_handler);
-
- xf86AddGeneralHandler(xf86Info.consoleFd, proc, data);
- handler = proc;
-
- return old_handler;
-}
-
-static void
-removeInputHandler(IHPtr ih)
-{
- IHPtr p;
-
- if (ih == InputHandlers)
- InputHandlers = ih->next;
- else {
- p = InputHandlers;
- while (p && p->next != ih)
- p = p->next;
- if (ih)
- p->next = ih->next;
- }
- free(ih);
-}
-
-int
-xf86RemoveInputHandler(pointer handler)
-{
- IHPtr ih;
- int fd;
-
- if (!handler)
- return -1;
-
- ih = handler;
- fd = ih->fd;
-
- if (ih->fd >= 0)
- RemoveEnabledDevice(ih->fd);
- removeInputHandler(ih);
-
- return fd;
-}
-
-int
-xf86RemoveGeneralHandler(pointer handler)
-{
- IHPtr ih;
- int fd;
-
- if (!handler)
- return -1;
-
- ih = handler;
- fd = ih->fd;
-
- if (ih->fd >= 0)
- RemoveGeneralSocket(ih->fd);
- removeInputHandler(ih);
-
- return fd;
-}
-
-void
-xf86DisableInputHandler(pointer handler)
-{
- IHPtr ih;
-
- if (!handler)
- return;
-
- ih = handler;
- ih->enabled = FALSE;
- if (ih->fd >= 0)
- RemoveEnabledDevice(ih->fd);
-}
-
-void
-xf86DisableGeneralHandler(pointer handler)
-{
- IHPtr ih;
-
- if (!handler)
- return;
-
- ih = handler;
- ih->enabled = FALSE;
- if (ih->fd >= 0)
- RemoveGeneralSocket(ih->fd);
-}
-
-void
-xf86EnableInputHandler(pointer handler)
-{
- IHPtr ih;
-
- if (!handler)
- return;
-
- ih = handler;
- ih->enabled = TRUE;
- if (ih->fd >= 0)
- AddEnabledDevice(ih->fd);
-}
-
-void
-xf86EnableGeneralHandler(pointer handler)
-{
- IHPtr ih;
-
- if (!handler)
- return;
-
- ih = handler;
- ih->enabled = TRUE;
- if (ih->fd >= 0)
- AddGeneralSocket(ih->fd);
-}
-
-/*
- * As used currently by the DRI, the return value is ignored.
- */
-Bool
-xf86EnableVTSwitch(Bool new)
-{
- static Bool def = TRUE;
- Bool old;
-
- old = VTSwitchEnabled;
- if (!new) {
- /* Disable VT switching */
- def = VTSwitchEnabled;
- VTSwitchEnabled = FALSE;
- } else {
- /* Restore VT switching to default */
- VTSwitchEnabled = def;
- }
- return old;
-}
-
-void
-DDXRingBell(int volume, int pitch, int duration) {
- xf86OSRingBell(volume, pitch, duration);
-}
+/*
+ * Copyright 1990,91 by Thomas Roell, Dinkelscherben, Germany.
+ *
+ * Permission to use, copy, modify, distribute, and sell this software and its
+ * documentation for any purpose is hereby granted without fee, provided that
+ * the above copyright notice appear in all copies and that both that
+ * copyright notice and this permission notice appear in supporting
+ * documentation, and that the name of Thomas Roell not be used in
+ * advertising or publicity pertaining to distribution of the software without
+ * specific, written prior permission. Thomas Roell makes no representations
+ * about the suitability of this software for any purpose. It is provided
+ * "as is" without express or implied warranty.
+ *
+ * THOMAS ROELL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
+ * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
+ * EVENT SHALL THOMAS ROELL BE LIABLE FOR ANY SPECIAL, INDIRECT OR
+ * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
+ * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
+ * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
+ * PERFORMANCE OF THIS SOFTWARE.
+ *
+ */
+/*
+ * Copyright (c) 1994-2003 by The XFree86 Project, Inc.
+ *
+ * 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, sublicense,
+ * 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 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 NONINFRINGEMENT. IN NO EVENT SHALL
+ * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) 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.
+ *
+ * Except as contained in this notice, the name of the copyright holder(s)
+ * and author(s) shall not be used in advertising or otherwise to promote
+ * the sale, use or other dealings in this Software without prior written
+ * authorization from the copyright holder(s) and author(s).
+ */
+
+/* [JCH-96/01/21] Extended std reverse map to four buttons. */
+
+#ifdef HAVE_XORG_CONFIG_H
+#include <xorg-config.h>
+#endif
+
+#include <X11/X.h>
+#include <X11/Xpoll.h>
+#include <X11/Xproto.h>
+#include "misc.h"
+#include "compiler.h"
+#include "xf86.h"
+#include "xf86Priv.h"
+#define XF86_OS_PRIVS
+#include "xf86_OSlib.h"
+#include <X11/keysym.h>
+
+#ifdef XFreeXDGA
+#include "dgaproc.h"
+#endif
+
+#include <X11/extensions/XI.h>
+#include <X11/extensions/XIproto.h>
+#include "inputstr.h"
+#include "xf86Xinput.h"
+
+#include "mi.h"
+#include "mipointer.h"
+
+#include "xkbsrv.h"
+#include "xkbstr.h"
+
+#ifdef DPMSExtension
+#include <X11/extensions/dpmsconst.h>
+#include "dpmsproc.h"
+#endif
+
+/*
+ * This is a toggling variable:
+ * FALSE = No VT switching keys have been pressed last time around
+ * TRUE = Possible VT switch Pending
+ * (DWH - 12/2/93)
+ *
+ * This has been generalised to work with Linux and *BSD+syscons (DHD)
+ */
+
+Bool VTSwitchEnabled = TRUE; /* Allows run-time disabling for
+ *BSD and for avoiding VT
+ switches when using the DRI
+ automatic full screen mode.*/
+
+extern fd_set EnabledDevices;
+
+#ifdef XF86PM
+extern void (*xf86OSPMClose)(void);
+#endif
+
+static void xf86VTSwitch(void);
+
+/*
+ * Allow arbitrary drivers or other XFree86 code to register with our main
+ * Wakeup handler.
+ */
+typedef struct x_IHRec {
+ int fd;
+ InputHandlerProc ihproc;
+ pointer data;
+ Bool enabled;
+ struct x_IHRec * next;
+} IHRec, *IHPtr;
+
+static IHPtr InputHandlers = NULL;
+
+
+Bool
+LegalModifier(unsigned int key, DeviceIntPtr pDev)
+{
+ return TRUE;
+}
+
+/*
+ * TimeSinceLastInputEvent --
+ * Function used for screensaver purposes by the os module. Returns the
+ * time in milliseconds since there last was any input.
+ */
+int
+TimeSinceLastInputEvent(void)
+{
+ if (xf86Info.lastEventTime == 0) {
+ xf86Info.lastEventTime = GetTimeInMillis();
+ }
+ return GetTimeInMillis() - xf86Info.lastEventTime;
+}
+
+/*
+ * SetTimeSinceLastInputEvent --
+ * Set the lastEventTime to now.
+ */
+void
+SetTimeSinceLastInputEvent(void)
+{
+ xf86Info.lastEventTime = GetTimeInMillis();
+}
+
+/*
+ * ProcessInputEvents --
+ * Retrieve all waiting input events and pass them to DIX in their
+ * correct chronological order. Only reads from the system pointer
+ * and keyboard.
+ */
+void
+ProcessInputEvents (void)
+{
+ int x, y;
+
+ mieqProcessInputEvents();
+
+ /* FIXME: This is a problem if we have multiple pointers */
+ miPointerGetPosition(inputInfo.pointer, &x, &y);
+ xf86SetViewport(xf86Info.currentScreen, x, y);
+}
+
+/*
+ * Handle keyboard events that cause some kind of "action"
+ * (i.e., server termination, video mode changes, VT switches, etc.)
+ */
+void
+xf86ProcessActionEvent(ActionEvent action, void *arg)
+{
+ DebugF("ProcessActionEvent(%d,%x)\n", (int) action, arg);
+ switch (action) {
+ case ACTION_TERMINATE:
+ if (!xf86Info.dontZap) {
+#ifdef XFreeXDGA
+ DGAShutdown();
+#endif
+ GiveUp(0);
+ }
+ break;
+ case ACTION_NEXT_MODE:
+ if (!xf86Info.dontZoom)
+ xf86ZoomViewport(xf86Info.currentScreen, 1);
+ break;
+ case ACTION_PREV_MODE:
+ if (!xf86Info.dontZoom)
+ xf86ZoomViewport(xf86Info.currentScreen, -1);
+ break;
+ case ACTION_SWITCHSCREEN:
+ if (VTSwitchEnabled && !xf86Info.dontVTSwitch && arg) {
+ int vtno = *((int *) arg);
+
+ if (vtno != xf86Info.vtno) {
+ if (!xf86VTActivate(vtno)) {
+ ErrorF("Failed to switch from vt%02d to vt%02d: %s\n",
+ xf86Info.vtno, vtno, strerror(errno));
+ }
+ }
+ }
+ break;
+ case ACTION_SWITCHSCREEN_NEXT:
+ if (VTSwitchEnabled && !xf86Info.dontVTSwitch) {
+ if (!xf86VTActivate(xf86Info.vtno + 1)) {
+ /* If first try failed, assume this is the last VT and
+ * try wrapping around to the first vt.
+ */
+ if (!xf86VTActivate(1)) {
+ ErrorF("Failed to switch from vt%02d to next vt: %s\n",
+ xf86Info.vtno, strerror(errno));
+ }
+ }
+ }
+ break;
+ case ACTION_SWITCHSCREEN_PREV:
+ if (VTSwitchEnabled && !xf86Info.dontVTSwitch && xf86Info.vtno > 0) {
+ if (!xf86VTActivate(xf86Info.vtno - 1)) {
+ /* Don't know what the maximum VT is, so can't wrap around */
+ ErrorF("Failed to switch from vt%02d to previous vt: %s\n",
+ xf86Info.vtno, strerror(errno));
+ }
+ }
+ break;
+ default:
+ break;
+ }
+}
+
+/*
+ * xf86Wakeup --
+ * Os wakeup handler.
+ */
+
+/* ARGSUSED */
+void
+xf86Wakeup(pointer blockData, int err, pointer pReadmask)
+{
+ fd_set* LastSelectMask = (fd_set*)pReadmask;
+ fd_set devicesWithInput;
+ InputInfoPtr pInfo;
+
+ if (err >= 0) {
+
+ XFD_ANDSET(&devicesWithInput, LastSelectMask, &EnabledDevices);
+ if (XFD_ANYSET(&devicesWithInput)) {
+ pInfo = xf86InputDevs;
+ while (pInfo) {
+ if (pInfo->read_input && pInfo->fd >= 0 &&
+ (FD_ISSET(pInfo->fd, &devicesWithInput) != 0)) {
+ int sigstate = xf86BlockSIGIO();
+
+ /*
+ * Remove the descriptior from the set because more than one
+ * device may share the same file descriptor.
+ */
+ FD_CLR(pInfo->fd, &devicesWithInput);
+
+ pInfo->read_input(pInfo);
+ xf86UnblockSIGIO(sigstate);
+ }
+ pInfo = pInfo->next;
+ }
+ }
+ }
+
+ if (err >= 0) { /* we don't want the handlers called if select() */
+ IHPtr ih; /* returned with an error condition, do we? */
+
+ for (ih = InputHandlers; ih; ih = ih->next) {
+ if (ih->enabled && ih->fd >= 0 && ih->ihproc &&
+ (FD_ISSET(ih->fd, ((fd_set *)pReadmask)) != 0)) {
+ ih->ihproc(ih->fd, ih->data);
+ }
+ }
+ }
+
+ if (xf86VTSwitchPending()) xf86VTSwitch();
+}
+
+
+/*
+ * xf86SigioReadInput --
+ * signal handler for the SIGIO signal.
+ */
+static void
+xf86SigioReadInput(int fd, void *closure)
+{
+ int errno_save = errno;
+ InputInfoPtr pInfo = closure;
+
+ pInfo->read_input(pInfo);
+
+ errno = errno_save;
+}
+
+/*
+ * xf86AddEnabledDevice --
+ *
+ */
+void
+xf86AddEnabledDevice(InputInfoPtr pInfo)
+{
+ if (!xf86InstallSIGIOHandler (pInfo->fd, xf86SigioReadInput, pInfo)) {
+ AddEnabledDevice(pInfo->fd);
+ }
+}
+
+/*
+ * xf86RemoveEnabledDevice --
+ *
+ */
+void
+xf86RemoveEnabledDevice(InputInfoPtr pInfo)
+{
+ if (!xf86RemoveSIGIOHandler (pInfo->fd)) {
+ RemoveEnabledDevice(pInfo->fd);
+ }
+}
+
+static int *xf86SignalIntercept = NULL;
+
+void
+xf86InterceptSignals(int *signo)
+{
+ if ((xf86SignalIntercept = signo))
+ *signo = -1;
+}
+
+static void (*xf86SigIllHandler)(void) = NULL;
+
+void
+xf86InterceptSigIll(void (*sigillhandler)(void))
+{
+ xf86SigIllHandler = sigillhandler;
+}
+
+/*
+ * xf86SigWrapper --
+ * Catch unexpected signals and exit or continue cleanly.
+ */
+int
+xf86SigWrapper(int signo)
+{
+ if ((signo == SIGILL) && xf86SigIllHandler) {
+ (*xf86SigIllHandler)();
+ return 0; /* continue */
+ }
+
+ if (xf86SignalIntercept && (*xf86SignalIntercept < 0)) {
+ *xf86SignalIntercept = signo;
+ return 0; /* continue */
+ }
+
+ xf86Info.caughtSignal = TRUE;
+ return 1; /* abort */
+}
+
+/*
+ * xf86PrintBacktrace --
+ * Print a stack backtrace for debugging purposes.
+ */
+void
+xf86PrintBacktrace(void)
+{
+ xorg_backtrace();
+}
+
+static void
+xf86ReleaseKeys(DeviceIntPtr pDev)
+{
+ KeyClassPtr keyc;
+ int i, j, nevents, sigstate;
+
+ if (!pDev || !pDev->key)
+ return;
+
+ keyc = pDev->key;
+
+ /*
+ * Hmm... here is the biggest hack of every time !
+ * It may be possible that a switch-vt procedure has finished BEFORE
+ * you released all keys neccessary to do this. That peculiar behavior
+ * can fool the X-server pretty much, cause it assumes that some keys
+ * were not released. TWM may stuck alsmost completly....
+ * OK, what we are doing here is after returning from the vt-switch
+ * exeplicitely unrelease all keyboard keys before the input-devices
+ * are reenabled.
+ */
+
+ for (i = keyc->xkbInfo->desc->min_key_code;
+ i < keyc->xkbInfo->desc->max_key_code;
+ i++) {
+ if (key_is_down(pDev, i, KEY_POSTED)) {
+ sigstate = xf86BlockSIGIO ();
+ nevents = GetKeyboardEvents(xf86Events, pDev, KeyRelease, i, NULL);
+ for (j = 0; j < nevents; j++)
+ mieqEnqueue(pDev, (InternalEvent*)(xf86Events + j)->event);
+ xf86UnblockSIGIO(sigstate);
+ }
+ }
+}
+
+/*
+ * xf86VTSwitch --
+ * Handle requests for switching the vt.
+ */
+static void
+xf86VTSwitch(void)
+{
+ int i;
+ static int prevSIGIO;
+ InputInfoPtr pInfo;
+ IHPtr ih;
+
+ DebugF("xf86VTSwitch()\n");
+
+#ifdef XFreeXDGA
+ if(!DGAVTSwitch())
+ return;
+#endif
+
+ /*
+ * Since all screens are currently all in the same state it is sufficient
+ * check the first. This might change in future.
+ */
+ if (xf86Screens[0]->vtSema) {
+
+ DebugF("xf86VTSwitch: Leaving, xf86Exiting is %s\n",
+ BOOLTOSTRING((dispatchException & DE_TERMINATE) ? TRUE : FALSE));
+#ifdef DPMSExtension
+ if (DPMSPowerLevel != DPMSModeOn)
+ DPMSSet(serverClient, DPMSModeOn);
+#endif
+ for (i = 0; i < xf86NumScreens; i++) {
+ if (!(dispatchException & DE_TERMINATE))
+ if (xf86Screens[i]->EnableDisableFBAccess)
+ (*xf86Screens[i]->EnableDisableFBAccess) (i, FALSE);
+ }
+
+ /*
+ * Keep the order: Disable Device > LeaveVT
+ * EnterVT > EnableDevice
+ */
+ for (ih = InputHandlers; ih; ih = ih->next)
+ xf86DisableInputHandler(ih);
+ for (pInfo = xf86InputDevs; pInfo; pInfo = pInfo->next) {
+ if (pInfo->dev) {
+ xf86ReleaseKeys(pInfo->dev);
+ ProcessInputEvents();
+ DisableDevice(pInfo->dev, TRUE);
+ }
+ }
+
+ prevSIGIO = xf86BlockSIGIO();
+ for (i = 0; i < xf86NumScreens; i++)
+ xf86Screens[i]->LeaveVT(i, 0);
+
+ xf86AccessLeave(); /* We need this here, otherwise */
+
+ if (!xf86VTSwitchAway()) {
+ /*
+ * switch failed
+ */
+
+ DebugF("xf86VTSwitch: Leave failed\n");
+ xf86AccessEnter();
+ for (i = 0; i < xf86NumScreens; i++) {
+ if (!xf86Screens[i]->EnterVT(i, 0))
+ FatalError("EnterVT failed for screen %d\n", i);
+ }
+ if (!(dispatchException & DE_TERMINATE)) {
+ for (i = 0; i < xf86NumScreens; i++) {
+ if (xf86Screens[i]->EnableDisableFBAccess)
+ (*xf86Screens[i]->EnableDisableFBAccess) (i, TRUE);
+ }
+ }
+ dixSaveScreens(serverClient, SCREEN_SAVER_FORCER, ScreenSaverReset);
+
+ pInfo = xf86InputDevs;
+ while (pInfo) {
+ if (pInfo->dev)
+ EnableDevice(pInfo->dev, TRUE);
+ pInfo = pInfo->next;
+ }
+ for (ih = InputHandlers; ih; ih = ih->next)
+ xf86EnableInputHandler(ih);
+
+ xf86UnblockSIGIO(prevSIGIO);
+
+ } else {
+#ifdef XF86PM
+ if (xf86OSPMClose)
+ xf86OSPMClose();
+ xf86OSPMClose = NULL;
+#endif
+
+ for (i = 0; i < xf86NumScreens; i++) {
+ /*
+ * zero all access functions to
+ * trap calls when switched away.
+ */
+ xf86Screens[i]->vtSema = FALSE;
+ }
+ if (xorgHWAccess)
+ xf86DisableIO();
+ }
+ } else {
+ DebugF("xf86VTSwitch: Entering\n");
+ if (!xf86VTSwitchTo()) return;
+
+#ifdef XF86PM
+ xf86OSPMClose = xf86OSPMOpen();
+#endif
+
+ if (xorgHWAccess)
+ xf86EnableIO();
+ xf86AccessEnter();
+ for (i = 0; i < xf86NumScreens; i++) {
+ xf86Screens[i]->vtSema = TRUE;
+ if (!xf86Screens[i]->EnterVT(i, 0))
+ FatalError("EnterVT failed for screen %d\n", i);
+ }
+ for (i = 0; i < xf86NumScreens; i++) {
+ if (xf86Screens[i]->EnableDisableFBAccess)
+ (*xf86Screens[i]->EnableDisableFBAccess)(i, TRUE);
+ }
+
+ /* Turn screen saver off when switching back */
+ dixSaveScreens(serverClient, SCREEN_SAVER_FORCER, ScreenSaverReset);
+
+ pInfo = xf86InputDevs;
+ while (pInfo) {
+ if (pInfo->dev)
+ EnableDevice(pInfo->dev, TRUE);
+ pInfo = pInfo->next;
+ }
+
+ for (ih = InputHandlers; ih; ih = ih->next)
+ xf86EnableInputHandler(ih);
+
+ xf86UnblockSIGIO(prevSIGIO);
+ }
+}
+
+
+/* Input handler registration */
+
+static pointer
+addInputHandler(int fd, InputHandlerProc proc, pointer data)
+{
+ IHPtr ih;
+
+ if (fd < 0 || !proc)
+ return NULL;
+
+ ih = calloc(sizeof(*ih), 1);
+ if (!ih)
+ return NULL;
+
+ ih->fd = fd;
+ ih->ihproc = proc;
+ ih->data = data;
+ ih->enabled = TRUE;
+
+ ih->next = InputHandlers;
+ InputHandlers = ih;
+
+ return ih;
+}
+
+pointer
+xf86AddInputHandler(int fd, InputHandlerProc proc, pointer data)
+{
+ IHPtr ih = addInputHandler(fd, proc, data);
+
+ if (ih)
+ AddEnabledDevice(fd);
+ return ih;
+}
+
+pointer
+xf86AddGeneralHandler(int fd, InputHandlerProc proc, pointer data)
+{
+ IHPtr ih = addInputHandler(fd, proc, data);
+
+ if (ih)
+ AddGeneralSocket(fd);
+ return ih;
+}
+
+/**
+ * Set the handler for the console's fd. Replaces (and returns) the previous
+ * handler or NULL, whichever appropriate.
+ * proc may be NULL if the server should not handle events on the console.
+ */
+InputHandlerProc
+xf86SetConsoleHandler(InputHandlerProc proc, pointer data)
+{
+ static InputHandlerProc handler = NULL;
+ InputHandlerProc old_handler = handler;
+
+ if (old_handler)
+ xf86RemoveGeneralHandler(old_handler);
+
+ xf86AddGeneralHandler(xf86Info.consoleFd, proc, data);
+ handler = proc;
+
+ return old_handler;
+}
+
+static void
+removeInputHandler(IHPtr ih)
+{
+ IHPtr p;
+
+ if (ih == InputHandlers)
+ InputHandlers = ih->next;
+ else {
+ p = InputHandlers;
+ while (p && p->next != ih)
+ p = p->next;
+ if (ih)
+ p->next = ih->next;
+ }
+ free(ih);
+}
+
+int
+xf86RemoveInputHandler(pointer handler)
+{
+ IHPtr ih;
+ int fd;
+
+ if (!handler)
+ return -1;
+
+ ih = handler;
+ fd = ih->fd;
+
+ if (ih->fd >= 0)
+ RemoveEnabledDevice(ih->fd);
+ removeInputHandler(ih);
+
+ return fd;
+}
+
+int
+xf86RemoveGeneralHandler(pointer handler)
+{
+ IHPtr ih;
+ int fd;
+
+ if (!handler)
+ return -1;
+
+ ih = handler;
+ fd = ih->fd;
+
+ if (ih->fd >= 0)
+ RemoveGeneralSocket(ih->fd);
+ removeInputHandler(ih);
+
+ return fd;
+}
+
+void
+xf86DisableInputHandler(pointer handler)
+{
+ IHPtr ih;
+
+ if (!handler)
+ return;
+
+ ih = handler;
+ ih->enabled = FALSE;
+ if (ih->fd >= 0)
+ RemoveEnabledDevice(ih->fd);
+}
+
+void
+xf86DisableGeneralHandler(pointer handler)
+{
+ IHPtr ih;
+
+ if (!handler)
+ return;
+
+ ih = handler;
+ ih->enabled = FALSE;
+ if (ih->fd >= 0)
+ RemoveGeneralSocket(ih->fd);
+}
+
+void
+xf86EnableInputHandler(pointer handler)
+{
+ IHPtr ih;
+
+ if (!handler)
+ return;
+
+ ih = handler;
+ ih->enabled = TRUE;
+ if (ih->fd >= 0)
+ AddEnabledDevice(ih->fd);
+}
+
+void
+xf86EnableGeneralHandler(pointer handler)
+{
+ IHPtr ih;
+
+ if (!handler)
+ return;
+
+ ih = handler;
+ ih->enabled = TRUE;
+ if (ih->fd >= 0)
+ AddGeneralSocket(ih->fd);
+}
+
+/*
+ * As used currently by the DRI, the return value is ignored.
+ */
+Bool
+xf86EnableVTSwitch(Bool new)
+{
+ static Bool def = TRUE;
+ Bool old;
+
+ old = VTSwitchEnabled;
+ if (!new) {
+ /* Disable VT switching */
+ def = VTSwitchEnabled;
+ VTSwitchEnabled = FALSE;
+ } else {
+ /* Restore VT switching to default */
+ VTSwitchEnabled = def;
+ }
+ return old;
+}
+
+void
+DDXRingBell(int volume, int pitch, int duration) {
+ xf86OSRingBell(volume, pitch, duration);
+}
diff --git a/xorg-server/hw/xfree86/common/xf86Xinput.c b/xorg-server/hw/xfree86/common/xf86Xinput.c
index d3af0c0c2..8356f79f8 100644
--- a/xorg-server/hw/xfree86/common/xf86Xinput.c
+++ b/xorg-server/hw/xfree86/common/xf86Xinput.c
@@ -1013,7 +1013,6 @@ xf86PostMotionEventM(DeviceIntPtr device,
const ValuatorMask *mask)
{
int i = 0, nevents = 0;
- DeviceEvent *event;
int flags = 0;
if (valuator_mask_num_valuators(mask) > 0)
@@ -1054,7 +1053,6 @@ xf86PostMotionEventM(DeviceIntPtr device,
nevents = GetPointerEvents(xf86Events, device, MotionNotify, 0, flags, mask);
for (i = 0; i < nevents; i++) {
- event = (DeviceEvent*)((xf86Events + i)->event);
mieqEnqueue(device, (InternalEvent*)((xf86Events + i)->event));
}
}
@@ -1252,16 +1250,9 @@ xf86PostKeyEventM(DeviceIntPtr device,
}
#endif
- if (is_absolute) {
- nevents = GetKeyboardValuatorEvents(xf86Events, device,
- is_down ? KeyPress : KeyRelease,
- key_code, mask);
- }
- else {
- nevents = GetKeyboardEvents(xf86Events, device,
- is_down ? KeyPress : KeyRelease,
- key_code);
- }
+ nevents = GetKeyboardEvents(xf86Events, device,
+ is_down ? KeyPress : KeyRelease,
+ key_code, mask);
for (i = 0; i < nevents; i++)
mieqEnqueue(device, (InternalEvent*)((xf86Events + i)->event));
diff --git a/xorg-server/hw/xfree86/os-support/linux/lnx_init.c b/xorg-server/hw/xfree86/os-support/linux/lnx_init.c
index d1f29d909..647c05c3a 100644
--- a/xorg-server/hw/xfree86/os-support/linux/lnx_init.c
+++ b/xorg-server/hw/xfree86/os-support/linux/lnx_init.c
@@ -62,17 +62,21 @@ drain_console(int fd, void *closure)
static void
switch_to(int vt, const char *from)
{
- if (ioctl(xf86Info.consoleFd, VT_ACTIVATE, vt) < 0)
- FatalError("%s: VT_ACTIVATE failed: %s\n", from, strerror(errno));
+ int ret;
- if (ioctl(xf86Info.consoleFd, VT_WAITACTIVE, vt) < 0)
- FatalError("%s: VT_WAITACTIVE failed: %s\n", from, strerror(errno));
+ SYSCALL(ret = ioctl(xf86Info.consoleFd, VT_ACTIVATE, vt));
+ if (ret < 0)
+ FatalError("%s: VT_ACTIVATE failed: %s\n", from, strerror(errno));
+
+ SYSCALL(ret = ioctl(xf86Info.consoleFd, VT_WAITACTIVE, vt));
+ if (ret < 0)
+ FatalError("%s: VT_WAITACTIVE failed: %s\n", from, strerror(errno));
}
void
xf86OpenConsole(void)
{
- int i, fd = -1;
+ int i, fd = -1, ret;
struct vt_mode VT;
struct vt_stat vts;
MessageType from = X_PROBED;
@@ -107,17 +111,19 @@ xf86OpenConsole(void)
if (ShareVTs)
{
- if (ioctl(fd, VT_GETSTATE, &vts) == 0)
- xf86Info.vtno = vts.v_active;
- else
- FatalError("xf86OpenConsole: Cannot find the current"
- " VT (%s)\n", strerror(errno));
+ SYSCALL(ret = ioctl(fd, VT_GETSTATE, &vts));
+ if (ret < 0)
+ FatalError("xf86OpenConsole: Cannot find the current"
+ " VT (%s)\n", strerror(errno));
+ xf86Info.vtno = vts.v_active;
} else {
- if ((ioctl(fd, VT_OPENQRY, &xf86Info.vtno) < 0) ||
- (xf86Info.vtno == -1))
- FatalError("xf86OpenConsole: Cannot find a free VT: %s\n",
- strerror(errno));
- }
+ SYSCALL(ret = ioctl(fd, VT_OPENQRY, &xf86Info.vtno));
+ if (ret < 0)
+ FatalError("xf86OpenConsole: Cannot find a free VT: "
+ "%s\n", strerror(errno));
+ if (xf86Info.vtno == -1)
+ FatalError("xf86OpenConsole: Cannot find a free VT\n");
+ }
close(fd);
}
@@ -159,7 +165,8 @@ xf86OpenConsole(void)
* Linux doesn't switch to an active vt after the last close of a vt,
* so we do this ourselves by remembering which is active now.
*/
- if (ioctl(xf86Info.consoleFd, VT_GETSTATE, &vts) < 0)
+ SYSCALL(ret = ioctl(xf86Info.consoleFd, VT_GETSTATE, &vts));
+ if (ret < 0)
xf86Msg(X_WARNING,"xf86OpenConsole: VT_GETSTATE failed: %s\n",
strerror(errno));
else
@@ -171,7 +178,7 @@ xf86OpenConsole(void)
* Detach from the controlling tty to avoid char loss
*/
if ((i = open("/dev/tty",O_RDWR)) >= 0) {
- ioctl(i, TIOCNOTTY, 0);
+ SYSCALL(ioctl(i, TIOCNOTTY, 0));
close(i);
}
}
@@ -186,9 +193,10 @@ xf86OpenConsole(void)
*/
switch_to(xf86Info.vtno, "xf86OpenConsole");
- if (ioctl(xf86Info.consoleFd, VT_GETMODE, &VT) < 0)
- FatalError("xf86OpenConsole: VT_GETMODE failed %s\n",
- strerror(errno));
+ SYSCALL(ret = ioctl(xf86Info.consoleFd, VT_GETMODE, &VT));
+ if (ret < 0)
+ FatalError("xf86OpenConsole: VT_GETMODE failed %s\n",
+ strerror(errno));
signal(SIGUSR1, xf86VTRequest);
@@ -196,20 +204,23 @@ xf86OpenConsole(void)
VT.relsig = SIGUSR1;
VT.acqsig = SIGUSR1;
- if (ioctl(xf86Info.consoleFd, VT_SETMODE, &VT) < 0)
- FatalError("xf86OpenConsole: VT_SETMODE VT_PROCESS failed: %s\n",
+ SYSCALL(ret = ioctl(xf86Info.consoleFd, VT_SETMODE, &VT));
+ if (ret < 0)
+ FatalError("xf86OpenConsole: VT_SETMODE VT_PROCESS failed: %s\n",
strerror(errno));
-
- if (ioctl(xf86Info.consoleFd, KDSETMODE, KD_GRAPHICS) < 0)
- FatalError("xf86OpenConsole: KDSETMODE KD_GRAPHICS failed %s\n",
- strerror(errno));
+
+ SYSCALL(ret = ioctl(xf86Info.consoleFd, KDSETMODE, KD_GRAPHICS));
+ if (ret < 0)
+ FatalError("xf86OpenConsole: KDSETMODE KD_GRAPHICS failed %s\n",
+ strerror(errno));
tcgetattr(xf86Info.consoleFd, &tty_attr);
- ioctl(xf86Info.consoleFd, KDGKBMODE, &tty_mode);
+ SYSCALL(ioctl(xf86Info.consoleFd, KDGKBMODE, &tty_mode));
- if (ioctl(xf86Info.consoleFd, KDSKBMODE, K_RAW) < 0)
- FatalError("xf86OpenConsole: KDSKBMODE K_RAW failed %s\n",
- strerror(errno));
+ SYSCALL(ret = ioctl(xf86Info.consoleFd, KDSKBMODE, K_RAW));
+ if (ret < 0)
+ FatalError("xf86OpenConsole: KDSKBMODE K_RAW failed %s\n",
+ strerror(errno));
nTty = tty_attr;
nTty.c_iflag = (IGNPAR | IGNBRK) & (~PARMRK) & (~ISTRIP);
@@ -241,6 +252,7 @@ void
xf86CloseConsole(void)
{
struct vt_mode VT;
+ int ret;
if (ShareVTs) {
close(xf86Info.consoleFd);
@@ -253,20 +265,23 @@ xf86CloseConsole(void)
};
/* Back to text mode ... */
- if (ioctl(xf86Info.consoleFd, KDSETMODE, KD_TEXT) < 0)
+ SYSCALL(ret = ioctl(xf86Info.consoleFd, KDSETMODE, KD_TEXT));
+ if (ret < 0)
xf86Msg(X_WARNING, "xf86CloseConsole: KDSETMODE failed: %s\n",
strerror(errno));
- ioctl(xf86Info.consoleFd, KDSKBMODE, tty_mode);
+ SYSCALL(ioctl(xf86Info.consoleFd, KDSKBMODE, tty_mode));
tcsetattr(xf86Info.consoleFd, TCSANOW, &tty_attr);
- if (ioctl(xf86Info.consoleFd, VT_GETMODE, &VT) < 0)
+ SYSCALL(ret = ioctl(xf86Info.consoleFd, VT_GETMODE, &VT));
+ if (ret < 0)
xf86Msg(X_WARNING, "xf86CloseConsole: VT_GETMODE failed: %s\n",
strerror(errno));
else {
/* set dflt vt handling */
VT.mode = VT_AUTO;
- if (ioctl(xf86Info.consoleFd, VT_SETMODE, &VT) < 0)
+ SYSCALL(ret = ioctl(xf86Info.consoleFd, VT_SETMODE, &VT));
+ if (ret < 0)
xf86Msg(X_WARNING, "xf86CloseConsole: VT_SETMODE failed: %s\n",
strerror(errno));
}
diff --git a/xorg-server/hw/xnest/Events.c b/xorg-server/hw/xnest/Events.c
index 6b8edf143..4e3fe86d1 100644
--- a/xorg-server/hw/xnest/Events.c
+++ b/xorg-server/hw/xnest/Events.c
@@ -108,7 +108,7 @@ xnestQueueKeyEvent(int type, unsigned int keycode)
GetEventList(&xnestEvents);
lastEventTime = GetTimeInMillis();
- n = GetKeyboardEvents(xnestEvents, xnestKeyboardDevice, type, keycode);
+ n = GetKeyboardEvents(xnestEvents, xnestKeyboardDevice, type, keycode, NULL);
for (i = 0; i < n; i++)
mieqEnqueue(xnestKeyboardDevice, (InternalEvent*)(xnestEvents + i)->event);
}
diff --git a/xorg-server/hw/xquartz/X11Application.m b/xorg-server/hw/xquartz/X11Application.m
index 2dd3bd36c..9c2857228 100644
--- a/xorg-server/hw/xquartz/X11Application.m
+++ b/xorg-server/hw/xquartz/X11Application.m
@@ -61,6 +61,12 @@ extern int xpbproxy_run (void);
#define XSERVER_VERSION "?"
#endif
+#ifdef HAVE_LIBDISPATCH
+#include <dispatch/dispatch.h>
+
+static dispatch_queue_t eventTranslationQueue;
+#endif
+
/* Stuck modifier / button state... force release when we context switch */
static NSEventType keyState[NUM_KEYCODES];
@@ -385,7 +391,15 @@ static void message_kit_thread (SEL selector, NSObject *arg) {
if (for_appkit) [super sendEvent:e];
- if (for_x) [self sendX11NSEvent:e];
+ if (for_x) {
+#ifdef HAVE_LIBDISPATCH
+ dispatch_async(eventTranslationQueue, ^{
+#endif
+ [self sendX11NSEvent:e];
+#ifdef HAVE_LIBDISPATCH
+ });
+#endif
+ }
}
- (void) set_window_menu:(NSArray *)list {
@@ -950,7 +964,7 @@ environment the next time you start X11?", @"Startup xinitrc dialog");
[X11App prefs_synchronize];
}
-static inline pthread_t create_thread(void *func, void *arg) {
+static inline pthread_t create_thread(void *(*func)(void *), void *arg) {
pthread_attr_t attr;
pthread_t tid;
@@ -999,6 +1013,11 @@ void X11ApplicationMain (int argc, char **argv, char **envp) {
aquaMenuBarHeight = NSHeight([[NSScreen mainScreen] frame]) -
NSMaxY([[NSScreen mainScreen] visibleFrame]);
+#ifdef HAVE_LIBDISPATCH
+ eventTranslationQueue = dispatch_queue_create(LAUNCHD_ID_PREFIX".X11.NSEventsToX11EventsQueue", NULL);
+ assert(eventTranslationQueue != NULL);
+#endif
+
/* Set the key layout seed before we start the server */
#if MAC_OS_X_VERSION_MIN_REQUIRED >= 1050
last_key_layout = TISCopyCurrentKeyboardLayoutInputSource();
@@ -1079,13 +1098,29 @@ static const char *untrusted_str(NSEvent *e) {
#endif
- (void) sendX11NSEvent:(NSEvent *)e {
- NSPoint location = NSZeroPoint, tilt = NSZeroPoint;
+ NSPoint location = NSZeroPoint;
int ev_button, ev_type;
- float pressure = 0.0;
+ static float pressure = 0.0; // static so ProximityOut will have the value from the previous tablet event
+ static NSPoint tilt; // static so ProximityOut will have the value from the previous tablet event
+ static DeviceIntPtr darwinTabletCurrent = NULL;
+ static BOOL needsProximityIn = NO; // Do we do need to handle a pending ProximityIn once we have pressure/tilt?
DeviceIntPtr pDev;
int modifierFlags;
BOOL isMouseOrTabletEvent, isTabletEvent;
+#ifdef HAVE_LIBDISPATCH
+ static dispatch_once_t once_pred;
+ dispatch_once(&once_pred, ^{
+ tilt = NSZeroPoint;
+ darwinTabletCurrent = darwinTabletStylus;
+ });
+#else
+ if(!darwinTabletCurrent) {
+ tilt = NSZeroPoint;
+ darwinTabletCurrent = darwinTabletStylus;
+ }
+#endif
+
isMouseOrTabletEvent = [e type] == NSLeftMouseDown || [e type] == NSOtherMouseDown || [e type] == NSRightMouseDown ||
[e type] == NSLeftMouseUp || [e type] == NSOtherMouseUp || [e type] == NSRightMouseUp ||
[e type] == NSLeftMouseDragged || [e type] == NSOtherMouseDragged || [e type] == NSRightMouseDragged ||
@@ -1207,19 +1242,14 @@ static const char *untrusted_str(NSEvent *e) {
darwinTabletCurrent=darwinTabletCursor;
break;
}
-
- /* NSTabletProximityEventSubtype doesn't encode pressure ant tilt
- * So we just pretend the motion was caused by the mouse. Hopefully
- * we'll have a better solution for this in the future (like maybe
- * NSTabletProximityEventSubtype will come from NSTabletPoint
- * rather than NSMouseMoved.
- pressure = [e pressure];
- tilt = [e tilt];
- pDev = darwinTabletCurrent;
- */
- DarwinSendProximityEvents([e isEnteringProximity] ? ProximityIn : ProximityOut,
- location.x, location.y);
+ if([e isEnteringProximity])
+ needsProximityIn = YES;
+ else
+ DarwinSendProximityEvents(darwinTabletCurrent, ProximityOut,
+ location.x, location.y, pressure,
+ tilt.x, tilt.y);
+ return;
}
if ([e type] == NSTabletPoint || [e subtype] == NSTabletPointEventSubtype) {
@@ -1227,6 +1257,14 @@ static const char *untrusted_str(NSEvent *e) {
tilt = [e tilt];
pDev = darwinTabletCurrent;
+
+ if(needsProximityIn) {
+ DarwinSendProximityEvents(darwinTabletCurrent, ProximityIn,
+ location.x, location.y, pressure,
+ tilt.x, tilt.y);
+
+ needsProximityIn = NO;
+ }
}
if(!XQuartzServerVisible && noTestExtensions) {
@@ -1280,8 +1318,12 @@ static const char *untrusted_str(NSEvent *e) {
break;
}
- DarwinSendProximityEvents([e isEnteringProximity] ? ProximityIn : ProximityOut,
- location.x, location.y);
+ if([e isEnteringProximity])
+ needsProximityIn = YES;
+ else
+ DarwinSendProximityEvents(darwinTabletCurrent, ProximityOut,
+ location.x, location.y, pressure,
+ tilt.x, tilt.y);
break;
case NSScrollWheel:
diff --git a/xorg-server/hw/xquartz/darwin.c b/xorg-server/hw/xquartz/darwin.c
index 5e43d2e04..cfeacae42 100644
--- a/xorg-server/hw/xquartz/darwin.c
+++ b/xorg-server/hw/xquartz/darwin.c
@@ -117,7 +117,6 @@ unsigned int windowItemModMask = NX_COMMANDMASK;
// devices
DeviceIntPtr darwinKeyboard = NULL;
DeviceIntPtr darwinPointer = NULL;
-DeviceIntPtr darwinTabletCurrent = NULL;
DeviceIntPtr darwinTabletStylus = NULL;
DeviceIntPtr darwinTabletCursor = NULL;
DeviceIntPtr darwinTabletEraser = NULL;
@@ -492,8 +491,6 @@ void InitInput( int argc, char **argv )
darwinTabletEraser = AddInputDevice(serverClient, DarwinTabletProc, TRUE);
darwinTabletEraser->name = strdup("eraser");
- darwinTabletCurrent = darwinTabletStylus;
-
DarwinEQInit();
QuartzInitInput(argc, argv);
diff --git a/xorg-server/hw/xquartz/darwin.h b/xorg-server/hw/xquartz/darwin.h
index 3a45f76e2..ec9d52d97 100644
--- a/xorg-server/hw/xquartz/darwin.h
+++ b/xorg-server/hw/xquartz/darwin.h
@@ -56,7 +56,6 @@ extern io_connect_t darwinParamConnect;
extern int darwinEventReadFD;
extern int darwinEventWriteFD;
extern DeviceIntPtr darwinPointer;
-extern DeviceIntPtr darwinTabletCurrent;
extern DeviceIntPtr darwinTabletCursor;
extern DeviceIntPtr darwinTabletStylus;
extern DeviceIntPtr darwinTabletEraser;
diff --git a/xorg-server/hw/xquartz/darwinEvents.c b/xorg-server/hw/xquartz/darwinEvents.c
index 16fec4a01..b591f7728 100644
--- a/xorg-server/hw/xquartz/darwinEvents.c
+++ b/xorg-server/hw/xquartz/darwinEvents.c
@@ -1,585 +1,609 @@
-/*
-Darwin event queue and event handling
-
-Copyright 2007-2008 Apple Inc.
-Copyright 2004 Kaleb S. KEITHLEY. All Rights Reserved.
-Copyright (c) 2002-2004 Torrey T. Lyons. All Rights Reserved.
-
-This file is based on mieq.c by Keith Packard,
-which contains the following copyright:
-Copyright 1990, 1998 The Open Group
-
-Permission to use, copy, modify, distribute, and sell this software and its
-documentation for any purpose is hereby granted without fee, provided that
-the above copyright notice appear in all copies and that both that
-copyright notice and this permission notice appear in supporting
-documentation.
-
-The above copyright notice and this permission notice 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 NONINFRINGEMENT. IN NO EVENT SHALL THE
-OPEN GROUP 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.
-
-Except as contained in this notice, the name of The Open Group shall not be
-used in advertising or otherwise to promote the sale, use or other dealings
-in this Software without prior written authorization from The Open Group.
- */
-
-#include "sanitizedCarbon.h"
-
-#ifdef HAVE_DIX_CONFIG_H
-#include <dix-config.h>
-#endif
-
-#include <X11/X.h>
-#include <X11/Xmd.h>
-#include <X11/Xproto.h>
-#include "misc.h"
-#include "windowstr.h"
-#include "pixmapstr.h"
-#include "inputstr.h"
-#include "inpututils.h"
-#include "eventstr.h"
-#include "mi.h"
-#include "scrnintstr.h"
-#include "mipointer.h"
-#include "os.h"
-
-#include "darwin.h"
-#include "quartz.h"
-#include "quartzKeyboard.h"
-#include "quartzRandR.h"
-#include "darwinEvents.h"
-
-#include <sys/types.h>
-#include <sys/uio.h>
-#include <unistd.h>
-#include <pthread.h>
-#include <errno.h>
-
-#include <IOKit/hidsystem/IOLLEvent.h>
-
-/* Fake button press/release for scroll wheel move. */
-#define SCROLLWHEELUPFAKE 4
-#define SCROLLWHEELDOWNFAKE 5
-#define SCROLLWHEELLEFTFAKE 6
-#define SCROLLWHEELRIGHTFAKE 7
-
-#include <X11/extensions/applewmconst.h>
-#include "applewmExt.h"
-
-/* FIXME: Abstract this better */
-extern Bool QuartzModeEventHandler(int screenNum, XQuartzEvent *e, DeviceIntPtr dev);
-
-int darwin_all_modifier_flags = 0; // last known modifier state
-int darwin_all_modifier_mask = 0;
-int darwin_x11_modifier_mask = 0;
-
-#define FD_ADD_MAX 128
-static int fd_add[FD_ADD_MAX];
-int fd_add_count = 0;
-static pthread_mutex_t fd_add_lock = PTHREAD_MUTEX_INITIALIZER;
-static pthread_cond_t fd_add_ready_cond = PTHREAD_COND_INITIALIZER;
-static pthread_t fd_add_tid = NULL;
-
-static EventListPtr darwinEvents = NULL;
-
-static pthread_mutex_t mieq_lock = PTHREAD_MUTEX_INITIALIZER;
-static pthread_cond_t mieq_ready_cond = PTHREAD_COND_INITIALIZER;
-
-/*** Pthread Magics ***/
-static pthread_t create_thread(void *func, void *arg) {
- pthread_attr_t attr;
- pthread_t tid;
-
- pthread_attr_init (&attr);
- pthread_attr_setscope (&attr, PTHREAD_SCOPE_SYSTEM);
- pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED);
- pthread_create (&tid, &attr, func, arg);
- pthread_attr_destroy (&attr);
-
- return tid;
-}
-
-void darwinEvents_lock(void);
-void darwinEvents_lock(void) {
- int err;
- if((err = pthread_mutex_lock(&mieq_lock))) {
- ErrorF("%s:%s:%d: Failed to lock mieq_lock: %d\n",
- __FILE__, __FUNCTION__, __LINE__, err);
- spewCallStack();
- }
- if(darwinEvents == NULL) {
- pthread_cond_wait(&mieq_ready_cond, &mieq_lock);
- }
-}
-
-void darwinEvents_unlock(void);
-void darwinEvents_unlock(void) {
- int err;
- if((err = pthread_mutex_unlock(&mieq_lock))) {
- ErrorF("%s:%s:%d: Failed to unlock mieq_lock: %d\n",
- __FILE__, __FUNCTION__, __LINE__, err);
- spewCallStack();
- }
-}
-
-/*
- * DarwinPressModifierKey
- * Press or release the given modifier key (one of NX_MODIFIERKEY_* constants)
- */
-static void DarwinPressModifierKey(int pressed, int key) {
- int keycode = DarwinModifierNXKeyToNXKeycode(key, 0);
-
- if (keycode == 0) {
- ErrorF("DarwinPressModifierKey bad keycode: key=%d\n", key);
- return;
- }
-
- DarwinSendKeyboardEvents(pressed, keycode);
-}
-
-/*
- * DarwinUpdateModifiers
- * Send events to update the modifier state.
- */
-
-static int darwin_x11_modifier_mask_list[] = {
-#ifdef NX_DEVICELCMDKEYMASK
- NX_DEVICELCTLKEYMASK, NX_DEVICERCTLKEYMASK,
- NX_DEVICELSHIFTKEYMASK, NX_DEVICERSHIFTKEYMASK,
- NX_DEVICELCMDKEYMASK, NX_DEVICERCMDKEYMASK,
- NX_DEVICELALTKEYMASK, NX_DEVICERALTKEYMASK,
-#else
- NX_CONTROLMASK, NX_SHIFTMASK, NX_COMMANDMASK, NX_ALTERNATEMASK,
-#endif
- NX_ALPHASHIFTMASK,
- 0
-};
-
-static int darwin_all_modifier_mask_additions[] = { NX_SECONDARYFNMASK, };
-
-static void DarwinUpdateModifiers(
- int pressed, // KeyPress or KeyRelease
- int flags ) // modifier flags that have changed
-{
- int *f;
- int key;
-
- /* Capslock is special. This mask is the state of capslock (on/off),
- * not the state of the button. Hopefully we can find a better solution.
- */
- if(NX_ALPHASHIFTMASK & flags) {
- DarwinPressModifierKey(KeyPress, NX_MODIFIERKEY_ALPHALOCK);
- DarwinPressModifierKey(KeyRelease, NX_MODIFIERKEY_ALPHALOCK);
- }
-
- for(f=darwin_x11_modifier_mask_list; *f; f++)
- if(*f & flags && *f != NX_ALPHASHIFTMASK) {
- key = DarwinModifierNXMaskToNXKey(*f);
- if(key == -1)
- ErrorF("DarwinUpdateModifiers: Unsupported NXMask: 0x%x\n", *f);
- else
- DarwinPressModifierKey(pressed, key);
- }
-}
-
-/* Generic handler for Xquartz-specifc events. When possible, these should
- be moved into their own individual functions and set as handlers using
- mieqSetHandler. */
-
-static void DarwinEventHandler(int screenNum, InternalEvent *ie, DeviceIntPtr dev) {
- XQuartzEvent *e = &(ie->xquartz_event);
-
- TA_SERVER();
-
- switch(e->subtype) {
- case kXquartzControllerNotify:
- DEBUG_LOG("kXquartzControllerNotify\n");
- AppleWMSendEvent(AppleWMControllerNotify,
- AppleWMControllerNotifyMask,
- e->data[0],
- e->data[1]);
- break;
-
- case kXquartzPasteboardNotify:
- DEBUG_LOG("kXquartzPasteboardNotify\n");
- AppleWMSendEvent(AppleWMPasteboardNotify,
- AppleWMPasteboardNotifyMask,
- e->data[0],
- e->data[1]);
- break;
-
- case kXquartzActivate:
- DEBUG_LOG("kXquartzActivate\n");
- QuartzShow();
- AppleWMSendEvent(AppleWMActivationNotify,
- AppleWMActivationNotifyMask,
- AppleWMIsActive, 0);
- break;
-
- case kXquartzDeactivate:
- DEBUG_LOG("kXquartzDeactivate\n");
- AppleWMSendEvent(AppleWMActivationNotify,
- AppleWMActivationNotifyMask,
- AppleWMIsInactive, 0);
- QuartzHide();
- break;
-
- case kXquartzReloadPreferences:
- DEBUG_LOG("kXquartzReloadPreferences\n");
- AppleWMSendEvent(AppleWMActivationNotify,
- AppleWMActivationNotifyMask,
- AppleWMReloadPreferences, 0);
- break;
-
- case kXquartzToggleFullscreen:
- DEBUG_LOG("kXquartzToggleFullscreen\n");
- if(XQuartzIsRootless)
- ErrorF("Ignoring kXquartzToggleFullscreen because of rootless mode.");
- else
- QuartzRandRToggleFullscreen();
- break;
-
- case kXquartzSetRootless:
- DEBUG_LOG("kXquartzSetRootless\n");
- if(e->data[0]) {
- QuartzRandRSetFakeRootless();
- } else {
- QuartzRandRSetFakeFullscreen(FALSE);
- }
- break;
-
- case kXquartzSetRootClip:
- QuartzSetRootClip((Bool)e->data[0]);
- break;
-
- case kXquartzQuit:
- GiveUp(0);
- break;
-
- case kXquartzSpaceChanged:
- DEBUG_LOG("kXquartzSpaceChanged\n");
- QuartzSpaceChanged(e->data[0]);
- break;
-
- case kXquartzListenOnOpenFD:
- ErrorF("Calling ListenOnOpenFD() for new fd: %d\n", (int)e->data[0]);
- ListenOnOpenFD((int)e->data[0], 1);
- break;
-
- case kXquartzReloadKeymap:
- DarwinKeyboardReloadHandler();
- break;
-
- case kXquartzDisplayChanged:
- DEBUG_LOG("kXquartzDisplayChanged\n");
- QuartzUpdateScreens();
-
- /* Update our RandR info */
- QuartzRandRUpdateFakeModes(TRUE);
- break;
-
- default:
- if(!QuartzModeEventHandler(screenNum, e, dev))
- ErrorF("Unknown application defined event type %d.\n", e->subtype);
- }
-}
-
-void DarwinListenOnOpenFD(int fd) {
- ErrorF("DarwinListenOnOpenFD: %d\n", fd);
-
- pthread_mutex_lock(&fd_add_lock);
- if(fd_add_count < FD_ADD_MAX)
- fd_add[fd_add_count++] = fd;
- else
- ErrorF("FD Addition buffer at max. Dropping fd addition request.\n");
-
- pthread_cond_broadcast(&fd_add_ready_cond);
- pthread_mutex_unlock(&fd_add_lock);
-}
-
-static void DarwinProcessFDAdditionQueue_thread(void *args) {
- pthread_mutex_lock(&fd_add_lock);
- while(true) {
- while(fd_add_count) {
- DarwinSendDDXEvent(kXquartzListenOnOpenFD, 1, fd_add[--fd_add_count]);
- }
- pthread_cond_wait(&fd_add_ready_cond, &fd_add_lock);
- }
-}
-
-Bool DarwinEQInit(void) {
- int *p;
-
- for(p=darwin_x11_modifier_mask_list, darwin_all_modifier_mask=0; *p; p++) {
- darwin_x11_modifier_mask |= *p;
- }
-
- for(p=darwin_all_modifier_mask_additions, darwin_all_modifier_mask= darwin_x11_modifier_mask; *p; p++) {
- darwin_all_modifier_mask |= *p;
- }
-
- mieqInit();
- mieqSetHandler(ET_XQuartz, DarwinEventHandler);
-
- /* Note that this *could* cause a potential async issue, since we're checking
- * darwinEvents without holding the lock, but darwinEvents is only ever set
- * here, so I don't bother.
- */
- if (!darwinEvents) {
- darwinEvents = InitEventList(GetMaximumEventsNum());;
-
- if (!darwinEvents)
- FatalError("Couldn't allocate event buffer\n");
-
- darwinEvents_lock();
- pthread_cond_broadcast(&mieq_ready_cond);
- darwinEvents_unlock();
- }
-
- if(!fd_add_tid)
- fd_add_tid = create_thread(DarwinProcessFDAdditionQueue_thread, NULL);
-
- return TRUE;
-}
-
-/*
- * ProcessInputEvents
- * Read and process events from the event queue until it is empty.
- */
-void ProcessInputEvents(void) {
- char nullbyte;
- int x = sizeof(nullbyte);
-
- TA_SERVER();
-
- mieqProcessInputEvents();
-
- // Empty the signaling pipe
- while (x == sizeof(nullbyte)) {
- x = read(darwinEventReadFD, &nullbyte, sizeof(nullbyte));
- }
-}
-
-/* Sends a null byte down darwinEventWriteFD, which will cause the
- Dispatch() event loop to check out event queue */
-static void DarwinPokeEQ(void) {
- char nullbyte=0;
- // <daniels> oh, i ... er ... christ.
- write(darwinEventWriteFD, &nullbyte, sizeof(nullbyte));
-}
-
-/* Convert from Appkit pointer input values to X input values:
- * Note: pointer_x and pointer_y are relative to the upper-left of primary
- * display.
- */
-static void DarwinPrepareValuators(DeviceIntPtr pDev, int *valuators, ScreenPtr screen,
- float pointer_x, float pointer_y,
- float pressure, float tilt_x, float tilt_y) {
- /* Fix offset between darwin and X screens */
- pointer_x -= darwinMainScreenX + screen->x;
- pointer_y -= darwinMainScreenY + screen->y;
-
- if(pointer_x < 0.0)
- pointer_x = 0.0;
-
- if(pointer_y < 0.0)
- pointer_y = 0.0;
-
- if(pDev == darwinPointer) {
- valuators[0] = pointer_x;
- valuators[1] = pointer_y;
- valuators[2] = 0;
- valuators[3] = 0;
- valuators[4] = 0;
- } else {
- /* Setup our array of values */
- valuators[0] = XQUARTZ_VALUATOR_LIMIT * (pointer_x / (float)screenInfo.screens[0]->width);
- valuators[1] = XQUARTZ_VALUATOR_LIMIT * (pointer_y / (float)screenInfo.screens[0]->height);
- valuators[2] = XQUARTZ_VALUATOR_LIMIT * pressure;
- valuators[3] = XQUARTZ_VALUATOR_LIMIT * tilt_x;
- valuators[4] = XQUARTZ_VALUATOR_LIMIT * tilt_y;
- }
- //DEBUG_LOG("Pointer (%f, %f), Valuators: {%d,%d,%d,%d,%d}\n", pointer_x, pointer_y,
- // valuators[0], valuators[1], valuators[2], valuators[3], valuators[4]);
-}
-
-void DarwinSendPointerEvents(DeviceIntPtr pDev, int ev_type, int ev_button, float pointer_x, float pointer_y,
- float pressure, float tilt_x, float tilt_y) {
- static int darwinFakeMouseButtonDown = 0;
- int i, num_events;
- ScreenPtr screen;
- int valuators[5];
-
- //DEBUG_LOG("x=%f, y=%f, p=%f, tx=%f, ty=%f\n", pointer_x, pointer_y, pressure, tilt_x, tilt_y);
-
- if(!darwinEvents) {
- DEBUG_LOG("DarwinSendPointerEvents called before darwinEvents was initialized\n");
- return;
- }
-
- screen = miPointerGetScreen(pDev);
- if(!screen) {
- DEBUG_LOG("DarwinSendPointerEvents called before screen was initialized\n");
- return;
- }
-
- /* Handle fake click */
- if (ev_type == ButtonPress && darwinFakeButtons && ev_button == 1) {
- if(darwinFakeMouseButtonDown != 0) {
- /* We're currently "down" with another button, so release it first */
- DarwinSendPointerEvents(pDev, ButtonRelease, darwinFakeMouseButtonDown, pointer_x, pointer_y, pressure, tilt_x, tilt_y);
- darwinFakeMouseButtonDown=0;
- }
- if (darwin_all_modifier_flags & darwinFakeMouse2Mask) {
- ev_button = 2;
- darwinFakeMouseButtonDown = 2;
- DarwinUpdateModKeys(darwin_all_modifier_flags & ~darwinFakeMouse2Mask);
- } else if (darwin_all_modifier_flags & darwinFakeMouse3Mask) {
- ev_button = 3;
- darwinFakeMouseButtonDown = 3;
- DarwinUpdateModKeys(darwin_all_modifier_flags & ~darwinFakeMouse3Mask);
- }
- }
-
- if (ev_type == ButtonRelease && ev_button == 1) {
- if(darwinFakeMouseButtonDown) {
- ev_button = darwinFakeMouseButtonDown;
- }
-
- if(darwinFakeMouseButtonDown == 2) {
- DarwinUpdateModKeys(darwin_all_modifier_flags & ~darwinFakeMouse2Mask);
- } else if(darwinFakeMouseButtonDown == 3) {
- DarwinUpdateModKeys(darwin_all_modifier_flags & ~darwinFakeMouse3Mask);
- }
-
- darwinFakeMouseButtonDown = 0;
- }
-
- DarwinPrepareValuators(pDev, valuators, screen, pointer_x, pointer_y, pressure, tilt_x, tilt_y);
- darwinEvents_lock(); {
- ValuatorMask mask;
- valuator_mask_set_range(&mask, 0, (pDev == darwinTabletCurrent) ? 5 : 2, valuators);
- num_events = GetPointerEvents(darwinEvents, pDev, ev_type, ev_button,
- POINTER_ABSOLUTE, &mask);
- for(i=0; i<num_events; i++) mieqEnqueue (pDev, (InternalEvent*)darwinEvents[i].event);
- if(num_events > 0) DarwinPokeEQ();
- } darwinEvents_unlock();
-}
-
-void DarwinSendKeyboardEvents(int ev_type, int keycode) {
- int i, num_events;
-
- if(!darwinEvents) {
- DEBUG_LOG("DarwinSendKeyboardEvents called before darwinEvents was initialized\n");
- return;
- }
-
- darwinEvents_lock(); {
- num_events = GetKeyboardEvents(darwinEvents, darwinKeyboard, ev_type, keycode + MIN_KEYCODE);
- for(i=0; i<num_events; i++) mieqEnqueue(darwinKeyboard, (InternalEvent*)darwinEvents[i].event);
- if(num_events > 0) DarwinPokeEQ();
- } darwinEvents_unlock();
-}
-
-void DarwinSendProximityEvents(int ev_type, float pointer_x, float pointer_y) {
- int i, num_events;
- ScreenPtr screen;
- DeviceIntPtr pDev = darwinTabletCurrent;
- int valuators[5];
-
- DEBUG_LOG("DarwinSendProximityEvents(%d, %f, %f)\n", ev_type, pointer_x, pointer_y);
-
- if(!darwinEvents) {
- DEBUG_LOG("DarwinSendProximityEvents called before darwinEvents was initialized\n");
- return;
- }
-
- screen = miPointerGetScreen(pDev);
- if(!screen) {
- DEBUG_LOG("DarwinSendPointerEvents called before screen was initialized\n");
- return;
- }
-
- DarwinPrepareValuators(pDev, valuators, screen, pointer_x, pointer_y, 0.0f, 0.0f, 0.0f);
- darwinEvents_lock(); {
- ValuatorMask mask;
- valuator_mask_set_range(&mask, 0, 5, valuators);
- num_events = GetProximityEvents(darwinEvents, pDev, ev_type, &mask);
- for(i=0; i<num_events; i++) mieqEnqueue (pDev, (InternalEvent*)darwinEvents[i].event);
- if(num_events > 0) DarwinPokeEQ();
- } darwinEvents_unlock();
-}
-
-
-/* Send the appropriate number of button clicks to emulate scroll wheel */
-void DarwinSendScrollEvents(float count_x, float count_y,
- float pointer_x, float pointer_y,
- float pressure, float tilt_x, float tilt_y) {
- int sign_x, sign_y;
- if(!darwinEvents) {
- DEBUG_LOG("DarwinSendScrollEvents called before darwinEvents was initialized\n");
- return;
- }
-
- sign_x = count_x > 0.0f ? SCROLLWHEELLEFTFAKE : SCROLLWHEELRIGHTFAKE;
- sign_y = count_y > 0.0f ? SCROLLWHEELUPFAKE : SCROLLWHEELDOWNFAKE;
- count_x = fabs(count_x);
- count_y = fabs(count_y);
-
- while ((count_x > 0.0f) || (count_y > 0.0f)) {
- if (count_x > 0.0f) {
- DarwinSendPointerEvents(darwinPointer, ButtonPress, sign_x, pointer_x, pointer_y, pressure, tilt_x, tilt_y);
- DarwinSendPointerEvents(darwinPointer, ButtonRelease, sign_x, pointer_x, pointer_y, pressure, tilt_x, tilt_y);
- count_x = count_x - 1.0f;
- }
- if (count_y > 0.0f) {
- DarwinSendPointerEvents(darwinPointer, ButtonPress, sign_y, pointer_x, pointer_y, pressure, tilt_x, tilt_y);
- DarwinSendPointerEvents(darwinPointer, ButtonRelease, sign_y, pointer_x, pointer_y, pressure, tilt_x, tilt_y);
- count_y = count_y - 1.0f;
- }
- }
-}
-
-/* Send the appropriate KeyPress/KeyRelease events to GetKeyboardEvents to
- reflect changing modifier flags (alt, control, meta, etc) */
-void DarwinUpdateModKeys(int flags) {
- DarwinUpdateModifiers(KeyRelease, darwin_all_modifier_flags & ~flags & darwin_x11_modifier_mask);
- DarwinUpdateModifiers(KeyPress, ~darwin_all_modifier_flags & flags & darwin_x11_modifier_mask);
- darwin_all_modifier_flags = flags;
-}
-
-/*
- * DarwinSendDDXEvent
- * Send the X server thread a message by placing it on the event queue.
- */
-void DarwinSendDDXEvent(int type, int argc, ...) {
- XQuartzEvent e;
- int i;
- va_list args;
-
- memset(&e, 0, sizeof(e));
- e.header = ET_Internal;
- e.type = ET_XQuartz;
- e.length = sizeof(e);
- e.time = GetTimeInMillis();
- e.subtype = type;
-
- if (argc > 0 && argc < XQUARTZ_EVENT_MAXARGS) {
- va_start (args, argc);
- for (i = 0; i < argc; i++)
- e.data[i] = (uint32_t) va_arg (args, uint32_t);
- va_end (args);
- }
-
- darwinEvents_lock(); {
- mieqEnqueue(NULL, (InternalEvent*)&e);
- DarwinPokeEQ();
- } darwinEvents_unlock();
-}
+/*
+Darwin event queue and event handling
+
+Copyright 2007-2008 Apple Inc.
+Copyright 2004 Kaleb S. KEITHLEY. All Rights Reserved.
+Copyright (c) 2002-2004 Torrey T. Lyons. All Rights Reserved.
+
+This file is based on mieq.c by Keith Packard,
+which contains the following copyright:
+Copyright 1990, 1998 The Open Group
+
+Permission to use, copy, modify, distribute, and sell this software and its
+documentation for any purpose is hereby granted without fee, provided that
+the above copyright notice appear in all copies and that both that
+copyright notice and this permission notice appear in supporting
+documentation.
+
+The above copyright notice and this permission notice 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 NONINFRINGEMENT. IN NO EVENT SHALL THE
+OPEN GROUP 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.
+
+Except as contained in this notice, the name of The Open Group shall not be
+used in advertising or otherwise to promote the sale, use or other dealings
+in this Software without prior written authorization from The Open Group.
+ */
+
+#include "sanitizedCarbon.h"
+
+#ifdef HAVE_DIX_CONFIG_H
+#include <dix-config.h>
+#endif
+
+#include <X11/X.h>
+#include <X11/Xmd.h>
+#include <X11/Xproto.h>
+#include "misc.h"
+#include "windowstr.h"
+#include "pixmapstr.h"
+#include "inputstr.h"
+#include "inpututils.h"
+#include "eventstr.h"
+#include "mi.h"
+#include "scrnintstr.h"
+#include "mipointer.h"
+#include "os.h"
+
+#include "darwin.h"
+#include "quartz.h"
+#include "quartzKeyboard.h"
+#include "quartzRandR.h"
+#include "darwinEvents.h"
+
+#include <sys/types.h>
+#include <sys/uio.h>
+#include <unistd.h>
+#include <pthread.h>
+#include <errno.h>
+#include <time.h>
+
+#include <IOKit/hidsystem/IOLLEvent.h>
+
+/* Fake button press/release for scroll wheel move. */
+#define SCROLLWHEELUPFAKE 4
+#define SCROLLWHEELDOWNFAKE 5
+#define SCROLLWHEELLEFTFAKE 6
+#define SCROLLWHEELRIGHTFAKE 7
+
+#include <X11/extensions/applewmconst.h>
+#include "applewmExt.h"
+
+/* FIXME: Abstract this better */
+extern Bool QuartzModeEventHandler(int screenNum, XQuartzEvent *e, DeviceIntPtr dev);
+
+int darwin_all_modifier_flags = 0; // last known modifier state
+int darwin_all_modifier_mask = 0;
+int darwin_x11_modifier_mask = 0;
+
+#define FD_ADD_MAX 128
+static int fd_add[FD_ADD_MAX];
+int fd_add_count = 0;
+static pthread_mutex_t fd_add_lock = PTHREAD_MUTEX_INITIALIZER;
+static pthread_cond_t fd_add_ready_cond = PTHREAD_COND_INITIALIZER;
+static pthread_t fd_add_tid = NULL;
+
+static EventListPtr darwinEvents = NULL;
+
+static pthread_mutex_t mieq_lock = PTHREAD_MUTEX_INITIALIZER;
+static pthread_cond_t mieq_ready_cond = PTHREAD_COND_INITIALIZER;
+
+/*** Pthread Magics ***/
+static pthread_t create_thread(void *(*func)(void *), void *arg) {
+ pthread_attr_t attr;
+ pthread_t tid;
+
+ pthread_attr_init (&attr);
+ pthread_attr_setscope (&attr, PTHREAD_SCOPE_SYSTEM);
+ pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED);
+ pthread_create (&tid, &attr, func, arg);
+ pthread_attr_destroy (&attr);
+
+ return tid;
+}
+
+void darwinEvents_lock(void);
+void darwinEvents_lock(void) {
+ int err;
+ if((err = pthread_mutex_lock(&mieq_lock))) {
+ ErrorF("%s:%s:%d: Failed to lock mieq_lock: %d\n",
+ __FILE__, __FUNCTION__, __LINE__, err);
+ spewCallStack();
+ }
+ if(darwinEvents == NULL) {
+ pthread_cond_wait(&mieq_ready_cond, &mieq_lock);
+ }
+}
+
+void darwinEvents_unlock(void);
+void darwinEvents_unlock(void) {
+ int err;
+ if((err = pthread_mutex_unlock(&mieq_lock))) {
+ ErrorF("%s:%s:%d: Failed to unlock mieq_lock: %d\n",
+ __FILE__, __FUNCTION__, __LINE__, err);
+ spewCallStack();
+ }
+}
+
+/*
+ * DarwinPressModifierKey
+ * Press or release the given modifier key (one of NX_MODIFIERKEY_* constants)
+ */
+static void DarwinPressModifierKey(int pressed, int key) {
+ int keycode = DarwinModifierNXKeyToNXKeycode(key, 0);
+
+ if (keycode == 0) {
+ ErrorF("DarwinPressModifierKey bad keycode: key=%d\n", key);
+ return;
+ }
+
+ DarwinSendKeyboardEvents(pressed, keycode);
+}
+
+/*
+ * DarwinUpdateModifiers
+ * Send events to update the modifier state.
+ */
+
+static int darwin_x11_modifier_mask_list[] = {
+#ifdef NX_DEVICELCMDKEYMASK
+ NX_DEVICELCTLKEYMASK, NX_DEVICERCTLKEYMASK,
+ NX_DEVICELSHIFTKEYMASK, NX_DEVICERSHIFTKEYMASK,
+ NX_DEVICELCMDKEYMASK, NX_DEVICERCMDKEYMASK,
+ NX_DEVICELALTKEYMASK, NX_DEVICERALTKEYMASK,
+#else
+ NX_CONTROLMASK, NX_SHIFTMASK, NX_COMMANDMASK, NX_ALTERNATEMASK,
+#endif
+ NX_ALPHASHIFTMASK,
+ 0
+};
+
+static int darwin_all_modifier_mask_additions[] = { NX_SECONDARYFNMASK, };
+
+static void DarwinUpdateModifiers(
+ int pressed, // KeyPress or KeyRelease
+ int flags ) // modifier flags that have changed
+{
+ int *f;
+ int key;
+
+ /* Capslock is special. This mask is the state of capslock (on/off),
+ * not the state of the button. Hopefully we can find a better solution.
+ */
+ if(NX_ALPHASHIFTMASK & flags) {
+ DarwinPressModifierKey(KeyPress, NX_MODIFIERKEY_ALPHALOCK);
+ DarwinPressModifierKey(KeyRelease, NX_MODIFIERKEY_ALPHALOCK);
+ }
+
+ for(f=darwin_x11_modifier_mask_list; *f; f++)
+ if(*f & flags && *f != NX_ALPHASHIFTMASK) {
+ key = DarwinModifierNXMaskToNXKey(*f);
+ if(key == -1)
+ ErrorF("DarwinUpdateModifiers: Unsupported NXMask: 0x%x\n", *f);
+ else
+ DarwinPressModifierKey(pressed, key);
+ }
+}
+
+/* Generic handler for Xquartz-specifc events. When possible, these should
+ be moved into their own individual functions and set as handlers using
+ mieqSetHandler. */
+
+static void DarwinEventHandler(int screenNum, InternalEvent *ie, DeviceIntPtr dev) {
+ XQuartzEvent *e = &(ie->xquartz_event);
+
+ TA_SERVER();
+
+ switch(e->subtype) {
+ case kXquartzControllerNotify:
+ DEBUG_LOG("kXquartzControllerNotify\n");
+ AppleWMSendEvent(AppleWMControllerNotify,
+ AppleWMControllerNotifyMask,
+ e->data[0],
+ e->data[1]);
+ break;
+
+ case kXquartzPasteboardNotify:
+ DEBUG_LOG("kXquartzPasteboardNotify\n");
+ AppleWMSendEvent(AppleWMPasteboardNotify,
+ AppleWMPasteboardNotifyMask,
+ e->data[0],
+ e->data[1]);
+ break;
+
+ case kXquartzActivate:
+ DEBUG_LOG("kXquartzActivate\n");
+ QuartzShow();
+ AppleWMSendEvent(AppleWMActivationNotify,
+ AppleWMActivationNotifyMask,
+ AppleWMIsActive, 0);
+ break;
+
+ case kXquartzDeactivate:
+ DEBUG_LOG("kXquartzDeactivate\n");
+ AppleWMSendEvent(AppleWMActivationNotify,
+ AppleWMActivationNotifyMask,
+ AppleWMIsInactive, 0);
+ QuartzHide();
+ break;
+
+ case kXquartzReloadPreferences:
+ DEBUG_LOG("kXquartzReloadPreferences\n");
+ AppleWMSendEvent(AppleWMActivationNotify,
+ AppleWMActivationNotifyMask,
+ AppleWMReloadPreferences, 0);
+ break;
+
+ case kXquartzToggleFullscreen:
+ DEBUG_LOG("kXquartzToggleFullscreen\n");
+ if(XQuartzIsRootless)
+ ErrorF("Ignoring kXquartzToggleFullscreen because of rootless mode.");
+ else
+ QuartzRandRToggleFullscreen();
+ break;
+
+ case kXquartzSetRootless:
+ DEBUG_LOG("kXquartzSetRootless\n");
+ if(e->data[0]) {
+ QuartzRandRSetFakeRootless();
+ } else {
+ QuartzRandRSetFakeFullscreen(FALSE);
+ }
+ break;
+
+ case kXquartzSetRootClip:
+ QuartzSetRootClip((Bool)e->data[0]);
+ break;
+
+ case kXquartzQuit:
+ GiveUp(0);
+ break;
+
+ case kXquartzSpaceChanged:
+ DEBUG_LOG("kXquartzSpaceChanged\n");
+ QuartzSpaceChanged(e->data[0]);
+ break;
+
+ case kXquartzListenOnOpenFD:
+ ErrorF("Calling ListenOnOpenFD() for new fd: %d\n", (int)e->data[0]);
+ ListenOnOpenFD((int)e->data[0], 1);
+ break;
+
+ case kXquartzReloadKeymap:
+ DarwinKeyboardReloadHandler();
+ break;
+
+ case kXquartzDisplayChanged:
+ DEBUG_LOG("kXquartzDisplayChanged\n");
+ QuartzUpdateScreens();
+
+ /* Update our RandR info */
+ QuartzRandRUpdateFakeModes(TRUE);
+ break;
+
+ default:
+ if(!QuartzModeEventHandler(screenNum, e, dev))
+ ErrorF("Unknown application defined event type %d.\n", e->subtype);
+ }
+}
+
+void DarwinListenOnOpenFD(int fd) {
+ ErrorF("DarwinListenOnOpenFD: %d\n", fd);
+
+ pthread_mutex_lock(&fd_add_lock);
+ if(fd_add_count < FD_ADD_MAX)
+ fd_add[fd_add_count++] = fd;
+ else
+ ErrorF("FD Addition buffer at max. Dropping fd addition request.\n");
+
+ pthread_cond_broadcast(&fd_add_ready_cond);
+ pthread_mutex_unlock(&fd_add_lock);
+}
+
+static void *DarwinProcessFDAdditionQueue_thread(void *args) {
+ /* TODO: Possibly adjust this to no longer be a race... maybe trigger this
+ * once a client connects and claims to be the WM.
+ *
+ * From ajax:
+ * There's already an internal callback chain for setting selection [in 1.5]
+ * ownership. See the CallSelectionCallback at the bottom of
+ * ProcSetSelectionOwner, and xfixes/select.c for an example of how to hook
+ * into it.
+ */
+
+ struct timespec sleep_for;
+ struct timespec sleep_remaining;
+
+ sleep_for.tv_sec = 3;
+ sleep_for.tv_nsec = 0;
+
+ ErrorF("X11.app: DarwinProcessFDAdditionQueue_thread: Sleeping to allow xinitrc to catchup.\n");
+ while(nanosleep(&sleep_for, &sleep_remaining) != 0) {
+ sleep_for = sleep_remaining;
+ }
+
+ pthread_mutex_lock(&fd_add_lock);
+ while(true) {
+ while(fd_add_count) {
+ DarwinSendDDXEvent(kXquartzListenOnOpenFD, 1, fd_add[--fd_add_count]);
+ }
+ pthread_cond_wait(&fd_add_ready_cond, &fd_add_lock);
+ }
+
+ return NULL;
+}
+
+Bool DarwinEQInit(void) {
+ int *p;
+
+ for(p=darwin_x11_modifier_mask_list, darwin_all_modifier_mask=0; *p; p++) {
+ darwin_x11_modifier_mask |= *p;
+ }
+
+ for(p=darwin_all_modifier_mask_additions, darwin_all_modifier_mask= darwin_x11_modifier_mask; *p; p++) {
+ darwin_all_modifier_mask |= *p;
+ }
+
+ mieqInit();
+ mieqSetHandler(ET_XQuartz, DarwinEventHandler);
+
+ /* Note that this *could* cause a potential async issue, since we're checking
+ * darwinEvents without holding the lock, but darwinEvents is only ever set
+ * here, so I don't bother.
+ */
+ if (!darwinEvents) {
+ darwinEvents = InitEventList(GetMaximumEventsNum());;
+
+ if (!darwinEvents)
+ FatalError("Couldn't allocate event buffer\n");
+
+ darwinEvents_lock();
+ pthread_cond_broadcast(&mieq_ready_cond);
+ darwinEvents_unlock();
+ }
+
+ if(!fd_add_tid)
+ fd_add_tid = create_thread(DarwinProcessFDAdditionQueue_thread, NULL);
+
+ return TRUE;
+}
+
+/*
+ * ProcessInputEvents
+ * Read and process events from the event queue until it is empty.
+ */
+void ProcessInputEvents(void) {
+ char nullbyte;
+ int x = sizeof(nullbyte);
+
+ TA_SERVER();
+
+ mieqProcessInputEvents();
+
+ // Empty the signaling pipe
+ while (x == sizeof(nullbyte)) {
+ x = read(darwinEventReadFD, &nullbyte, sizeof(nullbyte));
+ }
+}
+
+/* Sends a null byte down darwinEventWriteFD, which will cause the
+ Dispatch() event loop to check out event queue */
+static void DarwinPokeEQ(void) {
+ char nullbyte=0;
+ // <daniels> oh, i ... er ... christ.
+ write(darwinEventWriteFD, &nullbyte, sizeof(nullbyte));
+}
+
+/* Convert from Appkit pointer input values to X input values:
+ * Note: pointer_x and pointer_y are relative to the upper-left of primary
+ * display.
+ */
+static void DarwinPrepareValuators(DeviceIntPtr pDev, int *valuators, ScreenPtr screen,
+ float pointer_x, float pointer_y,
+ float pressure, float tilt_x, float tilt_y) {
+ /* Fix offset between darwin and X screens */
+ pointer_x -= darwinMainScreenX + screen->x;
+ pointer_y -= darwinMainScreenY + screen->y;
+
+ if(pointer_x < 0.0)
+ pointer_x = 0.0;
+
+ if(pointer_y < 0.0)
+ pointer_y = 0.0;
+
+ if(pDev == darwinPointer) {
+ valuators[0] = pointer_x;
+ valuators[1] = pointer_y;
+ valuators[2] = 0;
+ valuators[3] = 0;
+ valuators[4] = 0;
+ } else {
+ /* Setup our array of values */
+ valuators[0] = XQUARTZ_VALUATOR_LIMIT * (pointer_x / (float)screenInfo.screens[0]->width);
+ valuators[1] = XQUARTZ_VALUATOR_LIMIT * (pointer_y / (float)screenInfo.screens[0]->height);
+ valuators[2] = XQUARTZ_VALUATOR_LIMIT * pressure;
+ valuators[3] = XQUARTZ_VALUATOR_LIMIT * tilt_x;
+ valuators[4] = XQUARTZ_VALUATOR_LIMIT * tilt_y;
+ }
+ //DEBUG_LOG("Pointer (%f, %f), Valuators: {%d,%d,%d,%d,%d}\n", pointer_x, pointer_y,
+ // valuators[0], valuators[1], valuators[2], valuators[3], valuators[4]);
+}
+
+void DarwinSendPointerEvents(DeviceIntPtr pDev, int ev_type, int ev_button, float pointer_x, float pointer_y,
+ float pressure, float tilt_x, float tilt_y) {
+ static int darwinFakeMouseButtonDown = 0;
+ int i, num_events;
+ ScreenPtr screen;
+ int valuators[5];
+
+ //DEBUG_LOG("x=%f, y=%f, p=%f, tx=%f, ty=%f\n", pointer_x, pointer_y, pressure, tilt_x, tilt_y);
+
+ if(!darwinEvents) {
+ DEBUG_LOG("DarwinSendPointerEvents called before darwinEvents was initialized\n");
+ return;
+ }
+
+ screen = miPointerGetScreen(pDev);
+ if(!screen) {
+ DEBUG_LOG("DarwinSendPointerEvents called before screen was initialized\n");
+ return;
+ }
+
+ /* Handle fake click */
+ if (ev_type == ButtonPress && darwinFakeButtons && ev_button == 1) {
+ if(darwinFakeMouseButtonDown != 0) {
+ /* We're currently "down" with another button, so release it first */
+ DarwinSendPointerEvents(pDev, ButtonRelease, darwinFakeMouseButtonDown, pointer_x, pointer_y, pressure, tilt_x, tilt_y);
+ darwinFakeMouseButtonDown=0;
+ }
+ if (darwin_all_modifier_flags & darwinFakeMouse2Mask) {
+ ev_button = 2;
+ darwinFakeMouseButtonDown = 2;
+ DarwinUpdateModKeys(darwin_all_modifier_flags & ~darwinFakeMouse2Mask);
+ } else if (darwin_all_modifier_flags & darwinFakeMouse3Mask) {
+ ev_button = 3;
+ darwinFakeMouseButtonDown = 3;
+ DarwinUpdateModKeys(darwin_all_modifier_flags & ~darwinFakeMouse3Mask);
+ }
+ }
+
+ if (ev_type == ButtonRelease && ev_button == 1) {
+ if(darwinFakeMouseButtonDown) {
+ ev_button = darwinFakeMouseButtonDown;
+ }
+
+ if(darwinFakeMouseButtonDown == 2) {
+ DarwinUpdateModKeys(darwin_all_modifier_flags & ~darwinFakeMouse2Mask);
+ } else if(darwinFakeMouseButtonDown == 3) {
+ DarwinUpdateModKeys(darwin_all_modifier_flags & ~darwinFakeMouse3Mask);
+ }
+
+ darwinFakeMouseButtonDown = 0;
+ }
+
+ DarwinPrepareValuators(pDev, valuators, screen, pointer_x, pointer_y, pressure, tilt_x, tilt_y);
+ darwinEvents_lock(); {
+ ValuatorMask mask;
+ valuator_mask_set_range(&mask, 0, (pDev == darwinPointer) ? 2 : 5, valuators);
+ num_events = GetPointerEvents(darwinEvents, pDev, ev_type, ev_button,
+ POINTER_ABSOLUTE, &mask);
+ for(i=0; i<num_events; i++) mieqEnqueue (pDev, (InternalEvent*)darwinEvents[i].event);
+ if(num_events > 0) DarwinPokeEQ();
+ } darwinEvents_unlock();
+}
+
+void DarwinSendKeyboardEvents(int ev_type, int keycode) {
+ int i, num_events;
+
+ if(!darwinEvents) {
+ DEBUG_LOG("DarwinSendKeyboardEvents called before darwinEvents was initialized\n");
+ return;
+ }
+
+ darwinEvents_lock(); {
+ num_events = GetKeyboardEvents(darwinEvents, darwinKeyboard, ev_type, keycode + MIN_KEYCODE, NULL);
+ for(i=0; i<num_events; i++) mieqEnqueue(darwinKeyboard, (InternalEvent*)darwinEvents[i].event);
+ if(num_events > 0) DarwinPokeEQ();
+ } darwinEvents_unlock();
+}
+
+void DarwinSendProximityEvents(DeviceIntPtr pDev, int ev_type, float pointer_x, float pointer_y,
+ float pressure, float tilt_x, float tilt_y) {
+ int i, num_events;
+ ScreenPtr screen;
+ int valuators[5];
+
+ DEBUG_LOG("DarwinSendProximityEvents: %d l:%f,%f p:%f t:%f,%f\n", ev_type, pointer_x, pointer_y, pressure, tilt_x, tilt_y);
+
+ if(!darwinEvents) {
+ DEBUG_LOG("DarwinSendProximityEvents called before darwinEvents was initialized\n");
+ return;
+ }
+
+ screen = miPointerGetScreen(pDev);
+ if(!screen) {
+ DEBUG_LOG("DarwinSendPointerEvents called before screen was initialized\n");
+ return;
+ }
+
+ DarwinPrepareValuators(pDev, valuators, screen, pointer_x, pointer_y, pressure, tilt_x, tilt_y);
+ darwinEvents_lock(); {
+ ValuatorMask mask;
+ valuator_mask_set_range(&mask, 0, 5, valuators);
+ num_events = GetProximityEvents(darwinEvents, pDev, ev_type, &mask);
+ for(i=0; i<num_events; i++) mieqEnqueue (pDev, (InternalEvent*)darwinEvents[i].event);
+ if(num_events > 0) DarwinPokeEQ();
+ } darwinEvents_unlock();
+}
+
+
+/* Send the appropriate number of button clicks to emulate scroll wheel */
+void DarwinSendScrollEvents(float count_x, float count_y,
+ float pointer_x, float pointer_y,
+ float pressure, float tilt_x, float tilt_y) {
+ int sign_x, sign_y;
+ if(!darwinEvents) {
+ DEBUG_LOG("DarwinSendScrollEvents called before darwinEvents was initialized\n");
+ return;
+ }
+
+ sign_x = count_x > 0.0f ? SCROLLWHEELLEFTFAKE : SCROLLWHEELRIGHTFAKE;
+ sign_y = count_y > 0.0f ? SCROLLWHEELUPFAKE : SCROLLWHEELDOWNFAKE;
+ count_x = fabs(count_x);
+ count_y = fabs(count_y);
+
+ while ((count_x > 0.0f) || (count_y > 0.0f)) {
+ if (count_x > 0.0f) {
+ DarwinSendPointerEvents(darwinPointer, ButtonPress, sign_x, pointer_x, pointer_y, pressure, tilt_x, tilt_y);
+ DarwinSendPointerEvents(darwinPointer, ButtonRelease, sign_x, pointer_x, pointer_y, pressure, tilt_x, tilt_y);
+ count_x = count_x - 1.0f;
+ }
+ if (count_y > 0.0f) {
+ DarwinSendPointerEvents(darwinPointer, ButtonPress, sign_y, pointer_x, pointer_y, pressure, tilt_x, tilt_y);
+ DarwinSendPointerEvents(darwinPointer, ButtonRelease, sign_y, pointer_x, pointer_y, pressure, tilt_x, tilt_y);
+ count_y = count_y - 1.0f;
+ }
+ }
+}
+
+/* Send the appropriate KeyPress/KeyRelease events to GetKeyboardEvents to
+ reflect changing modifier flags (alt, control, meta, etc) */
+void DarwinUpdateModKeys(int flags) {
+ DarwinUpdateModifiers(KeyRelease, darwin_all_modifier_flags & ~flags & darwin_x11_modifier_mask);
+ DarwinUpdateModifiers(KeyPress, ~darwin_all_modifier_flags & flags & darwin_x11_modifier_mask);
+ darwin_all_modifier_flags = flags;
+}
+
+/*
+ * DarwinSendDDXEvent
+ * Send the X server thread a message by placing it on the event queue.
+ */
+void DarwinSendDDXEvent(int type, int argc, ...) {
+ XQuartzEvent e;
+ int i;
+ va_list args;
+
+ memset(&e, 0, sizeof(e));
+ e.header = ET_Internal;
+ e.type = ET_XQuartz;
+ e.length = sizeof(e);
+ e.time = GetTimeInMillis();
+ e.subtype = type;
+
+ if (argc > 0 && argc < XQUARTZ_EVENT_MAXARGS) {
+ va_start (args, argc);
+ for (i = 0; i < argc; i++)
+ e.data[i] = (uint32_t) va_arg (args, uint32_t);
+ va_end (args);
+ }
+
+ darwinEvents_lock(); {
+ mieqEnqueue(NULL, (InternalEvent*)&e);
+ DarwinPokeEQ();
+ } darwinEvents_unlock();
+}
diff --git a/xorg-server/hw/xquartz/darwinEvents.h b/xorg-server/hw/xquartz/darwinEvents.h
index 590305f3e..a1414211a 100644
--- a/xorg-server/hw/xquartz/darwinEvents.h
+++ b/xorg-server/hw/xquartz/darwinEvents.h
@@ -1,89 +1,90 @@
-/*
- * Copyright (c) 2008 Apple, Inc.
- * Copyright (c) 2001-2004 Torrey T. Lyons. 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, sublicense,
- * 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 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 NONINFRINGEMENT. IN NO EVENT SHALL
- * THE ABOVE LISTED COPYRIGHT HOLDER(S) 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.
- *
- * Except as contained in this notice, the name(s) of the above copyright
- * holders shall not be used in advertising or otherwise to promote the sale,
- * use or other dealings in this Software without prior written authorization.
- */
-
-#ifndef _DARWIN_EVENTS_H
-#define _DARWIN_EVENTS_H
-
-/* For extra precision of our cursor and other valuators */
-#define XQUARTZ_VALUATOR_LIMIT (1 << 16)
-
-Bool DarwinEQInit(void);
-void DarwinEQEnqueue(const xEventPtr e);
-void DarwinEQPointerPost(DeviceIntPtr pDev, xEventPtr e);
-void DarwinEQSwitchScreen(ScreenPtr pScreen, Bool fromDIX);
-void DarwinSendPointerEvents(DeviceIntPtr pDev, int ev_type, int ev_button, float pointer_x, float pointer_y,
- float pressure, float tilt_x, float tilt_y);
-void DarwinSendProximityEvents(int ev_type, float pointer_x, float pointer_y);
-void DarwinSendKeyboardEvents(int ev_type, int keycode);
-void DarwinSendScrollEvents(float count_x, float count_y, float pointer_x, float pointer_y,
- float pressure, float tilt_x, float tilt_y);
-void DarwinUpdateModKeys(int flags);
-void DarwinListenOnOpenFD(int fd);
-
-/*
- * Subtypes for the ET_XQuartz event type
- */
-enum {
- kXquartzReloadKeymap, // Reload system keymap
- kXquartzActivate, // restore X drawing and cursor
- kXquartzDeactivate, // clip X drawing and switch to Aqua cursor
- kXquartzSetRootClip, // enable or disable drawing to the X screen
- kXquartzQuit, // kill the X server and release the display
- kXquartzBringAllToFront, // bring all X windows to front
- kXquartzToggleFullscreen, // Enable/Disable fullscreen mode
- kXquartzSetRootless, // Set rootless mode
- kXquartzSpaceChanged, // Spaces changed
- kXquartzListenOnOpenFD, // Listen to the launchd fd (passed as arg)
- /*
- * AppleWM events
- */
- kXquartzControllerNotify, // send an AppleWMControllerNotify event
- kXquartzPasteboardNotify, // notify the WM to copy or paste
- kXquartzReloadPreferences, // send AppleWMReloadPreferences
- /*
- * Xplugin notification events
- */
- kXquartzDisplayChanged, // display configuration has changed
- kXquartzWindowState, // window visibility state has changed
- kXquartzWindowMoved, // window has moved on screen
-};
-
-/* Send one of the above events to the server thread. */
-void DarwinSendDDXEvent(int type, int argc, ...);
-
-/* A mask of the modifiers that are in our X11 keyboard layout:
- * (Fn for example is just useful for 3button mouse emulation) */
-extern int darwin_all_modifier_mask;
-
-/* A mask of the modifiers that are in our X11 keyboard layout:
- * (Fn for example is just useful for 3button mouse emulation) */
-extern int darwin_x11_modifier_mask;
-
-/* The current state of the above listed modifiers */
-extern int darwin_all_modifier_flags;
-
-#endif /* _DARWIN_EVENTS_H */
+/*
+ * Copyright (c) 2008 Apple, Inc.
+ * Copyright (c) 2001-2004 Torrey T. Lyons. 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, sublicense,
+ * 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 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 NONINFRINGEMENT. IN NO EVENT SHALL
+ * THE ABOVE LISTED COPYRIGHT HOLDER(S) 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.
+ *
+ * Except as contained in this notice, the name(s) of the above copyright
+ * holders shall not be used in advertising or otherwise to promote the sale,
+ * use or other dealings in this Software without prior written authorization.
+ */
+
+#ifndef _DARWIN_EVENTS_H
+#define _DARWIN_EVENTS_H
+
+/* For extra precision of our cursor and other valuators */
+#define XQUARTZ_VALUATOR_LIMIT (1 << 16)
+
+Bool DarwinEQInit(void);
+void DarwinEQEnqueue(const xEventPtr e);
+void DarwinEQPointerPost(DeviceIntPtr pDev, xEventPtr e);
+void DarwinEQSwitchScreen(ScreenPtr pScreen, Bool fromDIX);
+void DarwinSendPointerEvents(DeviceIntPtr pDev, int ev_type, int ev_button, float pointer_x, float pointer_y,
+ float pressure, float tilt_x, float tilt_y);
+void DarwinSendProximityEvents(DeviceIntPtr pDev, int ev_type, float pointer_x, float pointer_y,
+ float pressure, float tilt_x, float tilt_y);
+void DarwinSendKeyboardEvents(int ev_type, int keycode);
+void DarwinSendScrollEvents(float count_x, float count_y, float pointer_x, float pointer_y,
+ float pressure, float tilt_x, float tilt_y);
+void DarwinUpdateModKeys(int flags);
+void DarwinListenOnOpenFD(int fd);
+
+/*
+ * Subtypes for the ET_XQuartz event type
+ */
+enum {
+ kXquartzReloadKeymap, // Reload system keymap
+ kXquartzActivate, // restore X drawing and cursor
+ kXquartzDeactivate, // clip X drawing and switch to Aqua cursor
+ kXquartzSetRootClip, // enable or disable drawing to the X screen
+ kXquartzQuit, // kill the X server and release the display
+ kXquartzBringAllToFront, // bring all X windows to front
+ kXquartzToggleFullscreen, // Enable/Disable fullscreen mode
+ kXquartzSetRootless, // Set rootless mode
+ kXquartzSpaceChanged, // Spaces changed
+ kXquartzListenOnOpenFD, // Listen to the launchd fd (passed as arg)
+ /*
+ * AppleWM events
+ */
+ kXquartzControllerNotify, // send an AppleWMControllerNotify event
+ kXquartzPasteboardNotify, // notify the WM to copy or paste
+ kXquartzReloadPreferences, // send AppleWMReloadPreferences
+ /*
+ * Xplugin notification events
+ */
+ kXquartzDisplayChanged, // display configuration has changed
+ kXquartzWindowState, // window visibility state has changed
+ kXquartzWindowMoved, // window has moved on screen
+};
+
+/* Send one of the above events to the server thread. */
+void DarwinSendDDXEvent(int type, int argc, ...);
+
+/* A mask of the modifiers that are in our X11 keyboard layout:
+ * (Fn for example is just useful for 3button mouse emulation) */
+extern int darwin_all_modifier_mask;
+
+/* A mask of the modifiers that are in our X11 keyboard layout:
+ * (Fn for example is just useful for 3button mouse emulation) */
+extern int darwin_x11_modifier_mask;
+
+/* The current state of the above listed modifiers */
+extern int darwin_all_modifier_flags;
+
+#endif /* _DARWIN_EVENTS_H */
diff --git a/xorg-server/hw/xquartz/mach-startup/bundle-main.c b/xorg-server/hw/xquartz/mach-startup/bundle-main.c
index aaff1c625..774dda664 100644
--- a/xorg-server/hw/xquartz/mach-startup/bundle-main.c
+++ b/xorg-server/hw/xquartz/mach-startup/bundle-main.c
@@ -40,14 +40,18 @@
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
-#include <pthread.h>
#include <stdbool.h>
#include <signal.h>
+#ifdef HAVE_LIBDISPATCH
+#include <dispatch/dispatch.h>
+#else
+#include <pthread.h>
+#endif
+
#include <sys/socket.h>
#include <sys/un.h>
-#include <sys/time.h>
#include <fcntl.h>
#include <mach/mach.h>
@@ -95,8 +99,9 @@ int server_main(int argc, char **argv, char **envp);
static int execute(const char *command);
static char *command_from_prefs(const char *key, const char *default_value);
+#ifndef HAVE_LIBDISPATCH
/*** Pthread Magics ***/
-static pthread_t create_thread(void *func, void *arg) {
+static pthread_t create_thread(void *(*func)(void *), void *arg) {
pthread_attr_t attr;
pthread_t tid;
@@ -108,6 +113,7 @@ static pthread_t create_thread(void *func, void *arg) {
return tid;
}
+#endif
/*** Mach-O IPC Stuffs ***/
@@ -200,11 +206,15 @@ typedef struct {
/* This thread accepts an incoming connection and hands off the file
* descriptor for the new connection to accept_fd_handoff()
*/
-static void socket_handoff_thread(void *arg) {
+#ifdef HAVE_LIBDISPATCH
+static void socket_handoff(socket_handoff_t *handoff_data) {
+#else
+static void *socket_handoff_thread(void *arg) {
socket_handoff_t *handoff_data = (socket_handoff_t *)arg;
+#endif
+
int launchd_fd = -1;
int connected_fd;
- unsigned remain;
/* Now actually get the passed file descriptor from this connection
* If we encounter an error, keep listening.
@@ -227,22 +237,13 @@ static void socket_handoff_thread(void *arg) {
close(handoff_data->fd);
unlink(handoff_data->filename);
free(handoff_data);
-
- /* TODO: Clean up this race better... giving xinitrc time to run... need to wait for 1.5 branch:
- *
- * From ajax:
- * There's already an internal callback chain for setting selection [in 1.5]
- * ownership. See the CallSelectionCallback at the bottom of
- * ProcSetSelectionOwner, and xfixes/select.c for an example of how to hook
- * into it.
- */
-
- remain = 3000000;
- fprintf(stderr, "X11.app: Received new $DISPLAY fd: %d ... sleeping to allow xinitrc to catchup.\n", launchd_fd);
- while((remain = usleep(remain)) > 0);
-
+
fprintf(stderr, "X11.app Handing off fd to server thread via DarwinListenOnOpenFD(%d)\n", launchd_fd);
DarwinListenOnOpenFD(launchd_fd);
+
+#ifndef HAVE_LIBDISPATCH
+ return NULL;
+#endif
}
static int create_socket(char *filename_out) {
@@ -311,8 +312,14 @@ kern_return_t do_request_fd_handoff_socket(mach_port_t port, string_t filename)
}
strlcpy(filename, handoff_data->filename, STRING_T_SIZE);
-
+
+#ifdef HAVE_LIBDISPATCH
+ dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT,0), ^{
+ socket_handoff(handoff_data);
+ });
+#else
create_thread(socket_handoff_thread, handoff_data);
+#endif
#ifdef DEBUG
fprintf(stderr, "X11.app: Thread created for handoff. Returning success to tell caller to connect and push the fd.\n");
diff --git a/xorg-server/hw/xwin/winkeybd.c b/xorg-server/hw/xwin/winkeybd.c
index e53d84b3f..dd854820f 100644
--- a/xorg-server/hw/xwin/winkeybd.c
+++ b/xorg-server/hw/xwin/winkeybd.c
@@ -500,7 +500,7 @@ winSendKeyEvent (DWORD dwKey, Bool fDown)
g_winKeyState[dwKey] = fDown;
GetEventList(&events);
- nevents = GetKeyboardEvents(events, g_pwinKeyboard, fDown ? KeyPress : KeyRelease, dwKey + MIN_KEYCODE);
+ nevents = GetKeyboardEvents(events, g_pwinKeyboard, fDown ? KeyPress : KeyRelease, dwKey + MIN_KEYCODE, NULL);
for (i = 0; i < nevents; i++)
mieqEnqueue(g_pwinKeyboard, (InternalEvent*)events[i].event);
diff --git a/xorg-server/include/dix-config.h.in b/xorg-server/include/dix-config.h.in
index 2c0f00b3e..81dc01d41 100644
--- a/xorg-server/include/dix-config.h.in
+++ b/xorg-server/include/dix-config.h.in
@@ -136,6 +136,9 @@
/* Define to 1 if you have the `m' library (-lm). */
#undef HAVE_LIBM
+/* Define to 1 if you have the libdispatch (GCD) available */
+#undef HAVE_LIBDISPATCH
+
/* Define to 1 if you have the `link' function. */
#undef HAVE_LINK
diff --git a/xorg-server/include/input.h b/xorg-server/include/input.h
index 7d818e0b8..2aa5dbb74 100644
--- a/xorg-server/include/input.h
+++ b/xorg-server/include/input.h
@@ -102,6 +102,7 @@ typedef unsigned long Leds;
typedef struct _OtherClients *OtherClientsPtr;
typedef struct _InputClients *InputClientsPtr;
typedef struct _DeviceIntRec *DeviceIntPtr;
+typedef struct _ValuatorClassRec *ValuatorClassPtr;
typedef struct _ClassesRec *ClassesPtr;
typedef struct _SpriteRec *SpritePtr;
typedef union _GrabMask GrabMask;
@@ -300,6 +301,10 @@ extern _X_EXPORT Bool InitButtonClassDeviceStruct(
Atom* /* labels */,
CARD8* /*map*/);
+extern _X_INTERNAL ValuatorClassPtr AllocValuatorClass(
+ ValuatorClassPtr src,
+ int numAxes);
+
extern _X_EXPORT Bool InitValuatorClassDeviceStruct(
DeviceIntPtr /*device*/,
int /*numAxes*/,
@@ -460,12 +465,6 @@ extern _X_EXPORT int GetKeyboardEvents(
EventListPtr events,
DeviceIntPtr pDev,
int type,
- int key_code);
-
-extern int GetKeyboardValuatorEvents(
- EventListPtr events,
- DeviceIntPtr pDev,
- int type,
int key_code,
const ValuatorMask *mask);
diff --git a/xorg-server/include/inputstr.h b/xorg-server/include/inputstr.h
index 4016524d2..80e8ad8c7 100644
--- a/xorg-server/include/inputstr.h
+++ b/xorg-server/include/inputstr.h
@@ -283,7 +283,7 @@ typedef struct _ValuatorClassRec {
unsigned short numAxes;
double *axisVal; /* always absolute, but device-coord system */
ValuatorAccelerationRec accelScheme;
-} ValuatorClassRec, *ValuatorClassPtr;
+} ValuatorClassRec;
typedef struct _ButtonClassRec {
int sourceid;
diff --git a/xorg-server/include/ptrveloc.h b/xorg-server/include/ptrveloc.h
index 1198146f1..081de448f 100644
--- a/xorg-server/include/ptrveloc.h
+++ b/xorg-server/include/ptrveloc.h
@@ -106,7 +106,7 @@ InitVelocityData(DeviceVelocityPtr vel);
extern _X_EXPORT void
InitTrackers(DeviceVelocityPtr vel, int ntracker);
-extern _X_EXPORT short
+extern _X_EXPORT BOOL
ProcessVelocityData2D(DeviceVelocityPtr vel, int dx, int dy, int time);
extern _X_EXPORT float
diff --git a/xorg-server/test/Makefile.am b/xorg-server/test/Makefile.am
index bf091d41d..80493b7a5 100644
--- a/xorg-server/test/Makefile.am
+++ b/xorg-server/test/Makefile.am
@@ -1,5 +1,4 @@
if ENABLE_UNIT_TESTS
-if HAVE_GLIB
if HAVE_LD_WRAP
SUBDIRS= . xi2
noinst_PROGRAMS = xkb input xtest list
@@ -7,9 +6,9 @@ check_LTLIBRARIES = libxservertest.la
TESTS=$(noinst_PROGRAMS)
-AM_CFLAGS = $(DIX_CFLAGS) $(GLIB_CFLAGS) @XORG_CFLAGS@
+AM_CFLAGS = $(DIX_CFLAGS) @XORG_CFLAGS@
INCLUDES = @XORG_INCS@
-TEST_LDADD=libxservertest.la $(XORG_SYS_LIBS) $(XSERVER_SYS_LIBS) $(GLIB_LIBS)
+TEST_LDADD=libxservertest.la $(XORG_SYS_LIBS) $(XSERVER_SYS_LIBS)
if SPECIAL_DTRACE_OBJECTS
TEST_LDADD += $(OS_LIB) $(DIX_LIB)
@@ -38,7 +37,6 @@ libxservertest_la_LIBADD = \
@XORG_LIBS@
endif
endif
-endif
CLEANFILES=libxservertest.c
diff --git a/xorg-server/test/input.c b/xorg-server/test/input.c
index 9a1ac632e..a54feffec 100644
--- a/xorg-server/test/input.c
+++ b/xorg-server/test/input.c
@@ -40,7 +40,7 @@
#include "dixgrabs.h"
#include "eventstr.h"
#include "inpututils.h"
-#include <glib.h>
+#include "assert.h"
/**
* Init a device with axes.
@@ -60,24 +60,24 @@ static void dix_init_valuators(void)
memset(&dev, 0, sizeof(DeviceIntRec));
dev.type = MASTER_POINTER; /* claim it's a master to stop ptracccel */
- g_assert(InitValuatorClassDeviceStruct(NULL, 0, atoms, 0, 0) == FALSE);
- g_assert(InitValuatorClassDeviceStruct(&dev, num_axes, atoms, 0, Absolute));
+ assert(InitValuatorClassDeviceStruct(NULL, 0, atoms, 0, 0) == FALSE);
+ assert(InitValuatorClassDeviceStruct(&dev, num_axes, atoms, 0, Absolute));
val = dev.valuator;
- g_assert(val);
- g_assert(val->numAxes == num_axes);
- g_assert(val->numMotionEvents == 0);
- g_assert(val->axisVal);
+ assert(val);
+ assert(val->numAxes == num_axes);
+ assert(val->numMotionEvents == 0);
+ assert(val->axisVal);
for (i = 0; i < num_axes; i++)
{
- g_assert(val->axisVal[i] == 0);
- g_assert(val->axes->min_value == NO_AXIS_LIMITS);
- g_assert(val->axes->max_value == NO_AXIS_LIMITS);
- g_assert(val->axes->mode == Absolute);
+ assert(val->axisVal[i] == 0);
+ assert(val->axes->min_value == NO_AXIS_LIMITS);
+ assert(val->axes->max_value == NO_AXIS_LIMITS);
+ assert(val->axes->mode == Absolute);
}
- g_assert(dev.last.numValuators == num_axes);
+ assert(dev.last.numValuators == num_axes);
}
/* just check the known success cases, and that error cases set the client's
@@ -97,48 +97,48 @@ static void dix_check_grab_values(void)
param.ownerEvents = FALSE;
rc = CheckGrabValues(&client, &param);
- g_assert(rc == Success);
+ assert(rc == Success);
param.this_device_mode = GrabModeAsync;
rc = CheckGrabValues(&client, &param);
- g_assert(rc == Success);
+ assert(rc == Success);
param.this_device_mode = GrabModeAsync + 1;
rc = CheckGrabValues(&client, &param);
- g_assert(rc == BadValue);
- g_assert(client.errorValue == param.this_device_mode);
- g_assert(client.errorValue == GrabModeAsync + 1);
+ assert(rc == BadValue);
+ assert(client.errorValue == param.this_device_mode);
+ assert(client.errorValue == GrabModeAsync + 1);
param.this_device_mode = GrabModeSync;
param.other_devices_mode = GrabModeAsync;
rc = CheckGrabValues(&client, &param);
- g_assert(rc == Success);
+ assert(rc == Success);
param.other_devices_mode = GrabModeAsync + 1;
rc = CheckGrabValues(&client, &param);
- g_assert(rc == BadValue);
- g_assert(client.errorValue == param.other_devices_mode);
- g_assert(client.errorValue == GrabModeAsync + 1);
+ assert(rc == BadValue);
+ assert(client.errorValue == param.other_devices_mode);
+ assert(client.errorValue == GrabModeAsync + 1);
param.other_devices_mode = GrabModeSync;
param.modifiers = 1 << 13;
rc = CheckGrabValues(&client, &param);
- g_assert(rc == BadValue);
- g_assert(client.errorValue == param.modifiers);
- g_assert(client.errorValue == (1 << 13));
+ assert(rc == BadValue);
+ assert(client.errorValue == param.modifiers);
+ assert(client.errorValue == (1 << 13));
param.modifiers = AnyModifier;
param.ownerEvents = TRUE;
rc = CheckGrabValues(&client, &param);
- g_assert(rc == Success);
+ assert(rc == Success);
param.ownerEvents = 3;
rc = CheckGrabValues(&client, &param);
- g_assert(rc == BadValue);
- g_assert(client.errorValue == param.ownerEvents);
- g_assert(client.errorValue == 3);
+ assert(rc == BadValue);
+ assert(client.errorValue == param.ownerEvents);
+ assert(client.errorValue == 3);
}
@@ -160,21 +160,21 @@ static void dix_event_to_core(int type)
/* EventToCore memsets the event to 0 */
#define test_event() \
- g_assert(rc == Success); \
- g_assert(core); \
- g_assert(count == 1); \
- g_assert(core->u.u.type == type); \
- g_assert(core->u.u.detail == detail); \
- g_assert(core->u.keyButtonPointer.time == time); \
- g_assert(core->u.keyButtonPointer.rootX == x); \
- g_assert(core->u.keyButtonPointer.rootY == y); \
- g_assert(core->u.keyButtonPointer.state == state); \
- g_assert(core->u.keyButtonPointer.eventX == 0); \
- g_assert(core->u.keyButtonPointer.eventY == 0); \
- g_assert(core->u.keyButtonPointer.root == ROOT_WINDOW_ID); \
- g_assert(core->u.keyButtonPointer.event == 0); \
- g_assert(core->u.keyButtonPointer.child == 0); \
- g_assert(core->u.keyButtonPointer.sameScreen == FALSE);
+ assert(rc == Success); \
+ assert(core); \
+ assert(count == 1); \
+ assert(core->u.u.type == type); \
+ assert(core->u.u.detail == detail); \
+ assert(core->u.keyButtonPointer.time == time); \
+ assert(core->u.keyButtonPointer.rootX == x); \
+ assert(core->u.keyButtonPointer.rootY == y); \
+ assert(core->u.keyButtonPointer.state == state); \
+ assert(core->u.keyButtonPointer.eventX == 0); \
+ assert(core->u.keyButtonPointer.eventY == 0); \
+ assert(core->u.keyButtonPointer.root == ROOT_WINDOW_ID); \
+ assert(core->u.keyButtonPointer.event == 0); \
+ assert(core->u.keyButtonPointer.child == 0); \
+ assert(core->u.keyButtonPointer.sameScreen == FALSE);
x = 0;
y = 0;
@@ -217,11 +217,11 @@ static void dix_event_to_core(int type)
ev.root_x = x;
ev.root_y = y;
rc = EventToCore((InternalEvent*)&ev, &core, &count);
- g_assert(rc == Success);
- g_assert(core);
- g_assert(count == 1);
- g_assert(core->u.keyButtonPointer.rootX != x);
- g_assert(core->u.keyButtonPointer.rootY != y);
+ assert(rc == Success);
+ assert(core);
+ assert(count == 1);
+ assert(core->u.keyButtonPointer.rootX != x);
+ assert(core->u.keyButtonPointer.rootY != y);
x = 0x7FFF;
y = 0x7FFF;
@@ -245,7 +245,7 @@ static void dix_event_to_core(int type)
detail = 0xFFF; /* too big */
ev.detail.key = detail;
rc = EventToCore((InternalEvent*)&ev, &core, &count);
- g_assert(rc == BadMatch);
+ assert(rc == BadMatch);
detail = 0xFF; /* too big */
ev.detail.key = detail;
@@ -257,11 +257,11 @@ static void dix_event_to_core(int type)
state = 0x10000; /* too big */
ev.corestate = state;
rc = EventToCore((InternalEvent*)&ev, &core, &count);
- g_assert(rc == Success);
- g_assert(core);
- g_assert(count == 1);
- g_assert(core->u.keyButtonPointer.state != state);
- g_assert(core->u.keyButtonPointer.state == (state & 0xFFFF));
+ assert(rc == Success);
+ assert(core);
+ assert(count == 1);
+ assert(core->u.keyButtonPointer.state != state);
+ assert(core->u.keyButtonPointer.state == (state & 0xFFFF));
#undef test_event
}
@@ -278,7 +278,7 @@ static void dix_event_to_core_fail(int evtype, int expected_rc)
ev.type = evtype;
rc = EventToCore((InternalEvent*)&ev, &core, &count);
- g_assert(rc == expected_rc);
+ assert(rc == expected_rc);
}
static void dix_event_to_core_conversion(void)
@@ -304,28 +304,28 @@ _dix_test_xi_convert(DeviceEvent *ev, int expected_rc, int expected_count)
int rc;
rc = EventToXI((InternalEvent*)ev, &xi, &count);
- g_assert(rc == expected_rc);
- g_assert(count >= expected_count);
+ assert(rc == expected_rc);
+ assert(count >= expected_count);
if (count > 0){
deviceKeyButtonPointer *kbp = (deviceKeyButtonPointer*)xi;
- g_assert(kbp->type == IEventBase + ev->type);
- g_assert(kbp->detail == ev->detail.key);
- g_assert(kbp->time == ev->time);
- g_assert((kbp->deviceid & ~MORE_EVENTS) == ev->deviceid);
- g_assert(kbp->root_x == ev->root_x);
- g_assert(kbp->root_y == ev->root_y);
- g_assert(kbp->state == ev->corestate);
- g_assert(kbp->event_x == 0);
- g_assert(kbp->event_y == 0);
- g_assert(kbp->root == ev->root);
- g_assert(kbp->event == 0);
- g_assert(kbp->child == 0);
- g_assert(kbp->same_screen == FALSE);
+ assert(kbp->type == IEventBase + ev->type);
+ assert(kbp->detail == ev->detail.key);
+ assert(kbp->time == ev->time);
+ assert((kbp->deviceid & ~MORE_EVENTS) == ev->deviceid);
+ assert(kbp->root_x == ev->root_x);
+ assert(kbp->root_y == ev->root_y);
+ assert(kbp->state == ev->corestate);
+ assert(kbp->event_x == 0);
+ assert(kbp->event_y == 0);
+ assert(kbp->root == ev->root);
+ assert(kbp->event == 0);
+ assert(kbp->child == 0);
+ assert(kbp->same_screen == FALSE);
while (--count > 0) {
deviceValuator *v = (deviceValuator*)&xi[count];
- g_assert(v->type == DeviceValuator);
- g_assert(v->num_valuators <= 6);
+ assert(v->type == DeviceValuator);
+ assert(v->num_valuators <= 6);
}
@@ -436,7 +436,7 @@ static void dix_event_to_xi1_conversion(void)
static void xi2_struct_sizes(void)
{
#define compare(req) \
- g_assert(sizeof(req) == sz_##req);
+ assert(sizeof(req) == sz_##req);
compare(xXIQueryVersionReq);
compare(xXIWarpPointerReq);
@@ -476,23 +476,23 @@ static void dix_grab_matching(void)
a.grabtype = GRABTYPE_CORE;
b.grabtype = GRABTYPE_XI2;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
a.grabtype = GRABTYPE_XI;
b.grabtype = GRABTYPE_XI2;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
a.grabtype = GRABTYPE_XI;
b.grabtype = GRABTYPE_CORE;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
/* XI2 grabs for different devices must fail, regardless of ignoreDevice
* XI2 grabs for master devices must fail against a slave */
@@ -516,28 +516,28 @@ static void dix_grab_matching(void)
b.device = &dev2;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
a.device = &dev2;
b.device = &dev1;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&a, &b, TRUE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
a.device = inputInfo.all_master_devices;
b.device = &dev1;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&a, &b, TRUE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
a.device = &dev1;
b.device = inputInfo.all_master_devices;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&a, &b, TRUE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
/* ignoreDevice FALSE must fail for different devices for CORE and XI */
a.grabtype = GRABTYPE_XI;
@@ -547,7 +547,7 @@ static void dix_grab_matching(void)
a.modifierDevice = &dev1;
b.modifierDevice = &dev1;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
a.grabtype = GRABTYPE_CORE;
b.grabtype = GRABTYPE_CORE;
@@ -556,7 +556,7 @@ static void dix_grab_matching(void)
a.modifierDevice = &dev1;
b.modifierDevice = &dev1;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
/* ignoreDevice FALSE must fail for different modifier devices for CORE
* and XI */
@@ -567,7 +567,7 @@ static void dix_grab_matching(void)
a.modifierDevice = &dev1;
b.modifierDevice = &dev2;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
a.grabtype = GRABTYPE_CORE;
b.grabtype = GRABTYPE_CORE;
@@ -576,7 +576,7 @@ static void dix_grab_matching(void)
a.modifierDevice = &dev1;
b.modifierDevice = &dev2;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
/* different event type must fail */
a.grabtype = GRABTYPE_XI2;
@@ -588,9 +588,9 @@ static void dix_grab_matching(void)
a.type = XI_KeyPress;
b.type = XI_KeyRelease;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&a, &b, TRUE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
a.grabtype = GRABTYPE_CORE;
b.grabtype = GRABTYPE_CORE;
@@ -601,9 +601,9 @@ static void dix_grab_matching(void)
a.type = XI_KeyPress;
b.type = XI_KeyRelease;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&a, &b, TRUE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
a.grabtype = GRABTYPE_XI;
b.grabtype = GRABTYPE_XI;
@@ -614,9 +614,9 @@ static void dix_grab_matching(void)
a.type = XI_KeyPress;
b.type = XI_KeyRelease;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&a, &b, TRUE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
/* different modifiers must fail */
a.grabtype = GRABTYPE_XI2;
@@ -630,23 +630,23 @@ static void dix_grab_matching(void)
a.modifiersDetail.exact = 1;
b.modifiersDetail.exact = 2;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
a.grabtype = GRABTYPE_CORE;
b.grabtype = GRABTYPE_CORE;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
a.grabtype = GRABTYPE_XI;
b.grabtype = GRABTYPE_XI;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
/* AnyModifier must fail for XI2 */
a.grabtype = GRABTYPE_XI2;
@@ -654,9 +654,9 @@ static void dix_grab_matching(void)
a.modifiersDetail.exact = AnyModifier;
b.modifiersDetail.exact = 1;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
/* XIAnyModifier must fail for CORE and XI */
a.grabtype = GRABTYPE_XI;
@@ -664,18 +664,18 @@ static void dix_grab_matching(void)
a.modifiersDetail.exact = XIAnyModifier;
b.modifiersDetail.exact = 1;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
a.grabtype = GRABTYPE_CORE;
b.grabtype = GRABTYPE_CORE;
a.modifiersDetail.exact = XIAnyModifier;
b.modifiersDetail.exact = 1;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
/* different detail must fail */
a.grabtype = GRABTYPE_XI2;
@@ -685,23 +685,23 @@ static void dix_grab_matching(void)
a.modifiersDetail.exact = 1;
b.modifiersDetail.exact = 1;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
a.grabtype = GRABTYPE_XI;
b.grabtype = GRABTYPE_XI;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
a.grabtype = GRABTYPE_CORE;
b.grabtype = GRABTYPE_CORE;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
/* detail of AnyModifier must fail */
a.grabtype = GRABTYPE_XI2;
@@ -711,23 +711,23 @@ static void dix_grab_matching(void)
a.modifiersDetail.exact = 1;
b.modifiersDetail.exact = 1;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
a.grabtype = GRABTYPE_CORE;
b.grabtype = GRABTYPE_CORE;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
a.grabtype = GRABTYPE_XI;
b.grabtype = GRABTYPE_XI;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
/* detail of XIAnyModifier must fail */
a.grabtype = GRABTYPE_XI2;
@@ -737,23 +737,23 @@ static void dix_grab_matching(void)
a.modifiersDetail.exact = 1;
b.modifiersDetail.exact = 1;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
a.grabtype = GRABTYPE_CORE;
b.grabtype = GRABTYPE_CORE;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
a.grabtype = GRABTYPE_XI;
b.grabtype = GRABTYPE_XI;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == FALSE);
+ assert(rc == FALSE);
/* XIAnyModifier or AnyModifer must succeed */
a.grabtype = GRABTYPE_XI2;
@@ -763,9 +763,9 @@ static void dix_grab_matching(void)
a.modifiersDetail.exact = XIAnyModifier;
b.modifiersDetail.exact = 1;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == TRUE);
+ assert(rc == TRUE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == TRUE);
+ assert(rc == TRUE);
a.grabtype = GRABTYPE_CORE;
b.grabtype = GRABTYPE_CORE;
@@ -774,9 +774,9 @@ static void dix_grab_matching(void)
a.modifiersDetail.exact = AnyModifier;
b.modifiersDetail.exact = 1;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == TRUE);
+ assert(rc == TRUE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == TRUE);
+ assert(rc == TRUE);
a.grabtype = GRABTYPE_XI;
b.grabtype = GRABTYPE_XI;
@@ -785,9 +785,9 @@ static void dix_grab_matching(void)
a.modifiersDetail.exact = AnyModifier;
b.modifiersDetail.exact = 1;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == TRUE);
+ assert(rc == TRUE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == TRUE);
+ assert(rc == TRUE);
/* AnyKey or XIAnyKeycode must succeed */
a.grabtype = GRABTYPE_XI2;
@@ -797,9 +797,9 @@ static void dix_grab_matching(void)
a.modifiersDetail.exact = 1;
b.modifiersDetail.exact = 1;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == TRUE);
+ assert(rc == TRUE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == TRUE);
+ assert(rc == TRUE);
a.grabtype = GRABTYPE_CORE;
b.grabtype = GRABTYPE_CORE;
@@ -808,9 +808,9 @@ static void dix_grab_matching(void)
a.modifiersDetail.exact = 1;
b.modifiersDetail.exact = 1;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == TRUE);
+ assert(rc == TRUE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == TRUE);
+ assert(rc == TRUE);
a.grabtype = GRABTYPE_XI;
b.grabtype = GRABTYPE_XI;
@@ -819,9 +819,9 @@ static void dix_grab_matching(void)
a.modifiersDetail.exact = 1;
b.modifiersDetail.exact = 1;
rc = GrabMatchesSecond(&a, &b, FALSE);
- g_assert(rc == TRUE);
+ assert(rc == TRUE);
rc = GrabMatchesSecond(&b, &a, FALSE);
- g_assert(rc == TRUE);
+ assert(rc == TRUE);
}
static void test_bits_to_byte(int i)
@@ -829,9 +829,9 @@ static void test_bits_to_byte(int i)
int expected_bytes;
expected_bytes = (i + 7)/8;
- g_assert(bits_to_bytes(i) >= i/8);
- g_assert((bits_to_bytes(i) * 8) - i <= 7);
- g_assert(expected_bytes == bits_to_bytes(i));
+ assert(bits_to_bytes(i) >= i/8);
+ assert((bits_to_bytes(i) * 8) - i <= 7);
+ assert(expected_bytes == bits_to_bytes(i));
}
static void test_bytes_to_int32(int i)
@@ -839,9 +839,9 @@ static void test_bytes_to_int32(int i)
int expected_4byte;
expected_4byte = (i + 3)/4;
- g_assert(bytes_to_int32(i) <= i);
- g_assert((bytes_to_int32(i) * 4) - i <= 3);
- g_assert(expected_4byte == bytes_to_int32(i));
+ assert(bytes_to_int32(i) <= i);
+ assert((bytes_to_int32(i) * 4) - i <= 3);
+ assert(expected_4byte == bytes_to_int32(i));
}
static void test_pad_to_int32(int i)
@@ -849,13 +849,13 @@ static void test_pad_to_int32(int i)
int expected_bytes;
expected_bytes = ((i + 3)/4) * 4;
- g_assert(pad_to_int32(i) >= i);
- g_assert(pad_to_int32(i) - i <= 3);
- g_assert(expected_bytes == pad_to_int32(i));
+ assert(pad_to_int32(i) >= i);
+ assert(pad_to_int32(i) - i <= 3);
+ assert(expected_bytes == pad_to_int32(i));
}
static void include_byte_padding_macros(void)
{
- g_test_message("Testing bits_to_bytes()");
+ printf("Testing bits_to_bytes()\n");
/* the macros don't provide overflow protection */
test_bits_to_byte(0);
@@ -868,7 +868,7 @@ static void include_byte_padding_macros(void)
test_bits_to_byte(INT_MAX - 9);
test_bits_to_byte(INT_MAX - 8);
- g_test_message("Testing bytes_to_int32()");
+ printf("Testing bytes_to_int32()\n");
test_bytes_to_int32(0);
test_bytes_to_int32(1);
@@ -884,7 +884,7 @@ static void include_byte_padding_macros(void)
test_bytes_to_int32(INT_MAX - 4);
test_bytes_to_int32(INT_MAX - 3);
- g_test_message("Testing pad_to_int32");
+ printf("Testing pad_to_int32\n");
test_pad_to_int32(0);
test_pad_to_int32(0);
@@ -910,47 +910,47 @@ static void xi_unregister_handlers(void)
memset(&dev, 0, sizeof(dev));
handler = XIRegisterPropertyHandler(&dev, NULL, NULL, NULL);
- g_assert(handler == 1);
+ assert(handler == 1);
handler = XIRegisterPropertyHandler(&dev, NULL, NULL, NULL);
- g_assert(handler == 2);
+ assert(handler == 2);
handler = XIRegisterPropertyHandler(&dev, NULL, NULL, NULL);
- g_assert(handler == 3);
+ assert(handler == 3);
- g_test_message("Unlinking from front.");
+ printf("Unlinking from front.\n");
XIUnregisterPropertyHandler(&dev, 4); /* NOOP */
- g_assert(dev.properties.handlers->id == 3);
+ assert(dev.properties.handlers->id == 3);
XIUnregisterPropertyHandler(&dev, 3);
- g_assert(dev.properties.handlers->id == 2);
+ assert(dev.properties.handlers->id == 2);
XIUnregisterPropertyHandler(&dev, 2);
- g_assert(dev.properties.handlers->id == 1);
+ assert(dev.properties.handlers->id == 1);
XIUnregisterPropertyHandler(&dev, 1);
- g_assert(dev.properties.handlers == NULL);
+ assert(dev.properties.handlers == NULL);
handler = XIRegisterPropertyHandler(&dev, NULL, NULL, NULL);
- g_assert(handler == 4);
+ assert(handler == 4);
handler = XIRegisterPropertyHandler(&dev, NULL, NULL, NULL);
- g_assert(handler == 5);
+ assert(handler == 5);
handler = XIRegisterPropertyHandler(&dev, NULL, NULL, NULL);
- g_assert(handler == 6);
+ assert(handler == 6);
XIUnregisterPropertyHandler(&dev, 3); /* NOOP */
- g_assert(dev.properties.handlers->next->next->next == NULL);
+ assert(dev.properties.handlers->next->next->next == NULL);
XIUnregisterPropertyHandler(&dev, 4);
- g_assert(dev.properties.handlers->next->next == NULL);
+ assert(dev.properties.handlers->next->next == NULL);
XIUnregisterPropertyHandler(&dev, 5);
- g_assert(dev.properties.handlers->next == NULL);
+ assert(dev.properties.handlers->next == NULL);
XIUnregisterPropertyHandler(&dev, 6);
- g_assert(dev.properties.handlers == NULL);
+ assert(dev.properties.handlers == NULL);
handler = XIRegisterPropertyHandler(&dev, NULL, NULL, NULL);
- g_assert(handler == 7);
+ assert(handler == 7);
handler = XIRegisterPropertyHandler(&dev, NULL, NULL, NULL);
- g_assert(handler == 8);
+ assert(handler == 8);
handler = XIRegisterPropertyHandler(&dev, NULL, NULL, NULL);
- g_assert(handler == 9);
+ assert(handler == 9);
XIDeleteAllDeviceProperties(&dev);
- g_assert(dev.properties.handlers == NULL);
+ assert(dev.properties.handlers == NULL);
XIUnregisterPropertyHandler(&dev, 7); /* NOOP */
}
@@ -960,44 +960,44 @@ static void cmp_attr_fields(InputAttributes *attr1,
{
char **tags1, **tags2;
- g_assert(attr1 && attr2);
- g_assert(attr1 != attr2);
- g_assert(attr1->flags == attr2->flags);
+ assert(attr1 && attr2);
+ assert(attr1 != attr2);
+ assert(attr1->flags == attr2->flags);
if (attr1->product != NULL)
{
- g_assert(attr1->product != attr2->product);
- g_assert(strcmp(attr1->product, attr2->product) == 0);
+ assert(attr1->product != attr2->product);
+ assert(strcmp(attr1->product, attr2->product) == 0);
} else
- g_assert(attr2->product == NULL);
+ assert(attr2->product == NULL);
if (attr1->vendor != NULL)
{
- g_assert(attr1->vendor != attr2->vendor);
- g_assert(strcmp(attr1->vendor, attr2->vendor) == 0);
+ assert(attr1->vendor != attr2->vendor);
+ assert(strcmp(attr1->vendor, attr2->vendor) == 0);
} else
- g_assert(attr2->vendor == NULL);
+ assert(attr2->vendor == NULL);
if (attr1->device != NULL)
{
- g_assert(attr1->device != attr2->device);
- g_assert(strcmp(attr1->device, attr2->device) == 0);
+ assert(attr1->device != attr2->device);
+ assert(strcmp(attr1->device, attr2->device) == 0);
} else
- g_assert(attr2->device == NULL);
+ assert(attr2->device == NULL);
if (attr1->pnp_id != NULL)
{
- g_assert(attr1->pnp_id != attr2->pnp_id);
- g_assert(strcmp(attr1->pnp_id, attr2->pnp_id) == 0);
+ assert(attr1->pnp_id != attr2->pnp_id);
+ assert(strcmp(attr1->pnp_id, attr2->pnp_id) == 0);
} else
- g_assert(attr2->pnp_id == NULL);
+ assert(attr2->pnp_id == NULL);
if (attr1->usb_id != NULL)
{
- g_assert(attr1->usb_id != attr2->usb_id);
- g_assert(strcmp(attr1->usb_id, attr2->usb_id) == 0);
+ assert(attr1->usb_id != attr2->usb_id);
+ assert(strcmp(attr1->usb_id, attr2->usb_id) == 0);
} else
- g_assert(attr2->usb_id == NULL);
+ assert(attr2->usb_id == NULL);
tags1 = attr1->tags;
tags2 = attr2->tags;
@@ -1005,25 +1005,25 @@ static void cmp_attr_fields(InputAttributes *attr1,
/* if we don't have any tags, skip the tag checking bits */
if (!tags1)
{
- g_assert(!tags2);
+ assert(!tags2);
return;
}
/* Don't lug around empty arrays */
- g_assert(*tags1);
- g_assert(*tags2);
+ assert(*tags1);
+ assert(*tags2);
/* check for identical content, but duplicated */
while (*tags1)
{
- g_assert(*tags1 != *tags2);
- g_assert(strcmp(*tags1, *tags2) == 0);
+ assert(*tags1 != *tags2);
+ assert(strcmp(*tags1, *tags2) == 0);
tags1++;
tags2++;
}
/* ensure tags1 and tags2 have the same no of elements */
- g_assert(!*tags2);
+ assert(!*tags2);
/* check for not sharing memory */
tags1 = attr1->tags;
@@ -1031,7 +1031,7 @@ static void cmp_attr_fields(InputAttributes *attr1,
{
tags2 = attr2->tags;
while (*tags2)
- g_assert(*tags1 != *tags2++);
+ assert(*tags1 != *tags2++);
tags1++;
}
@@ -1044,10 +1044,10 @@ static void dix_input_attributes(void)
char *tags[4] = {"tag1", "tag2", "tag2", NULL};
new = DuplicateInputAttributes(NULL);
- g_assert(!new);
+ assert(!new);
new = DuplicateInputAttributes(&orig);
- g_assert(memcmp(&orig, new, sizeof(InputAttributes)) == 0);
+ assert(memcmp(&orig, new, sizeof(InputAttributes)) == 0);
orig.product = "product name";
new = DuplicateInputAttributes(&orig);
@@ -1097,69 +1097,69 @@ static void dix_input_valuator_masks(void)
valuators[i] = i;
mask = valuator_mask_new(nvaluators);
- g_assert(mask != NULL);
- g_assert(valuator_mask_size(mask) == 0);
- g_assert(valuator_mask_num_valuators(mask) == 0);
+ assert(mask != NULL);
+ assert(valuator_mask_size(mask) == 0);
+ assert(valuator_mask_num_valuators(mask) == 0);
for (i = 0; i < nvaluators; i++)
{
- g_assert(!valuator_mask_isset(mask, i));
+ assert(!valuator_mask_isset(mask, i));
valuator_mask_set(mask, i, valuators[i]);
- g_assert(valuator_mask_isset(mask, i));
- g_assert(valuator_mask_get(mask, i) == valuators[i]);
- g_assert(valuator_mask_size(mask) == i + 1);
- g_assert(valuator_mask_num_valuators(mask) == i + 1);
+ assert(valuator_mask_isset(mask, i));
+ assert(valuator_mask_get(mask, i) == valuators[i]);
+ assert(valuator_mask_size(mask) == i + 1);
+ assert(valuator_mask_num_valuators(mask) == i + 1);
}
for (i = 0; i < nvaluators; i++)
{
- g_assert(valuator_mask_isset(mask, i));
+ assert(valuator_mask_isset(mask, i));
valuator_mask_unset(mask, i);
/* we're removing valuators from the front, so size should stay the
* same until the last bit is removed */
if (i < nvaluators - 1)
- g_assert(valuator_mask_size(mask) == nvaluators);
- g_assert(!valuator_mask_isset(mask, i));
+ assert(valuator_mask_size(mask) == nvaluators);
+ assert(!valuator_mask_isset(mask, i));
}
- g_assert(valuator_mask_size(mask) == 0);
+ assert(valuator_mask_size(mask) == 0);
valuator_mask_zero(mask);
- g_assert(valuator_mask_size(mask) == 0);
- g_assert(valuator_mask_num_valuators(mask) == 0);
+ assert(valuator_mask_size(mask) == 0);
+ assert(valuator_mask_num_valuators(mask) == 0);
for (i = 0; i < nvaluators; i++)
- g_assert(!valuator_mask_isset(mask, i));
+ assert(!valuator_mask_isset(mask, i));
first_val = 5;
num_vals = 6;
valuator_mask_set_range(mask, first_val, num_vals, valuators);
- g_assert(valuator_mask_size(mask) == first_val + num_vals);
- g_assert(valuator_mask_num_valuators(mask) == num_vals);
+ assert(valuator_mask_size(mask) == first_val + num_vals);
+ assert(valuator_mask_num_valuators(mask) == num_vals);
for (i = 0; i < nvaluators; i++)
{
if (i < first_val || i >= first_val + num_vals)
- g_assert(!valuator_mask_isset(mask, i));
+ assert(!valuator_mask_isset(mask, i));
else
{
- g_assert(valuator_mask_isset(mask, i));
- g_assert(valuator_mask_get(mask, i) == valuators[i - first_val]);
+ assert(valuator_mask_isset(mask, i));
+ assert(valuator_mask_get(mask, i) == valuators[i - first_val]);
}
}
copy = valuator_mask_new(nvaluators);
valuator_mask_copy(copy, mask);
- g_assert(mask != copy);
- g_assert(valuator_mask_size(mask) == valuator_mask_size(copy));
- g_assert(valuator_mask_num_valuators(mask) == valuator_mask_num_valuators(copy));
+ assert(mask != copy);
+ assert(valuator_mask_size(mask) == valuator_mask_size(copy));
+ assert(valuator_mask_num_valuators(mask) == valuator_mask_num_valuators(copy));
for (i = 0; i < nvaluators; i++)
{
- g_assert(valuator_mask_isset(mask, i) == valuator_mask_isset(copy, i));
- g_assert(valuator_mask_get(mask, i) == valuator_mask_get(copy, i));
+ assert(valuator_mask_isset(mask, i) == valuator_mask_isset(copy, i));
+ assert(valuator_mask_get(mask, i) == valuator_mask_get(copy, i));
}
valuator_mask_free(&mask);
- g_assert(mask == NULL);
+ assert(mask == NULL);
}
static void dix_valuator_mode(void)
@@ -1172,24 +1172,24 @@ static void dix_valuator_mode(void)
memset(&dev, 0, sizeof(DeviceIntRec));
dev.type = MASTER_POINTER; /* claim it's a master to stop ptracccel */
- g_assert(InitValuatorClassDeviceStruct(NULL, 0, atoms, 0, 0) == FALSE);
- g_assert(InitValuatorClassDeviceStruct(&dev, num_axes, atoms, 0, Absolute));
+ assert(InitValuatorClassDeviceStruct(NULL, 0, atoms, 0, 0) == FALSE);
+ assert(InitValuatorClassDeviceStruct(&dev, num_axes, atoms, 0, Absolute));
for (i = 0; i < num_axes; i++)
{
- g_assert(valuator_get_mode(&dev, i) == Absolute);
+ assert(valuator_get_mode(&dev, i) == Absolute);
valuator_set_mode(&dev, i, Relative);
- g_assert(dev.valuator->axes[i].mode == Relative);
- g_assert(valuator_get_mode(&dev, i) == Relative);
+ assert(dev.valuator->axes[i].mode == Relative);
+ assert(valuator_get_mode(&dev, i) == Relative);
}
valuator_set_mode(&dev, VALUATOR_MODE_ALL_AXES, Absolute);
for (i = 0; i < num_axes; i++)
- g_assert(valuator_get_mode(&dev, i) == Absolute);
+ assert(valuator_get_mode(&dev, i) == Absolute);
valuator_set_mode(&dev, VALUATOR_MODE_ALL_AXES, Relative);
for (i = 0; i < num_axes; i++)
- g_assert(valuator_get_mode(&dev, i) == Relative);
+ assert(valuator_get_mode(&dev, i) == Relative);
}
static void include_bit_test_macros(void)
@@ -1199,34 +1199,53 @@ static void include_bit_test_macros(void)
for (i = 0; i < sizeof(mask)/sizeof(mask[0]); i++)
{
- g_assert(BitIsOn(mask, i) == 0);
+ assert(BitIsOn(mask, i) == 0);
SetBit(mask, i);
- g_assert(BitIsOn(mask, i) == 1);
- g_assert(!!(mask[i/8] & (1 << (i % 8))));
- g_assert(CountBits(mask, sizeof(mask)) == 1);
+ assert(BitIsOn(mask, i) == 1);
+ assert(!!(mask[i/8] & (1 << (i % 8))));
+ assert(CountBits(mask, sizeof(mask)) == 1);
ClearBit(mask, i);
- g_assert(BitIsOn(mask, i) == 0);
+ assert(BitIsOn(mask, i) == 0);
}
}
+/**
+ * Ensure that val->axisVal and val->axes are aligned on doubles.
+ */
+static void dix_valuator_alloc(void)
+{
+ ValuatorClassPtr v = NULL;
+ int num_axes = 0;
+
+ while (num_axes < 5)
+ {
+ v = AllocValuatorClass(v, num_axes);
+
+ assert(v);
+ assert(v->numAxes == num_axes);
+ assert(((void*)v->axisVal - (void*)v) % sizeof(double) == 0);
+ assert(((void*)v->axes - (void*)v) % sizeof(double) == 0);
+ num_axes ++;
+ }
+
+ free(v);
+}
+
int main(int argc, char** argv)
{
- g_test_init(&argc, &argv,NULL);
- g_test_bug_base("https://bugzilla.freedesktop.org/show_bug.cgi?id=");
-
- g_test_add_func("/dix/input/valuator-masks", dix_input_valuator_masks);
- g_test_add_func("/dix/input/attributes", dix_input_attributes);
- g_test_add_func("/dix/input/init-valuators", dix_init_valuators);
- g_test_add_func("/dix/input/event-core-conversion", dix_event_to_core_conversion);
- g_test_add_func("/dix/input/event-xi1-conversion", dix_event_to_xi1_conversion);
- g_test_add_func("/dix/input/check-grab-values", dix_check_grab_values);
- g_test_add_func("/dix/input/xi2-struct-sizes", xi2_struct_sizes);
- g_test_add_func("/dix/input/grab_matching", dix_grab_matching);
- g_test_add_func("/dix/input/valuator_mode", dix_valuator_mode);
- g_test_add_func("/include/byte_padding_macros", include_byte_padding_macros);
- g_test_add_func("/include/bit_test_macros", include_bit_test_macros);
- g_test_add_func("/Xi/xiproperty/register-unregister", xi_unregister_handlers);
-
-
- return g_test_run();
+ dix_input_valuator_masks();
+ dix_input_attributes();
+ dix_init_valuators();
+ dix_event_to_core_conversion();
+ dix_event_to_xi1_conversion();
+ dix_check_grab_values();
+ xi2_struct_sizes();
+ dix_grab_matching();
+ dix_valuator_mode();
+ include_byte_padding_macros();
+ include_bit_test_macros();
+ xi_unregister_handlers();
+ dix_valuator_alloc();
+
+ return 0;
}
diff --git a/xorg-server/test/list.c b/xorg-server/test/list.c
index 7e035fe58..2b56f9b8d 100644
--- a/xorg-server/test/list.c
+++ b/xorg-server/test/list.c
@@ -28,7 +28,7 @@
#include <X11/Xlib.h>
#include <list.h>
#include <string.h>
-#include <glib.h>
+#include <assert.h>
struct parent {
int a;
@@ -56,10 +56,10 @@ test_list_init(void)
list_init(&parent.children);
/* test we haven't touched anything else. */
- g_assert(parent.a == tmp.a);
- g_assert(parent.b == tmp.b);
+ assert(parent.a == tmp.a);
+ assert(parent.b == tmp.b);
- g_assert(list_is_empty(&parent.children));
+ assert(list_is_empty(&parent.children));
}
static void
@@ -72,19 +72,19 @@ test_list_add(void)
list_init(&parent.children);
list_add(&child[0].node, &parent.children);
- g_assert(!list_is_empty(&parent.children));
+ assert(!list_is_empty(&parent.children));
c = list_first_entry(&parent.children, struct child, node);
- g_assert(memcmp(c, &child[0], sizeof(struct child)) == 0);
+ assert(memcmp(c, &child[0], sizeof(struct child)) == 0);
/* note: list_add prepends */
list_add(&child[1].node, &parent.children);
c = list_first_entry(&parent.children, struct child, node);
- g_assert(memcmp(c, &child[1], sizeof(struct child)) == 0);
+ assert(memcmp(c, &child[1], sizeof(struct child)) == 0);
list_add(&child[2].node, &parent.children);
c = list_first_entry(&parent.children, struct child, node);
- g_assert(memcmp(c, &child[2], sizeof(struct child)) == 0);
+ assert(memcmp(c, &child[2], sizeof(struct child)) == 0);
};
static void
@@ -97,40 +97,40 @@ test_list_del(void)
list_init(&parent.children);
list_add(&child[0].node, &parent.children);
- g_assert(!list_is_empty(&parent.children));
+ assert(!list_is_empty(&parent.children));
list_del(&parent.children);
- g_assert(list_is_empty(&parent.children));
+ assert(list_is_empty(&parent.children));
list_add(&child[0].node, &parent.children);
list_del(&child[0].node);
- g_assert(list_is_empty(&parent.children));
+ assert(list_is_empty(&parent.children));
list_add(&child[0].node, &parent.children);
list_add(&child[1].node, &parent.children);
c = list_first_entry(&parent.children, struct child, node);
- g_assert(memcmp(c, &child[1], sizeof(struct child)) == 0);
+ assert(memcmp(c, &child[1], sizeof(struct child)) == 0);
/* delete first node */
list_del(&child[1].node);
- g_assert(!list_is_empty(&parent.children));
- g_assert(list_is_empty(&child[1].node));
+ assert(!list_is_empty(&parent.children));
+ assert(list_is_empty(&child[1].node));
c = list_first_entry(&parent.children, struct child, node);
- g_assert(memcmp(c, &child[0], sizeof(struct child)) == 0);
+ assert(memcmp(c, &child[0], sizeof(struct child)) == 0);
/* delete last node */
list_add(&child[1].node, &parent.children);
list_del(&child[0].node);
c = list_first_entry(&parent.children, struct child, node);
- g_assert(memcmp(c, &child[1], sizeof(struct child)) == 0);
+ assert(memcmp(c, &child[1], sizeof(struct child)) == 0);
/* delete list head */
list_add(&child[0].node, &parent.children);
list_del(&parent.children);
- g_assert(list_is_empty(&parent.children));
- g_assert(!list_is_empty(&child[1].node));
- g_assert(!list_is_empty(&child[2].node));
+ assert(list_is_empty(&parent.children));
+ assert(!list_is_empty(&child[1].node));
+ assert(!list_is_empty(&child[2].node));
}
static void
@@ -148,29 +148,26 @@ test_list_for_each(void)
list_add(&child[0].node, &parent.children);
list_for_each_entry(c, &parent.children, node) {
- g_assert(memcmp(c, &child[i], sizeof(struct child)) == 0);
+ assert(memcmp(c, &child[i], sizeof(struct child)) == 0);
i++;
}
/* foreach on empty list */
list_del(&parent.children);
- g_assert(list_is_empty(&parent.children));
+ assert(list_is_empty(&parent.children));
list_for_each_entry(c, &parent.children, node) {
- g_assert(0); /* we must not get here */
+ assert(0); /* we must not get here */
}
}
int main(int argc, char** argv)
{
- g_test_init(&argc, &argv,NULL);
- g_test_bug_base("https://bugzilla.freedesktop.org/show_bug.cgi?id=");
+ test_list_init();
+ test_list_add();
+ test_list_del();
+ test_list_for_each();
- g_test_add_func("/list/init", test_list_init);
- g_test_add_func("/list/add", test_list_add);
- g_test_add_func("/list/del", test_list_del);
- g_test_add_func("/list/for_each", test_list_for_each);
-
- return g_test_run();
+ return 0;
}
diff --git a/xorg-server/test/xi2/Makefile.am b/xorg-server/test/xi2/Makefile.am
index c2d0b6e7c..3b69ed1a4 100644
--- a/xorg-server/test/xi2/Makefile.am
+++ b/xorg-server/test/xi2/Makefile.am
@@ -1,5 +1,4 @@
if ENABLE_UNIT_TESTS
-if HAVE_GLIB
if HAVE_LD_WRAP
noinst_PROGRAMS = \
protocol-xiqueryversion \
@@ -8,15 +7,16 @@ noinst_PROGRAMS = \
protocol-xigetselectedevents \
protocol-xisetclientpointer \
protocol-xigetclientpointer \
+ protocol-xipassivegrabdevice \
protocol-xiquerypointer \
protocol-xiwarppointer \
protocol-eventconvert
TESTS=$(noinst_PROGRAMS)
-AM_CFLAGS = $(DIX_CFLAGS) $(GLIB_CFLAGS) @XORG_CFLAGS@
+AM_CFLAGS = $(DIX_CFLAGS) @XORG_CFLAGS@
INCLUDES = @XORG_INCS@
-TEST_LDADD=../libxservertest.la $(XORG_SYS_LIBS) $(XSERVER_SYS_LIBS) $(GLIB_LIBS)
+TEST_LDADD=../libxservertest.la $(XORG_SYS_LIBS) $(XSERVER_SYS_LIBS)
COMMON_SOURCES=protocol-common.h protocol-common.c
if SPECIAL_DTRACE_OBJECTS
@@ -30,6 +30,7 @@ protocol_xigetselectedevents_LDADD=$(TEST_LDADD)
protocol_xisetclientpointer_LDADD=$(TEST_LDADD)
protocol_xigetclientpointer_LDADD=$(TEST_LDADD)
protocol_xiquerypointer_LDADD=$(TEST_LDADD)
+protocol_xipassivegrabdevice_LDADD=$(TEST_LDADD)
protocol_xiwarppointer_LDADD=$(TEST_LDADD)
protocol_eventconvert_LDADD=$(TEST_LDADD)
@@ -39,6 +40,7 @@ protocol_xiselectevents_LDFLAGS=$(AM_LDFLAGS) -Wl,-wrap,dixLookupWindow -Wl,-wra
protocol_xigetselectedevents_LDFLAGS=$(AM_LDFLAGS) -Wl,-wrap,WriteToClient -Wl,-wrap,dixLookupWindow -Wl,-wrap,AddResource
protocol_xisetclientpointer_LDFLAGS=$(AM_LDFLAGS) -Wl,-wrap,dixLookupClient
protocol_xigetclientpointer_LDFLAGS=$(AM_LDFLAGS) -Wl,-wrap,WriteToClient -Wl,-wrap,dixLookupClient
+protocol_xipassivegrabdevice_LDFLAGS=$(AM_LDFLAGS) -Wl,-wrap,GrabButton -Wl,-wrap,dixLookupWindow -Wl,-wrap,WriteToClient
protocol_xiquerypointer_LDFLAGS=$(AM_LDFLAGS) -Wl,-wrap,WriteToClient -Wl,-wrap,dixLookupWindow
protocol_xiwarppointer_LDFLAGS=$(AM_LDFLAGS) -Wl,-wrap,WriteToClient -Wl,-wrap,dixLookupWindow
@@ -49,7 +51,7 @@ protocol_xigetselectedevents_SOURCES=$(COMMON_SOURCES) protocol-xigetselectedeve
protocol_xisetclientpointer_SOURCES=$(COMMON_SOURCES) protocol-xisetclientpointer.c
protocol_xigetclientpointer_SOURCES=$(COMMON_SOURCES) protocol-xigetclientpointer.c
protocol_xiquerypointer_SOURCES=$(COMMON_SOURCES) protocol-xiquerypointer.c
+protocol_xipassivegrabdevice_SOURCES=$(COMMON_SOURCES) protocol-xipassivegrabdevice.c
protocol_xiwarppointer_SOURCES=$(COMMON_SOURCES) protocol-xiwarppointer.c
endif
endif
-endif
diff --git a/xorg-server/test/xi2/protocol-common.c b/xorg-server/test/xi2/protocol-common.c
index 86a7201b8..a414ad1fb 100644
--- a/xorg-server/test/xi2/protocol-common.c
+++ b/xorg-server/test/xi2/protocol-common.c
@@ -29,7 +29,6 @@
#include "extinit.h" /* for XInputExtensionInit */
#include "exglobals.h"
#include "xkbsrv.h" /* for XkbInitPrivates */
-#include <glib.h>
#include "protocol-common.h"
@@ -134,7 +133,7 @@ void init_window(WindowPtr window, WindowPtr parent, int id)
}
window->parent = parent;
window->optional = calloc(1, sizeof(WindowOptRec));
- g_assert(window->optional);
+ assert(window->optional);
}
extern DevPrivateKeyRec miPointerScreenKeyRec;
@@ -171,7 +170,7 @@ void init_simple(void)
void __wrap_WriteToClient(ClientPtr client, int len, void *data)
{
- g_assert(reply_handler != NULL);
+ assert(reply_handler != NULL);
(*reply_handler)(client, len, data, userdata);
}
diff --git a/xorg-server/test/xi2/protocol-common.h b/xorg-server/test/xi2/protocol-common.h
index afa08780c..d5559ba1a 100644
--- a/xorg-server/test/xi2/protocol-common.h
+++ b/xorg-server/test/xi2/protocol-common.h
@@ -1,153 +1,154 @@
-/**
- * Copyright © 2009 Red Hat, Inc.
- *
- * 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, sublicense,
- * 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 NONINFRINGEMENT. IN NO EVENT SHALL
- * THE AUTHORS OR COPYRIGHT HOLDERS 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.
- */
-
-#ifdef HAVE_DIX_CONFIG_H
-#include <dix-config.h>
-#endif
-
-#include "scrnintstr.h"
-#include "windowstr.h"
-#include "scrnintstr.h"
-#include "exevents.h"
-
-#ifndef PROTOCOL_COMMON_H
-#define PROTOCOL_COMMON_H
-
-extern int BadDevice;
-
-/* Check default values in a reply */
-#define reply_check_defaults(rep, len, type) \
- { \
- g_assert((len) >= sz_x##type##Reply); \
- g_assert((rep)->repType == X_Reply); \
- g_assert((rep)->RepType == X_##type); \
- g_assert((rep)->sequenceNumber == CLIENT_SEQUENCE); \
- g_assert((rep)->length >= (sz_x##type##Reply - 32)/4); \
- }
-
-/* initialise default values for request */
-#define request_init(req, type) \
- { \
- (req)->reqType = 128; /* doesn't matter */ \
- (req)->ReqType = X_##type; \
- (req)->length = (sz_x##type##Req >> 2); \
- }
-
-
-/* Various defines used in the tests. Some tests may use different values
- * than these defaults */
-/* default client index */
-#define CLIENT_INDEX 1
-/* default client mask for resources and windows */
-#define CLIENT_MASK ((CLIENT_INDEX) << CLIENTOFFSET)
-/* default client sequence number for replies */
-#define CLIENT_SEQUENCE 0x100
-/* default root window id */
-#define ROOT_WINDOW_ID 0x10
-/* default client window id */
-#define CLIENT_WINDOW_ID 0x100001
-/* invalid window ID. use for BadWindow checks. */
-#define INVALID_WINDOW_ID 0x111111
-/* initial fake sprite position */
-#define SPRITE_X 100
-#define SPRITE_Y 200
-
-
-/* Various structs used throughout the tests */
-
-
-/* The default devices struct, contains one pointer + keyboard and the
- * matching master devices. Initialize with init_devices() if needed. */
-struct devices {
- DeviceIntPtr vcp;
- DeviceIntPtr vck;
- DeviceIntPtr mouse;
- DeviceIntPtr kbd;
-
- int num_devices;
- int num_master_devices;
-} devices;
-
-/**
- * The set of default devices available in all tests if necessary.
- */
-extern struct devices devices;
-
-/**
- * test-specific userdata, passed into the reply handler.
- */
-extern void *userdata;
-/**
- * The reply handler called from WriteToClient. Set this handler if you need
- * to check the reply values.
- */
-void (*reply_handler)(ClientPtr client, int len, char *data, void *userdata);
-
-/**
- * The default screen used for the windows. Initialized by init_simple().
- */
-extern ScreenRec screen;
-/**
- * Semi-initialized root window. initialized by init().
- */
-extern WindowRec root;
-/**
- * Semi-initialized top-level window. initialized by init().
- */
-extern WindowRec window;
-
-/* various simple functions for quick setup */
-/**
- * Initialize the above struct with default devices and return the struct.
- * Usually not needed if you call ::init_simple.
- */
-struct devices init_devices(void);
-/**
- * Init a mostly zeroed out client with default values for index and mask.
- */
-ClientRec init_client(int request_len, void *request_data);
-/**
- * Init a mostly zeroed out window with the given window ID.
- * Usually not needed if you call ::init_simple which sets up root and
- * window.
- */
-void init_window(WindowPtr window, WindowPtr parent, int id);
-/**
- * Create a very simple setup that provides the minimum values for most
- * tests, including a screen, the root and client window and the default
- * device setup.
- */
-void init_simple(void);
-
-/* Declarations for various overrides in the test files. */
-void __wrap_WriteToClient(ClientPtr client, int len, void *data);
-int __wrap_XISetEventMask(DeviceIntPtr dev, WindowPtr win, int len, unsigned char* mask);
-int __wrap_dixLookupWindow(WindowPtr *win, XID id, ClientPtr client, Mask access);
-int __real_dixLookupWindow(WindowPtr *win, XID id, ClientPtr client, Mask access);
-Bool __wrap_AddResource(XID id, RESTYPE type, pointer value);
-int __wrap_dixLookupClient(ClientPtr *c, XID id, ClientPtr client, Mask access);
-int __real_dixLookupClient(ClientPtr *c, XID id, ClientPtr client, Mask access);
-
-
-#endif /* PROTOCOL_COMMON_H */
-
+/**
+ * Copyright © 2009 Red Hat, Inc.
+ *
+ * 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, sublicense,
+ * 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 NONINFRINGEMENT. IN NO EVENT SHALL
+ * THE AUTHORS OR COPYRIGHT HOLDERS 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.
+ */
+
+#ifdef HAVE_DIX_CONFIG_H
+#include <dix-config.h>
+#endif
+
+#include "scrnintstr.h"
+#include "windowstr.h"
+#include "scrnintstr.h"
+#include "exevents.h"
+#include <assert.h>
+
+#ifndef PROTOCOL_COMMON_H
+#define PROTOCOL_COMMON_H
+
+extern int BadDevice;
+
+/* Check default values in a reply */
+#define reply_check_defaults(rep, len, type) \
+ { \
+ assert((len) >= sz_x##type##Reply); \
+ assert((rep)->repType == X_Reply); \
+ assert((rep)->RepType == X_##type); \
+ assert((rep)->sequenceNumber == CLIENT_SEQUENCE); \
+ assert((rep)->length >= (sz_x##type##Reply - 32)/4); \
+ }
+
+/* initialise default values for request */
+#define request_init(req, type) \
+ { \
+ (req)->reqType = 128; /* doesn't matter */ \
+ (req)->ReqType = X_##type; \
+ (req)->length = (sz_x##type##Req >> 2); \
+ }
+
+
+/* Various defines used in the tests. Some tests may use different values
+ * than these defaults */
+/* default client index */
+#define CLIENT_INDEX 1
+/* default client mask for resources and windows */
+#define CLIENT_MASK ((CLIENT_INDEX) << CLIENTOFFSET)
+/* default client sequence number for replies */
+#define CLIENT_SEQUENCE 0x100
+/* default root window id */
+#define ROOT_WINDOW_ID 0x10
+/* default client window id */
+#define CLIENT_WINDOW_ID 0x100001
+/* invalid window ID. use for BadWindow checks. */
+#define INVALID_WINDOW_ID 0x111111
+/* initial fake sprite position */
+#define SPRITE_X 100
+#define SPRITE_Y 200
+
+
+/* Various structs used throughout the tests */
+
+
+/* The default devices struct, contains one pointer + keyboard and the
+ * matching master devices. Initialize with init_devices() if needed. */
+struct devices {
+ DeviceIntPtr vcp;
+ DeviceIntPtr vck;
+ DeviceIntPtr mouse;
+ DeviceIntPtr kbd;
+
+ int num_devices;
+ int num_master_devices;
+} devices;
+
+/**
+ * The set of default devices available in all tests if necessary.
+ */
+extern struct devices devices;
+
+/**
+ * test-specific userdata, passed into the reply handler.
+ */
+extern void *userdata;
+/**
+ * The reply handler called from WriteToClient. Set this handler if you need
+ * to check the reply values.
+ */
+void (*reply_handler)(ClientPtr client, int len, char *data, void *userdata);
+
+/**
+ * The default screen used for the windows. Initialized by init_simple().
+ */
+extern ScreenRec screen;
+/**
+ * Semi-initialized root window. initialized by init().
+ */
+extern WindowRec root;
+/**
+ * Semi-initialized top-level window. initialized by init().
+ */
+extern WindowRec window;
+
+/* various simple functions for quick setup */
+/**
+ * Initialize the above struct with default devices and return the struct.
+ * Usually not needed if you call ::init_simple.
+ */
+struct devices init_devices(void);
+/**
+ * Init a mostly zeroed out client with default values for index and mask.
+ */
+ClientRec init_client(int request_len, void *request_data);
+/**
+ * Init a mostly zeroed out window with the given window ID.
+ * Usually not needed if you call ::init_simple which sets up root and
+ * window.
+ */
+void init_window(WindowPtr window, WindowPtr parent, int id);
+/**
+ * Create a very simple setup that provides the minimum values for most
+ * tests, including a screen, the root and client window and the default
+ * device setup.
+ */
+void init_simple(void);
+
+/* Declarations for various overrides in the test files. */
+void __wrap_WriteToClient(ClientPtr client, int len, void *data);
+int __wrap_XISetEventMask(DeviceIntPtr dev, WindowPtr win, int len, unsigned char* mask);
+int __wrap_dixLookupWindow(WindowPtr *win, XID id, ClientPtr client, Mask access);
+int __real_dixLookupWindow(WindowPtr *win, XID id, ClientPtr client, Mask access);
+Bool __wrap_AddResource(XID id, RESTYPE type, pointer value);
+int __wrap_dixLookupClient(ClientPtr *c, XID id, ClientPtr client, Mask access);
+int __real_dixLookupClient(ClientPtr *c, XID id, ClientPtr client, Mask access);
+
+
+#endif /* PROTOCOL_COMMON_H */
+
diff --git a/xorg-server/test/xi2/protocol-eventconvert.c b/xorg-server/test/xi2/protocol-eventconvert.c
index 0478c33fe..35c68246d 100644
--- a/xorg-server/test/xi2/protocol-eventconvert.c
+++ b/xorg-server/test/xi2/protocol-eventconvert.c
@@ -1,917 +1,913 @@
-/**
- * Copyright © 2009 Red Hat, Inc.
- *
- * 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, sublicense,
- * 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 NONINFRINGEMENT. IN NO EVENT SHALL
- * THE AUTHORS OR COPYRIGHT HOLDERS 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.
- */
-
-#ifdef HAVE_DIX_CONFIG_H
-#include <dix-config.h>
-#endif
-
-#include <stdint.h>
-#include <glib.h>
-
-#include "inputstr.h"
-#include "eventstr.h"
-#include "eventconvert.h"
-#include "exevents.h"
-#include <X11/extensions/XI2proto.h>
-
-
-static void test_values_XIRawEvent(RawDeviceEvent *in, xXIRawEvent *out,
- BOOL swap)
-{
- int i;
- unsigned char *ptr;
- FP3232 *value, *raw_value;
- int nvals = 0;
- int bits_set;
- int len;
-
- if (swap)
- {
- char n;
-
- swaps(&out->sequenceNumber, n);
- swapl(&out->length, n);
- swaps(&out->evtype, n);
- swaps(&out->deviceid, n);
- swapl(&out->time, n);
- swapl(&out->detail, n);
- swaps(&out->valuators_len, n);
- }
-
-
- g_assert(out->type == GenericEvent);
- g_assert(out->extension == 0); /* IReqCode defaults to 0 */
- g_assert(out->evtype == GetXI2Type((InternalEvent*)in));
- g_assert(out->time == in->time);
- g_assert(out->detail == in->detail.button);
- g_assert(out->deviceid == in->deviceid);
- g_assert(out->valuators_len >= bytes_to_int32(bits_to_bytes(sizeof(in->valuators.mask))));
- g_assert(out->flags == 0); /* FIXME: we don't set the flags yet */
-
- ptr = (unsigned char*)&out[1];
- bits_set = 0;
-
- for (i = 0; out->valuators_len && i < sizeof(in->valuators.mask) * 8; i++)
- {
- g_assert (XIMaskIsSet(in->valuators.mask, i) == XIMaskIsSet(ptr, i));
- if (XIMaskIsSet(in->valuators.mask, i))
- bits_set++;
- }
-
- /* length is len of valuator mask (in 4-byte units) + the number of bits
- * set. Each bit set represents 2 8-byte values, hence the
- * 'bits_set * 4' */
- len = out->valuators_len + bits_set * 4;
- g_assert(out->length == len);
-
- nvals = 0;
-
- for (i = 0; out->valuators_len && i < MAX_VALUATORS; i++)
- {
- g_assert (XIMaskIsSet(in->valuators.mask, i) == XIMaskIsSet(ptr, i));
- if (XIMaskIsSet(in->valuators.mask, i))
- {
- FP3232 vi, vo;
- value = (FP3232*)(((unsigned char*)&out[1]) + out->valuators_len * 4);
- value += nvals;
-
- vi.integral = in->valuators.data[i];
- vi.frac = in->valuators.data_frac[i];
-
- vo.integral = value->integral;
- vo.frac = value->frac;
- if (swap)
- {
- char n;
- swapl(&vo.integral, n);
- swapl(&vo.frac, n);
- }
-
- g_assert(vi.integral == vo.integral);
- g_assert(vi.frac == vo.frac);
-
- raw_value = value + bits_set;
-
- vi.integral = in->valuators.data_raw[i];
- vi.frac = in->valuators.data_raw_frac[i];
-
- vo.integral = raw_value->integral;
- vo.frac = raw_value->frac;
- if (swap)
- {
- char n;
- swapl(&vo.integral, n);
- swapl(&vo.frac, n);
- }
-
- g_assert(vi.integral == vo.integral);
- g_assert(vi.frac == vo.frac);
-
- nvals++;
- }
- }
-}
-
-static void test_XIRawEvent(RawDeviceEvent *in)
-{
- xXIRawEvent *out, *swapped;
- int rc;
-
- rc = EventToXI2((InternalEvent*)in, (xEvent**)&out);
- g_assert(rc == Success);
-
- test_values_XIRawEvent(in, out, FALSE);
-
- swapped = calloc(1, sizeof(xEvent) + out->length * 4);
- XI2EventSwap((xGenericEvent*)out, (xGenericEvent*)swapped);
- test_values_XIRawEvent(in, swapped, TRUE);
-
- free(out);
- free(swapped);
-}
-
-static void test_convert_XIFocusEvent(void)
-{
- xEvent *out;
- DeviceEvent in;
- int rc;
-
- in.header = ET_Internal;
- in.type = ET_Enter;
- rc = EventToXI2((InternalEvent*)&in, &out);
- g_assert(rc == Success);
- g_assert(out == NULL);
-
- in.header = ET_Internal;
- in.type = ET_FocusIn;
- rc = EventToXI2((InternalEvent*)&in, &out);
- g_assert(rc == Success);
- g_assert(out == NULL);
-
- in.header = ET_Internal;
- in.type = ET_FocusOut;
- rc = EventToXI2((InternalEvent*)&in, &out);
- g_assert(rc == BadImplementation);
-
- in.header = ET_Internal;
- in.type = ET_Leave;
- rc = EventToXI2((InternalEvent*)&in, &out);
- g_assert(rc == BadImplementation);
-}
-
-
-static void test_convert_XIRawEvent(void)
-{
- RawDeviceEvent in;
- int i;
-
- memset(&in, 0, sizeof(in));
-
- g_test_message("Testing all event types");
- in.header = ET_Internal;
- in.type = ET_RawMotion;
- test_XIRawEvent(&in);
-
- in.header = ET_Internal;
- in.type = ET_RawKeyPress;
- test_XIRawEvent(&in);
-
- in.header = ET_Internal;
- in.type = ET_RawKeyRelease;
- test_XIRawEvent(&in);
-
- in.header = ET_Internal;
- in.type = ET_RawButtonPress;
- test_XIRawEvent(&in);
-
- in.header = ET_Internal;
- in.type = ET_RawButtonRelease;
- test_XIRawEvent(&in);
-
- g_test_message("Testing details and other fields");
- in.detail.button = 1L;
- test_XIRawEvent(&in);
- in.detail.button = 1L << 8;
- test_XIRawEvent(&in);
- in.detail.button = 1L << 16;
- test_XIRawEvent(&in);
- in.detail.button = 1L << 24;
- test_XIRawEvent(&in);
- in.detail.button = ~0L;
- test_XIRawEvent(&in);
-
- in.detail.button = 0;
-
- in.time = 1L;
- test_XIRawEvent(&in);
- in.time = 1L << 8;
- test_XIRawEvent(&in);
- in.time = 1L << 16;
- test_XIRawEvent(&in);
- in.time = 1L << 24;
- test_XIRawEvent(&in);
- in.time = ~0L;
- test_XIRawEvent(&in);
-
- in.deviceid = 1;
- test_XIRawEvent(&in);
- in.deviceid = 1 << 8;
- test_XIRawEvent(&in);
- in.deviceid = ~0 & 0xFF;
- test_XIRawEvent(&in);
-
- g_test_message("Testing valuator masks");
- for (i = 0; i < sizeof(in.valuators.mask) * 8; i++)
- {
- XISetMask(in.valuators.mask, i);
- test_XIRawEvent(&in);
- XIClearMask(in.valuators.mask, i);
- }
-
- for (i = 0; i < MAX_VALUATORS; i++)
- {
- XISetMask(in.valuators.mask, i);
-
- in.valuators.data[i] = i;
- in.valuators.data_raw[i] = i + 10;
- in.valuators.data_frac[i] = i + 20;
- in.valuators.data_raw_frac[i] = i + 30;
- test_XIRawEvent(&in);
- XIClearMask(in.valuators.mask, i);
- }
-
- for (i = 0; i < sizeof(in.valuators.mask) * 8; i++)
- {
- XISetMask(in.valuators.mask, i);
- test_XIRawEvent(&in);
- }
-}
-
-static void test_values_XIDeviceEvent(DeviceEvent *in, xXIDeviceEvent *out,
- BOOL swap)
-{
- int buttons, valuators;
- int i;
- unsigned char *ptr;
- uint32_t flagmask = 0;
- FP3232 *values;
-
- if (swap) {
- char n;
-
- swaps(&out->sequenceNumber, n);
- swapl(&out->length, n);
- swaps(&out->evtype, n);
- swaps(&out->deviceid, n);
- swaps(&out->sourceid, n);
- swapl(&out->time, n);
- swapl(&out->detail, n);
- swapl(&out->root, n);
- swapl(&out->event, n);
- swapl(&out->child, n);
- swapl(&out->root_x, n);
- swapl(&out->root_y, n);
- swapl(&out->event_x, n);
- swapl(&out->event_y, n);
- swaps(&out->buttons_len, n);
- swaps(&out->valuators_len, n);
- swapl(&out->mods.base_mods, n);
- swapl(&out->mods.latched_mods, n);
- swapl(&out->mods.locked_mods, n);
- swapl(&out->mods.effective_mods, n);
- swapl(&out->flags, n);
- }
-
- g_assert(out->extension == 0); /* IReqCode defaults to 0 */
- g_assert(out->evtype == GetXI2Type((InternalEvent*)in));
- g_assert(out->time == in->time);
- g_assert(out->detail == in->detail.button);
- g_assert(out->length >= 12);
-
- g_assert(out->deviceid == in->deviceid);
- g_assert(out->sourceid == in->sourceid);
-
- switch (in->type) {
- case ET_KeyPress:
- flagmask = XIKeyRepeat;
- break;
- default:
- flagmask = 0;
- break;
- }
- g_assert((out->flags & ~flagmask) == 0);
-
- g_assert(out->root == in->root);
- g_assert(out->event == None); /* set in FixUpEventFromWindow */
- g_assert(out->child == None); /* set in FixUpEventFromWindow */
-
- g_assert(out->mods.base_mods == in->mods.base);
- g_assert(out->mods.latched_mods == in->mods.latched);
- g_assert(out->mods.locked_mods == in->mods.locked);
- g_assert(out->mods.effective_mods == in->mods.effective);
-
- g_assert(out->group.base_group == in->group.base);
- g_assert(out->group.latched_group == in->group.latched);
- g_assert(out->group.locked_group == in->group.locked);
- g_assert(out->group.effective_group == in->group.effective);
-
- g_assert(out->event_x == 0); /* set in FixUpEventFromWindow */
- g_assert(out->event_y == 0); /* set in FixUpEventFromWindow */
-
- g_assert(out->root_x == FP1616(in->root_x, in->root_x_frac));
- g_assert(out->root_y == FP1616(in->root_y, in->root_y_frac));
-
- buttons = 0;
- for (i = 0; i < bits_to_bytes(sizeof(in->buttons)); i++)
- {
- if (XIMaskIsSet(in->buttons, i))
- {
- g_assert(out->buttons_len >= bytes_to_int32(bits_to_bytes(i)));
- buttons++;
- }
- }
-
- ptr = (unsigned char*)&out[1];
- for (i = 0; i < sizeof(in->buttons) * 8; i++)
- g_assert(XIMaskIsSet(in->buttons, i) == XIMaskIsSet(ptr, i));
-
-
- valuators = 0;
- for (i = 0; i < sizeof(in->valuators.mask) * 8; i++)
- if (XIMaskIsSet(in->valuators.mask, i))
- valuators++;
-
- g_assert(out->valuators_len >= bytes_to_int32(bits_to_bytes(valuators)));
-
- ptr += out->buttons_len * 4;
- values = (FP3232*)(ptr + out->valuators_len * 4);
- for (i = 0; i < sizeof(in->valuators.mask) * 8 ||
- i < (out->valuators_len * 4) * 8; i++)
- {
- if (i > sizeof(in->valuators.mask) * 8)
- g_assert(!XIMaskIsSet(ptr, i));
- else if (i > out->valuators_len * 4 * 8)
- g_assert(!XIMaskIsSet(in->valuators.mask, i));
- else {
- g_assert(XIMaskIsSet(in->valuators.mask, i) ==
- XIMaskIsSet(ptr, i));
-
- if (XIMaskIsSet(ptr, i))
- {
- FP3232 vi, vo;
-
- vi.integral = in->valuators.data[i];
- vi.frac = in->valuators.data_frac[i];
-
- vo = *values;
-
- if (swap)
- {
- char n;
- swapl(&vo.integral, n);
- swapl(&vo.frac, n);
- }
-
-
- g_assert(vi.integral == vo.integral);
- g_assert(vi.frac == vo.frac);
- values++;
- }
- }
- }
-}
-
-static void test_XIDeviceEvent(DeviceEvent *in)
-{
- xXIDeviceEvent *out, *swapped;
- int rc;
-
- rc = EventToXI2((InternalEvent*)in, (xEvent**)&out);
- g_assert(rc == Success);
-
- test_values_XIDeviceEvent(in, out, FALSE);
-
- swapped = calloc(1, sizeof(xEvent) + out->length * 4);
- XI2EventSwap((xGenericEvent*)out, (xGenericEvent*)swapped);
- test_values_XIDeviceEvent(in, swapped, TRUE);
-
- free(out);
- free(swapped);
-}
-
-static void test_convert_XIDeviceEvent(void)
-{
- DeviceEvent in;
- int i;
-
- memset(&in, 0, sizeof(in));
-
- g_test_message("Testing simple field values");
- in.header = ET_Internal;
- in.type = ET_Motion;
- in.length = sizeof(DeviceEvent);
- in.time = 0;
- in.deviceid = 1;
- in.sourceid = 2;
- in.root = 3;
- in.root_x = 4;
- in.root_x_frac = 5;
- in.root_y = 6;
- in.root_y_frac = 7;
- in.detail.button = 8;
- in.mods.base = 9;
- in.mods.latched = 10;
- in.mods.locked = 11;
- in.mods.effective = 11;
- in.group.base = 12;
- in.group.latched = 13;
- in.group.locked = 14;
- in.group.effective = 15;
-
- test_XIDeviceEvent(&in);
-
- g_test_message("Testing field ranges");
- /* 32 bit */
- in.detail.button = 1L;
- test_XIDeviceEvent(&in);
- in.detail.button = 1L << 8;
- test_XIDeviceEvent(&in);
- in.detail.button = 1L << 16;
- test_XIDeviceEvent(&in);
- in.detail.button = 1L << 24;
- test_XIDeviceEvent(&in);
- in.detail.button = ~0L;
- test_XIDeviceEvent(&in);
-
- /* 32 bit */
- in.time = 1L;
- test_XIDeviceEvent(&in);
- in.time = 1L << 8;
- test_XIDeviceEvent(&in);
- in.time = 1L << 16;
- test_XIDeviceEvent(&in);
- in.time = 1L << 24;
- test_XIDeviceEvent(&in);
- in.time = ~0L;
- test_XIDeviceEvent(&in);
-
- /* 16 bit */
- in.deviceid = 1;
- test_XIDeviceEvent(&in);
- in.deviceid = 1 << 8;
- test_XIDeviceEvent(&in);
- in.deviceid = ~0 & 0xFF;
- test_XIDeviceEvent(&in);
-
- /* 16 bit */
- in.sourceid = 1;
- test_XIDeviceEvent(&in);
- in.deviceid = 1 << 8;
- test_XIDeviceEvent(&in);
- in.deviceid = ~0 & 0xFF;
- test_XIDeviceEvent(&in);
-
- /* 32 bit */
- in.root = 1L;
- test_XIDeviceEvent(&in);
- in.root = 1L << 8;
- test_XIDeviceEvent(&in);
- in.root = 1L << 16;
- test_XIDeviceEvent(&in);
- in.root = 1L << 24;
- test_XIDeviceEvent(&in);
- in.root = ~0L;
- test_XIDeviceEvent(&in);
-
- /* 16 bit */
- in.root_x = 1;
- test_XIDeviceEvent(&in);
- in.root_x = 1 << 8;
- test_XIDeviceEvent(&in);
- in.root_x = ~0 & 0xFF;
- test_XIDeviceEvent(&in);
-
- in.root_x_frac = 1;
- test_XIDeviceEvent(&in);
- in.root_x_frac = 1 << 8;
- test_XIDeviceEvent(&in);
- in.root_x_frac = ~0 & 0xFF;
- test_XIDeviceEvent(&in);
-
- in.root_y = 1;
- test_XIDeviceEvent(&in);
- in.root_y = 1 << 8;
- test_XIDeviceEvent(&in);
- in.root_y = ~0 & 0xFF;
- test_XIDeviceEvent(&in);
-
- in.root_y_frac = 1;
- test_XIDeviceEvent(&in);
- in.root_y_frac = 1 << 8;
- test_XIDeviceEvent(&in);
- in.root_y_frac = ~0 & 0xFF;
- test_XIDeviceEvent(&in);
-
- /* 32 bit */
- in.mods.base = 1L;
- test_XIDeviceEvent(&in);
- in.mods.base = 1L << 8;
- test_XIDeviceEvent(&in);
- in.mods.base = 1L << 16;
- test_XIDeviceEvent(&in);
- in.mods.base = 1L << 24;
- test_XIDeviceEvent(&in);
- in.mods.base = ~0L;
- test_XIDeviceEvent(&in);
-
- in.mods.latched = 1L;
- test_XIDeviceEvent(&in);
- in.mods.latched = 1L << 8;
- test_XIDeviceEvent(&in);
- in.mods.latched = 1L << 16;
- test_XIDeviceEvent(&in);
- in.mods.latched = 1L << 24;
- test_XIDeviceEvent(&in);
- in.mods.latched = ~0L;
- test_XIDeviceEvent(&in);
-
- in.mods.locked = 1L;
- test_XIDeviceEvent(&in);
- in.mods.locked = 1L << 8;
- test_XIDeviceEvent(&in);
- in.mods.locked = 1L << 16;
- test_XIDeviceEvent(&in);
- in.mods.locked = 1L << 24;
- test_XIDeviceEvent(&in);
- in.mods.locked = ~0L;
- test_XIDeviceEvent(&in);
-
- in.mods.effective = 1L;
- test_XIDeviceEvent(&in);
- in.mods.effective = 1L << 8;
- test_XIDeviceEvent(&in);
- in.mods.effective = 1L << 16;
- test_XIDeviceEvent(&in);
- in.mods.effective = 1L << 24;
- test_XIDeviceEvent(&in);
- in.mods.effective = ~0L;
- test_XIDeviceEvent(&in);
-
- /* 8 bit */
- in.group.base = 1;
- test_XIDeviceEvent(&in);
- in.group.base = ~0 & 0xFF;
- test_XIDeviceEvent(&in);
-
- in.group.latched = 1;
- test_XIDeviceEvent(&in);
- in.group.latched = ~0 & 0xFF;
- test_XIDeviceEvent(&in);
-
- in.group.locked = 1;
- test_XIDeviceEvent(&in);
- in.group.locked = ~0 & 0xFF;
- test_XIDeviceEvent(&in);
-
- in.mods.effective = 1;
- test_XIDeviceEvent(&in);
- in.mods.effective = ~0 & 0xFF;
- test_XIDeviceEvent(&in);
-
- g_test_message("Testing button masks");
- for (i = 0; i < sizeof(in.buttons) * 8; i++)
- {
- XISetMask(in.buttons, i);
- test_XIDeviceEvent(&in);
- XIClearMask(in.buttons, i);
- }
-
- for (i = 0; i < sizeof(in.buttons) * 8; i++)
- {
- XISetMask(in.buttons, i);
- test_XIDeviceEvent(&in);
- }
-
- g_test_message("Testing valuator masks");
- for (i = 0; i < sizeof(in.valuators.mask) * 8; i++)
- {
- XISetMask(in.valuators.mask, i);
- test_XIDeviceEvent(&in);
- XIClearMask(in.valuators.mask, i);
- }
-
- for (i = 0; i < sizeof(in.valuators.mask) * 8; i++)
- {
- XISetMask(in.valuators.mask, i);
-
- in.valuators.data[i] = i;
- in.valuators.data_frac[i] = i + 20;
- test_XIDeviceEvent(&in);
- XIClearMask(in.valuators.mask, i);
- }
-
- for (i = 0; i < sizeof(in.valuators.mask) * 8; i++)
- {
- XISetMask(in.valuators.mask, i);
- test_XIDeviceEvent(&in);
- }
-}
-
-static void test_values_XIDeviceChangedEvent(DeviceChangedEvent *in,
- xXIDeviceChangedEvent *out,
- BOOL swap)
-{
- int i, j;
- unsigned char *ptr;
-
- if (swap)
- {
- char n;
-
- swaps(&out->sequenceNumber, n);
- swapl(&out->length, n);
- swaps(&out->evtype, n);
- swaps(&out->deviceid, n);
- swaps(&out->sourceid, n);
- swapl(&out->time, n);
- swaps(&out->num_classes, n);
- }
-
- g_assert(out->type == GenericEvent);
- g_assert(out->extension == 0); /* IReqCode defaults to 0 */
- g_assert(out->evtype == GetXI2Type((InternalEvent*)in));
- g_assert(out->time == in->time);
- g_assert(out->deviceid == in->deviceid);
- g_assert(out->sourceid == in->sourceid);
-
- ptr = (unsigned char*)&out[1];
- for (i = 0; i < out->num_classes; i++)
- {
- xXIAnyInfo* any = (xXIAnyInfo*)ptr;
-
- if (swap)
- {
- char n;
- swaps(&any->length, n);
- swaps(&any->type, n);
- swaps(&any->sourceid, n);
- }
-
- switch(any->type)
- {
- case XIButtonClass:
- {
- xXIButtonInfo *b = (xXIButtonInfo*)any;
- Atom *names;
-
- if (swap)
- {
- char n;
- swaps(&b->num_buttons, n);
- }
-
- g_assert(b->length ==
- bytes_to_int32(sizeof(xXIButtonInfo)) +
- bytes_to_int32(bits_to_bytes(b->num_buttons)) +
- b->num_buttons);
- g_assert(b->num_buttons == in->buttons.num_buttons);
-
- names = (Atom*)((char*)&b[1] +
- pad_to_int32(bits_to_bytes(b->num_buttons)));
- for (j = 0; j < b->num_buttons; j++)
- {
- if (swap)
- {
- char n;
- swapl(&names[j], n);
- }
- g_assert(names[j] == in->buttons.names[j]);
- }
- }
- break;
- case XIKeyClass:
- {
- xXIKeyInfo *k = (xXIKeyInfo*)any;
- uint32_t *kc;
-
- if (swap)
- {
- char n;
- swaps(&k->num_keycodes, n);
- }
-
- g_assert(k->length ==
- bytes_to_int32(sizeof(xXIKeyInfo)) +
- k->num_keycodes);
- g_assert(k->num_keycodes == in->keys.max_keycode -
- in->keys.min_keycode + 1);
-
- kc = (uint32_t*)&k[1];
- for (j = 0; j < k->num_keycodes; j++)
- {
- if (swap)
- {
- char n;
- swapl(&kc[j], n);
- }
- g_assert(kc[j] >= in->keys.min_keycode);
- g_assert(kc[j] <= in->keys.max_keycode);
- }
- }
- break;
- case XIValuatorClass:
- {
- xXIValuatorInfo *v = (xXIValuatorInfo*)any;
- g_assert(v->length ==
- bytes_to_int32(sizeof(xXIValuatorInfo)));
-
- }
- break;
- default:
- g_error("Invalid class type.\n");
- break;
- }
-
- ptr += any->length * 4;
- }
-
-}
-
-static void test_XIDeviceChangedEvent(DeviceChangedEvent *in)
-{
- xXIDeviceChangedEvent *out, *swapped;
- int rc;
-
- rc = EventToXI2((InternalEvent*)in, (xEvent**)&out);
- g_assert(rc == Success);
-
- test_values_XIDeviceChangedEvent(in, out, FALSE);
-
- swapped = calloc(1, sizeof(xEvent) + out->length * 4);
- XI2EventSwap((xGenericEvent*)out, (xGenericEvent*)swapped);
- test_values_XIDeviceChangedEvent(in, swapped, TRUE);
-
- free(out);
- free(swapped);
-}
-
-static void test_convert_XIDeviceChangedEvent(void)
-{
- DeviceChangedEvent in;
- int i;
-
- g_test_message("Testing simple field values");
- memset(&in, 0, sizeof(in));
- in.header = ET_Internal;
- in.type = ET_DeviceChanged;
- in.length = sizeof(DeviceChangedEvent);
- in.time = 0;
- in.deviceid = 1;
- in.sourceid = 2;
- in.masterid = 3;
- in.num_valuators = 4;
- in.flags = DEVCHANGE_SLAVE_SWITCH | DEVCHANGE_POINTER_EVENT | DEVCHANGE_KEYBOARD_EVENT;
-
- for (i = 0; i < MAX_BUTTONS; i++)
- in.buttons.names[i] = i + 10;
-
- in.keys.min_keycode = 8;
- in.keys.max_keycode = 255;
-
- test_XIDeviceChangedEvent(&in);
-
- in.time = 1L;
- test_XIDeviceChangedEvent(&in);
- in.time = 1L << 8;
- test_XIDeviceChangedEvent(&in);
- in.time = 1L << 16;
- test_XIDeviceChangedEvent(&in);
- in.time = 1L << 24;
- test_XIDeviceChangedEvent(&in);
- in.time = ~0L;
- test_XIDeviceChangedEvent(&in);
-
- in.deviceid = 1L;
- test_XIDeviceChangedEvent(&in);
- in.deviceid = 1L << 8;
- test_XIDeviceChangedEvent(&in);
- in.deviceid = ~0 & 0xFFFF;
- test_XIDeviceChangedEvent(&in);
-
- in.sourceid = 1L;
- test_XIDeviceChangedEvent(&in);
- in.sourceid = 1L << 8;
- test_XIDeviceChangedEvent(&in);
- in.sourceid = ~0 & 0xFFFF;
- test_XIDeviceChangedEvent(&in);
-
- in.masterid = 1L;
- test_XIDeviceChangedEvent(&in);
- in.masterid = 1L << 8;
- test_XIDeviceChangedEvent(&in);
- in.masterid = ~0 & 0xFFFF;
- test_XIDeviceChangedEvent(&in);
-
- in.buttons.num_buttons = 0;
- test_XIDeviceChangedEvent(&in);
-
- in.buttons.num_buttons = 1;
- test_XIDeviceChangedEvent(&in);
-
- in.buttons.num_buttons = MAX_BUTTONS;
- test_XIDeviceChangedEvent(&in);
-
- in.keys.min_keycode = 0;
- in.keys.max_keycode = 0;
- test_XIDeviceChangedEvent(&in);
-
- in.keys.max_keycode = 1 << 8;
- test_XIDeviceChangedEvent(&in);
-
- in.keys.max_keycode = 0xFFFC; /* highest range, above that the length
- field gives up */
- test_XIDeviceChangedEvent(&in);
-
- in.keys.min_keycode = 1 << 8;
- in.keys.max_keycode = 1 << 8;
- test_XIDeviceChangedEvent(&in);
-
- in.keys.min_keycode = 1 << 8;
- in.keys.max_keycode = 0;
- test_XIDeviceChangedEvent(&in);
-
- in.num_valuators = 0;
- test_XIDeviceChangedEvent(&in);
-
- in.num_valuators = 1;
- test_XIDeviceChangedEvent(&in);
-
- in.num_valuators = MAX_VALUATORS;
- test_XIDeviceChangedEvent(&in);
-
- for (i = 0; i < MAX_VALUATORS; i++)
- {
- in.valuators[i].min = 0;
- in.valuators[i].max = 0;
- test_XIDeviceChangedEvent(&in);
-
- in.valuators[i].max = 1 << 8;
- test_XIDeviceChangedEvent(&in);
- in.valuators[i].max = 1 << 16;
- test_XIDeviceChangedEvent(&in);
- in.valuators[i].max = 1 << 24;
- test_XIDeviceChangedEvent(&in);
- in.valuators[i].max = abs(~0);
- test_XIDeviceChangedEvent(&in);
-
- in.valuators[i].resolution = 1 << 8;
- test_XIDeviceChangedEvent(&in);
- in.valuators[i].resolution = 1 << 16;
- test_XIDeviceChangedEvent(&in);
- in.valuators[i].resolution = 1 << 24;
- test_XIDeviceChangedEvent(&in);
- in.valuators[i].resolution = abs(~0);
- test_XIDeviceChangedEvent(&in);
-
- in.valuators[i].name = i;
- test_XIDeviceChangedEvent(&in);
-
- in.valuators[i].mode = Relative;
- test_XIDeviceChangedEvent(&in);
-
- in.valuators[i].mode = Absolute;
- test_XIDeviceChangedEvent(&in);
- }
-}
-
-int main(int argc, char** argv)
-{
- g_test_init(&argc, &argv,NULL);
- g_test_bug_base("https://bugzilla.freedesktop.org/show_bug.cgi?id=");
-
- g_test_add_func("/xi2/eventconvert/XIRawEvent", test_convert_XIRawEvent);
- g_test_add_func("/xi2/eventconvert/XIFocusEvent", test_convert_XIFocusEvent);
- g_test_add_func("/xi2/eventconvert/XIDeviceEvent", test_convert_XIDeviceEvent);
- g_test_add_func("/xi2/eventconvert/XIDeviceChangedEvent", test_convert_XIDeviceChangedEvent);
-
- return g_test_run();
-}
+/**
+ * Copyright © 2009 Red Hat, Inc.
+ *
+ * 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, sublicense,
+ * 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 NONINFRINGEMENT. IN NO EVENT SHALL
+ * THE AUTHORS OR COPYRIGHT HOLDERS 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.
+ */
+
+#ifdef HAVE_DIX_CONFIG_H
+#include <dix-config.h>
+#endif
+
+#include <stdint.h>
+
+#include "inputstr.h"
+#include "eventstr.h"
+#include "eventconvert.h"
+#include "exevents.h"
+#include <X11/extensions/XI2proto.h>
+
+static void test_values_XIRawEvent(RawDeviceEvent *in, xXIRawEvent *out,
+ BOOL swap)
+{
+ int i;
+ unsigned char *ptr;
+ FP3232 *value, *raw_value;
+ int nvals = 0;
+ int bits_set;
+ int len;
+
+ if (swap)
+ {
+ char n;
+
+ swaps(&out->sequenceNumber, n);
+ swapl(&out->length, n);
+ swaps(&out->evtype, n);
+ swaps(&out->deviceid, n);
+ swapl(&out->time, n);
+ swapl(&out->detail, n);
+ swaps(&out->valuators_len, n);
+ }
+
+
+ assert(out->type == GenericEvent);
+ assert(out->extension == 0); /* IReqCode defaults to 0 */
+ assert(out->evtype == GetXI2Type((InternalEvent*)in));
+ assert(out->time == in->time);
+ assert(out->detail == in->detail.button);
+ assert(out->deviceid == in->deviceid);
+ assert(out->valuators_len >= bytes_to_int32(bits_to_bytes(sizeof(in->valuators.mask))));
+ assert(out->flags == 0); /* FIXME: we don't set the flags yet */
+
+ ptr = (unsigned char*)&out[1];
+ bits_set = 0;
+
+ for (i = 0; out->valuators_len && i < sizeof(in->valuators.mask) * 8; i++)
+ {
+ assert (XIMaskIsSet(in->valuators.mask, i) == XIMaskIsSet(ptr, i));
+ if (XIMaskIsSet(in->valuators.mask, i))
+ bits_set++;
+ }
+
+ /* length is len of valuator mask (in 4-byte units) + the number of bits
+ * set. Each bit set represents 2 8-byte values, hence the
+ * 'bits_set * 4' */
+ len = out->valuators_len + bits_set * 4;
+ assert(out->length == len);
+
+ nvals = 0;
+
+ for (i = 0; out->valuators_len && i < MAX_VALUATORS; i++)
+ {
+ assert (XIMaskIsSet(in->valuators.mask, i) == XIMaskIsSet(ptr, i));
+ if (XIMaskIsSet(in->valuators.mask, i))
+ {
+ FP3232 vi, vo;
+ value = (FP3232*)(((unsigned char*)&out[1]) + out->valuators_len * 4);
+ value += nvals;
+
+ vi.integral = in->valuators.data[i];
+ vi.frac = in->valuators.data_frac[i];
+
+ vo.integral = value->integral;
+ vo.frac = value->frac;
+ if (swap)
+ {
+ char n;
+ swapl(&vo.integral, n);
+ swapl(&vo.frac, n);
+ }
+
+ assert(vi.integral == vo.integral);
+ assert(vi.frac == vo.frac);
+
+ raw_value = value + bits_set;
+
+ vi.integral = in->valuators.data_raw[i];
+ vi.frac = in->valuators.data_raw_frac[i];
+
+ vo.integral = raw_value->integral;
+ vo.frac = raw_value->frac;
+ if (swap)
+ {
+ char n;
+ swapl(&vo.integral, n);
+ swapl(&vo.frac, n);
+ }
+
+ assert(vi.integral == vo.integral);
+ assert(vi.frac == vo.frac);
+
+ nvals++;
+ }
+ }
+}
+
+static void test_XIRawEvent(RawDeviceEvent *in)
+{
+ xXIRawEvent *out, *swapped;
+ int rc;
+
+ rc = EventToXI2((InternalEvent*)in, (xEvent**)&out);
+ assert(rc == Success);
+
+ test_values_XIRawEvent(in, out, FALSE);
+
+ swapped = calloc(1, sizeof(xEvent) + out->length * 4);
+ XI2EventSwap((xGenericEvent*)out, (xGenericEvent*)swapped);
+ test_values_XIRawEvent(in, swapped, TRUE);
+
+ free(out);
+ free(swapped);
+}
+
+static void test_convert_XIFocusEvent(void)
+{
+ xEvent *out;
+ DeviceEvent in;
+ int rc;
+
+ in.header = ET_Internal;
+ in.type = ET_Enter;
+ rc = EventToXI2((InternalEvent*)&in, &out);
+ assert(rc == Success);
+ assert(out == NULL);
+
+ in.header = ET_Internal;
+ in.type = ET_FocusIn;
+ rc = EventToXI2((InternalEvent*)&in, &out);
+ assert(rc == Success);
+ assert(out == NULL);
+
+ in.header = ET_Internal;
+ in.type = ET_FocusOut;
+ rc = EventToXI2((InternalEvent*)&in, &out);
+ assert(rc == BadImplementation);
+
+ in.header = ET_Internal;
+ in.type = ET_Leave;
+ rc = EventToXI2((InternalEvent*)&in, &out);
+ assert(rc == BadImplementation);
+}
+
+
+static void test_convert_XIRawEvent(void)
+{
+ RawDeviceEvent in;
+ int i;
+
+ memset(&in, 0, sizeof(in));
+
+ printf("Testing all event types\n");
+ in.header = ET_Internal;
+ in.type = ET_RawMotion;
+ test_XIRawEvent(&in);
+
+ in.header = ET_Internal;
+ in.type = ET_RawKeyPress;
+ test_XIRawEvent(&in);
+
+ in.header = ET_Internal;
+ in.type = ET_RawKeyRelease;
+ test_XIRawEvent(&in);
+
+ in.header = ET_Internal;
+ in.type = ET_RawButtonPress;
+ test_XIRawEvent(&in);
+
+ in.header = ET_Internal;
+ in.type = ET_RawButtonRelease;
+ test_XIRawEvent(&in);
+
+ printf("Testing details and other fields\n");
+ in.detail.button = 1L;
+ test_XIRawEvent(&in);
+ in.detail.button = 1L << 8;
+ test_XIRawEvent(&in);
+ in.detail.button = 1L << 16;
+ test_XIRawEvent(&in);
+ in.detail.button = 1L << 24;
+ test_XIRawEvent(&in);
+ in.detail.button = ~0L;
+ test_XIRawEvent(&in);
+
+ in.detail.button = 0;
+
+ in.time = 1L;
+ test_XIRawEvent(&in);
+ in.time = 1L << 8;
+ test_XIRawEvent(&in);
+ in.time = 1L << 16;
+ test_XIRawEvent(&in);
+ in.time = 1L << 24;
+ test_XIRawEvent(&in);
+ in.time = ~0L;
+ test_XIRawEvent(&in);
+
+ in.deviceid = 1;
+ test_XIRawEvent(&in);
+ in.deviceid = 1 << 8;
+ test_XIRawEvent(&in);
+ in.deviceid = ~0 & 0xFF;
+ test_XIRawEvent(&in);
+
+ printf("Testing valuator masks\n");
+ for (i = 0; i < sizeof(in.valuators.mask) * 8; i++)
+ {
+ XISetMask(in.valuators.mask, i);
+ test_XIRawEvent(&in);
+ XIClearMask(in.valuators.mask, i);
+ }
+
+ for (i = 0; i < MAX_VALUATORS; i++)
+ {
+ XISetMask(in.valuators.mask, i);
+
+ in.valuators.data[i] = i;
+ in.valuators.data_raw[i] = i + 10;
+ in.valuators.data_frac[i] = i + 20;
+ in.valuators.data_raw_frac[i] = i + 30;
+ test_XIRawEvent(&in);
+ XIClearMask(in.valuators.mask, i);
+ }
+
+ for (i = 0; i < sizeof(in.valuators.mask) * 8; i++)
+ {
+ XISetMask(in.valuators.mask, i);
+ test_XIRawEvent(&in);
+ }
+}
+
+static void test_values_XIDeviceEvent(DeviceEvent *in, xXIDeviceEvent *out,
+ BOOL swap)
+{
+ int buttons, valuators;
+ int i;
+ unsigned char *ptr;
+ uint32_t flagmask = 0;
+ FP3232 *values;
+
+ if (swap) {
+ char n;
+
+ swaps(&out->sequenceNumber, n);
+ swapl(&out->length, n);
+ swaps(&out->evtype, n);
+ swaps(&out->deviceid, n);
+ swaps(&out->sourceid, n);
+ swapl(&out->time, n);
+ swapl(&out->detail, n);
+ swapl(&out->root, n);
+ swapl(&out->event, n);
+ swapl(&out->child, n);
+ swapl(&out->root_x, n);
+ swapl(&out->root_y, n);
+ swapl(&out->event_x, n);
+ swapl(&out->event_y, n);
+ swaps(&out->buttons_len, n);
+ swaps(&out->valuators_len, n);
+ swapl(&out->mods.base_mods, n);
+ swapl(&out->mods.latched_mods, n);
+ swapl(&out->mods.locked_mods, n);
+ swapl(&out->mods.effective_mods, n);
+ swapl(&out->flags, n);
+ }
+
+ assert(out->extension == 0); /* IReqCode defaults to 0 */
+ assert(out->evtype == GetXI2Type((InternalEvent*)in));
+ assert(out->time == in->time);
+ assert(out->detail == in->detail.button);
+ assert(out->length >= 12);
+
+ assert(out->deviceid == in->deviceid);
+ assert(out->sourceid == in->sourceid);
+
+ switch (in->type) {
+ case ET_KeyPress:
+ flagmask = XIKeyRepeat;
+ break;
+ default:
+ flagmask = 0;
+ break;
+ }
+ assert((out->flags & ~flagmask) == 0);
+
+ assert(out->root == in->root);
+ assert(out->event == None); /* set in FixUpEventFromWindow */
+ assert(out->child == None); /* set in FixUpEventFromWindow */
+
+ assert(out->mods.base_mods == in->mods.base);
+ assert(out->mods.latched_mods == in->mods.latched);
+ assert(out->mods.locked_mods == in->mods.locked);
+ assert(out->mods.effective_mods == in->mods.effective);
+
+ assert(out->group.base_group == in->group.base);
+ assert(out->group.latched_group == in->group.latched);
+ assert(out->group.locked_group == in->group.locked);
+ assert(out->group.effective_group == in->group.effective);
+
+ assert(out->event_x == 0); /* set in FixUpEventFromWindow */
+ assert(out->event_y == 0); /* set in FixUpEventFromWindow */
+
+ assert(out->root_x == FP1616(in->root_x, in->root_x_frac));
+ assert(out->root_y == FP1616(in->root_y, in->root_y_frac));
+
+ buttons = 0;
+ for (i = 0; i < bits_to_bytes(sizeof(in->buttons)); i++)
+ {
+ if (XIMaskIsSet(in->buttons, i))
+ {
+ assert(out->buttons_len >= bytes_to_int32(bits_to_bytes(i)));
+ buttons++;
+ }
+ }
+
+ ptr = (unsigned char*)&out[1];
+ for (i = 0; i < sizeof(in->buttons) * 8; i++)
+ assert(XIMaskIsSet(in->buttons, i) == XIMaskIsSet(ptr, i));
+
+
+ valuators = 0;
+ for (i = 0; i < sizeof(in->valuators.mask) * 8; i++)
+ if (XIMaskIsSet(in->valuators.mask, i))
+ valuators++;
+
+ assert(out->valuators_len >= bytes_to_int32(bits_to_bytes(valuators)));
+
+ ptr += out->buttons_len * 4;
+ values = (FP3232*)(ptr + out->valuators_len * 4);
+ for (i = 0; i < sizeof(in->valuators.mask) * 8 ||
+ i < (out->valuators_len * 4) * 8; i++)
+ {
+ if (i > sizeof(in->valuators.mask) * 8)
+ assert(!XIMaskIsSet(ptr, i));
+ else if (i > out->valuators_len * 4 * 8)
+ assert(!XIMaskIsSet(in->valuators.mask, i));
+ else {
+ assert(XIMaskIsSet(in->valuators.mask, i) ==
+ XIMaskIsSet(ptr, i));
+
+ if (XIMaskIsSet(ptr, i))
+ {
+ FP3232 vi, vo;
+
+ vi.integral = in->valuators.data[i];
+ vi.frac = in->valuators.data_frac[i];
+
+ vo = *values;
+
+ if (swap)
+ {
+ char n;
+ swapl(&vo.integral, n);
+ swapl(&vo.frac, n);
+ }
+
+
+ assert(vi.integral == vo.integral);
+ assert(vi.frac == vo.frac);
+ values++;
+ }
+ }
+ }
+}
+
+static void test_XIDeviceEvent(DeviceEvent *in)
+{
+ xXIDeviceEvent *out, *swapped;
+ int rc;
+
+ rc = EventToXI2((InternalEvent*)in, (xEvent**)&out);
+ assert(rc == Success);
+
+ test_values_XIDeviceEvent(in, out, FALSE);
+
+ swapped = calloc(1, sizeof(xEvent) + out->length * 4);
+ XI2EventSwap((xGenericEvent*)out, (xGenericEvent*)swapped);
+ test_values_XIDeviceEvent(in, swapped, TRUE);
+
+ free(out);
+ free(swapped);
+}
+
+static void test_convert_XIDeviceEvent(void)
+{
+ DeviceEvent in;
+ int i;
+
+ memset(&in, 0, sizeof(in));
+
+ printf("Testing simple field values\n");
+ in.header = ET_Internal;
+ in.type = ET_Motion;
+ in.length = sizeof(DeviceEvent);
+ in.time = 0;
+ in.deviceid = 1;
+ in.sourceid = 2;
+ in.root = 3;
+ in.root_x = 4;
+ in.root_x_frac = 5;
+ in.root_y = 6;
+ in.root_y_frac = 7;
+ in.detail.button = 8;
+ in.mods.base = 9;
+ in.mods.latched = 10;
+ in.mods.locked = 11;
+ in.mods.effective = 11;
+ in.group.base = 12;
+ in.group.latched = 13;
+ in.group.locked = 14;
+ in.group.effective = 15;
+
+ test_XIDeviceEvent(&in);
+
+ printf("Testing field ranges\n");
+ /* 32 bit */
+ in.detail.button = 1L;
+ test_XIDeviceEvent(&in);
+ in.detail.button = 1L << 8;
+ test_XIDeviceEvent(&in);
+ in.detail.button = 1L << 16;
+ test_XIDeviceEvent(&in);
+ in.detail.button = 1L << 24;
+ test_XIDeviceEvent(&in);
+ in.detail.button = ~0L;
+ test_XIDeviceEvent(&in);
+
+ /* 32 bit */
+ in.time = 1L;
+ test_XIDeviceEvent(&in);
+ in.time = 1L << 8;
+ test_XIDeviceEvent(&in);
+ in.time = 1L << 16;
+ test_XIDeviceEvent(&in);
+ in.time = 1L << 24;
+ test_XIDeviceEvent(&in);
+ in.time = ~0L;
+ test_XIDeviceEvent(&in);
+
+ /* 16 bit */
+ in.deviceid = 1;
+ test_XIDeviceEvent(&in);
+ in.deviceid = 1 << 8;
+ test_XIDeviceEvent(&in);
+ in.deviceid = ~0 & 0xFF;
+ test_XIDeviceEvent(&in);
+
+ /* 16 bit */
+ in.sourceid = 1;
+ test_XIDeviceEvent(&in);
+ in.deviceid = 1 << 8;
+ test_XIDeviceEvent(&in);
+ in.deviceid = ~0 & 0xFF;
+ test_XIDeviceEvent(&in);
+
+ /* 32 bit */
+ in.root = 1L;
+ test_XIDeviceEvent(&in);
+ in.root = 1L << 8;
+ test_XIDeviceEvent(&in);
+ in.root = 1L << 16;
+ test_XIDeviceEvent(&in);
+ in.root = 1L << 24;
+ test_XIDeviceEvent(&in);
+ in.root = ~0L;
+ test_XIDeviceEvent(&in);
+
+ /* 16 bit */
+ in.root_x = 1;
+ test_XIDeviceEvent(&in);
+ in.root_x = 1 << 8;
+ test_XIDeviceEvent(&in);
+ in.root_x = ~0 & 0xFF;
+ test_XIDeviceEvent(&in);
+
+ in.root_x_frac = 1;
+ test_XIDeviceEvent(&in);
+ in.root_x_frac = 1 << 8;
+ test_XIDeviceEvent(&in);
+ in.root_x_frac = ~0 & 0xFF;
+ test_XIDeviceEvent(&in);
+
+ in.root_y = 1;
+ test_XIDeviceEvent(&in);
+ in.root_y = 1 << 8;
+ test_XIDeviceEvent(&in);
+ in.root_y = ~0 & 0xFF;
+ test_XIDeviceEvent(&in);
+
+ in.root_y_frac = 1;
+ test_XIDeviceEvent(&in);
+ in.root_y_frac = 1 << 8;
+ test_XIDeviceEvent(&in);
+ in.root_y_frac = ~0 & 0xFF;
+ test_XIDeviceEvent(&in);
+
+ /* 32 bit */
+ in.mods.base = 1L;
+ test_XIDeviceEvent(&in);
+ in.mods.base = 1L << 8;
+ test_XIDeviceEvent(&in);
+ in.mods.base = 1L << 16;
+ test_XIDeviceEvent(&in);
+ in.mods.base = 1L << 24;
+ test_XIDeviceEvent(&in);
+ in.mods.base = ~0L;
+ test_XIDeviceEvent(&in);
+
+ in.mods.latched = 1L;
+ test_XIDeviceEvent(&in);
+ in.mods.latched = 1L << 8;
+ test_XIDeviceEvent(&in);
+ in.mods.latched = 1L << 16;
+ test_XIDeviceEvent(&in);
+ in.mods.latched = 1L << 24;
+ test_XIDeviceEvent(&in);
+ in.mods.latched = ~0L;
+ test_XIDeviceEvent(&in);
+
+ in.mods.locked = 1L;
+ test_XIDeviceEvent(&in);
+ in.mods.locked = 1L << 8;
+ test_XIDeviceEvent(&in);
+ in.mods.locked = 1L << 16;
+ test_XIDeviceEvent(&in);
+ in.mods.locked = 1L << 24;
+ test_XIDeviceEvent(&in);
+ in.mods.locked = ~0L;
+ test_XIDeviceEvent(&in);
+
+ in.mods.effective = 1L;
+ test_XIDeviceEvent(&in);
+ in.mods.effective = 1L << 8;
+ test_XIDeviceEvent(&in);
+ in.mods.effective = 1L << 16;
+ test_XIDeviceEvent(&in);
+ in.mods.effective = 1L << 24;
+ test_XIDeviceEvent(&in);
+ in.mods.effective = ~0L;
+ test_XIDeviceEvent(&in);
+
+ /* 8 bit */
+ in.group.base = 1;
+ test_XIDeviceEvent(&in);
+ in.group.base = ~0 & 0xFF;
+ test_XIDeviceEvent(&in);
+
+ in.group.latched = 1;
+ test_XIDeviceEvent(&in);
+ in.group.latched = ~0 & 0xFF;
+ test_XIDeviceEvent(&in);
+
+ in.group.locked = 1;
+ test_XIDeviceEvent(&in);
+ in.group.locked = ~0 & 0xFF;
+ test_XIDeviceEvent(&in);
+
+ in.mods.effective = 1;
+ test_XIDeviceEvent(&in);
+ in.mods.effective = ~0 & 0xFF;
+ test_XIDeviceEvent(&in);
+
+ printf("Testing button masks\n");
+ for (i = 0; i < sizeof(in.buttons) * 8; i++)
+ {
+ XISetMask(in.buttons, i);
+ test_XIDeviceEvent(&in);
+ XIClearMask(in.buttons, i);
+ }
+
+ for (i = 0; i < sizeof(in.buttons) * 8; i++)
+ {
+ XISetMask(in.buttons, i);
+ test_XIDeviceEvent(&in);
+ }
+
+ printf("Testing valuator masks\n");
+ for (i = 0; i < sizeof(in.valuators.mask) * 8; i++)
+ {
+ XISetMask(in.valuators.mask, i);
+ test_XIDeviceEvent(&in);
+ XIClearMask(in.valuators.mask, i);
+ }
+
+ for (i = 0; i < sizeof(in.valuators.mask) * 8; i++)
+ {
+ XISetMask(in.valuators.mask, i);
+
+ in.valuators.data[i] = i;
+ in.valuators.data_frac[i] = i + 20;
+ test_XIDeviceEvent(&in);
+ XIClearMask(in.valuators.mask, i);
+ }
+
+ for (i = 0; i < sizeof(in.valuators.mask) * 8; i++)
+ {
+ XISetMask(in.valuators.mask, i);
+ test_XIDeviceEvent(&in);
+ }
+}
+
+static void test_values_XIDeviceChangedEvent(DeviceChangedEvent *in,
+ xXIDeviceChangedEvent *out,
+ BOOL swap)
+{
+ int i, j;
+ unsigned char *ptr;
+
+ if (swap)
+ {
+ char n;
+
+ swaps(&out->sequenceNumber, n);
+ swapl(&out->length, n);
+ swaps(&out->evtype, n);
+ swaps(&out->deviceid, n);
+ swaps(&out->sourceid, n);
+ swapl(&out->time, n);
+ swaps(&out->num_classes, n);
+ }
+
+ assert(out->type == GenericEvent);
+ assert(out->extension == 0); /* IReqCode defaults to 0 */
+ assert(out->evtype == GetXI2Type((InternalEvent*)in));
+ assert(out->time == in->time);
+ assert(out->deviceid == in->deviceid);
+ assert(out->sourceid == in->sourceid);
+
+ ptr = (unsigned char*)&out[1];
+ for (i = 0; i < out->num_classes; i++)
+ {
+ xXIAnyInfo* any = (xXIAnyInfo*)ptr;
+
+ if (swap)
+ {
+ char n;
+ swaps(&any->length, n);
+ swaps(&any->type, n);
+ swaps(&any->sourceid, n);
+ }
+
+ switch(any->type)
+ {
+ case XIButtonClass:
+ {
+ xXIButtonInfo *b = (xXIButtonInfo*)any;
+ Atom *names;
+
+ if (swap)
+ {
+ char n;
+ swaps(&b->num_buttons, n);
+ }
+
+ assert(b->length ==
+ bytes_to_int32(sizeof(xXIButtonInfo)) +
+ bytes_to_int32(bits_to_bytes(b->num_buttons)) +
+ b->num_buttons);
+ assert(b->num_buttons == in->buttons.num_buttons);
+
+ names = (Atom*)((char*)&b[1] +
+ pad_to_int32(bits_to_bytes(b->num_buttons)));
+ for (j = 0; j < b->num_buttons; j++)
+ {
+ if (swap)
+ {
+ char n;
+ swapl(&names[j], n);
+ }
+ assert(names[j] == in->buttons.names[j]);
+ }
+ }
+ break;
+ case XIKeyClass:
+ {
+ xXIKeyInfo *k = (xXIKeyInfo*)any;
+ uint32_t *kc;
+
+ if (swap)
+ {
+ char n;
+ swaps(&k->num_keycodes, n);
+ }
+
+ assert(k->length ==
+ bytes_to_int32(sizeof(xXIKeyInfo)) +
+ k->num_keycodes);
+ assert(k->num_keycodes == in->keys.max_keycode -
+ in->keys.min_keycode + 1);
+
+ kc = (uint32_t*)&k[1];
+ for (j = 0; j < k->num_keycodes; j++)
+ {
+ if (swap)
+ {
+ char n;
+ swapl(&kc[j], n);
+ }
+ assert(kc[j] >= in->keys.min_keycode);
+ assert(kc[j] <= in->keys.max_keycode);
+ }
+ }
+ break;
+ case XIValuatorClass:
+ {
+ xXIValuatorInfo *v = (xXIValuatorInfo*)any;
+ assert(v->length ==
+ bytes_to_int32(sizeof(xXIValuatorInfo)));
+
+ }
+ break;
+ default:
+ printf("Invalid class type.\n\n");
+ assert(1);
+ break;
+ }
+
+ ptr += any->length * 4;
+ }
+
+}
+
+static void test_XIDeviceChangedEvent(DeviceChangedEvent *in)
+{
+ xXIDeviceChangedEvent *out, *swapped;
+ int rc;
+
+ rc = EventToXI2((InternalEvent*)in, (xEvent**)&out);
+ assert(rc == Success);
+
+ test_values_XIDeviceChangedEvent(in, out, FALSE);
+
+ swapped = calloc(1, sizeof(xEvent) + out->length * 4);
+ XI2EventSwap((xGenericEvent*)out, (xGenericEvent*)swapped);
+ test_values_XIDeviceChangedEvent(in, swapped, TRUE);
+
+ free(out);
+ free(swapped);
+}
+
+static void test_convert_XIDeviceChangedEvent(void)
+{
+ DeviceChangedEvent in;
+ int i;
+
+ printf("Testing simple field values\n");
+ memset(&in, 0, sizeof(in));
+ in.header = ET_Internal;
+ in.type = ET_DeviceChanged;
+ in.length = sizeof(DeviceChangedEvent);
+ in.time = 0;
+ in.deviceid = 1;
+ in.sourceid = 2;
+ in.masterid = 3;
+ in.num_valuators = 4;
+ in.flags = DEVCHANGE_SLAVE_SWITCH | DEVCHANGE_POINTER_EVENT | DEVCHANGE_KEYBOARD_EVENT;
+
+ for (i = 0; i < MAX_BUTTONS; i++)
+ in.buttons.names[i] = i + 10;
+
+ in.keys.min_keycode = 8;
+ in.keys.max_keycode = 255;
+
+ test_XIDeviceChangedEvent(&in);
+
+ in.time = 1L;
+ test_XIDeviceChangedEvent(&in);
+ in.time = 1L << 8;
+ test_XIDeviceChangedEvent(&in);
+ in.time = 1L << 16;
+ test_XIDeviceChangedEvent(&in);
+ in.time = 1L << 24;
+ test_XIDeviceChangedEvent(&in);
+ in.time = ~0L;
+ test_XIDeviceChangedEvent(&in);
+
+ in.deviceid = 1L;
+ test_XIDeviceChangedEvent(&in);
+ in.deviceid = 1L << 8;
+ test_XIDeviceChangedEvent(&in);
+ in.deviceid = ~0 & 0xFFFF;
+ test_XIDeviceChangedEvent(&in);
+
+ in.sourceid = 1L;
+ test_XIDeviceChangedEvent(&in);
+ in.sourceid = 1L << 8;
+ test_XIDeviceChangedEvent(&in);
+ in.sourceid = ~0 & 0xFFFF;
+ test_XIDeviceChangedEvent(&in);
+
+ in.masterid = 1L;
+ test_XIDeviceChangedEvent(&in);
+ in.masterid = 1L << 8;
+ test_XIDeviceChangedEvent(&in);
+ in.masterid = ~0 & 0xFFFF;
+ test_XIDeviceChangedEvent(&in);
+
+ in.buttons.num_buttons = 0;
+ test_XIDeviceChangedEvent(&in);
+
+ in.buttons.num_buttons = 1;
+ test_XIDeviceChangedEvent(&in);
+
+ in.buttons.num_buttons = MAX_BUTTONS;
+ test_XIDeviceChangedEvent(&in);
+
+ in.keys.min_keycode = 0;
+ in.keys.max_keycode = 0;
+ test_XIDeviceChangedEvent(&in);
+
+ in.keys.max_keycode = 1 << 8;
+ test_XIDeviceChangedEvent(&in);
+
+ in.keys.max_keycode = 0xFFFC; /* highest range, above that the length
+ field gives up */
+ test_XIDeviceChangedEvent(&in);
+
+ in.keys.min_keycode = 1 << 8;
+ in.keys.max_keycode = 1 << 8;
+ test_XIDeviceChangedEvent(&in);
+
+ in.keys.min_keycode = 1 << 8;
+ in.keys.max_keycode = 0;
+ test_XIDeviceChangedEvent(&in);
+
+ in.num_valuators = 0;
+ test_XIDeviceChangedEvent(&in);
+
+ in.num_valuators = 1;
+ test_XIDeviceChangedEvent(&in);
+
+ in.num_valuators = MAX_VALUATORS;
+ test_XIDeviceChangedEvent(&in);
+
+ for (i = 0; i < MAX_VALUATORS; i++)
+ {
+ in.valuators[i].min = 0;
+ in.valuators[i].max = 0;
+ test_XIDeviceChangedEvent(&in);
+
+ in.valuators[i].max = 1 << 8;
+ test_XIDeviceChangedEvent(&in);
+ in.valuators[i].max = 1 << 16;
+ test_XIDeviceChangedEvent(&in);
+ in.valuators[i].max = 1 << 24;
+ test_XIDeviceChangedEvent(&in);
+ in.valuators[i].max = abs(~0);
+ test_XIDeviceChangedEvent(&in);
+
+ in.valuators[i].resolution = 1 << 8;
+ test_XIDeviceChangedEvent(&in);
+ in.valuators[i].resolution = 1 << 16;
+ test_XIDeviceChangedEvent(&in);
+ in.valuators[i].resolution = 1 << 24;
+ test_XIDeviceChangedEvent(&in);
+ in.valuators[i].resolution = abs(~0);
+ test_XIDeviceChangedEvent(&in);
+
+ in.valuators[i].name = i;
+ test_XIDeviceChangedEvent(&in);
+
+ in.valuators[i].mode = Relative;
+ test_XIDeviceChangedEvent(&in);
+
+ in.valuators[i].mode = Absolute;
+ test_XIDeviceChangedEvent(&in);
+ }
+}
+
+int main(int argc, char** argv)
+{
+ test_convert_XIRawEvent();
+ test_convert_XIFocusEvent();
+ test_convert_XIDeviceEvent();
+ test_convert_XIDeviceChangedEvent();
+
+ return 0;
+}
diff --git a/xorg-server/test/xi2/protocol-xigetclientpointer.c b/xorg-server/test/xi2/protocol-xigetclientpointer.c
index 6b4d04957..39fae8eaa 100644
--- a/xorg-server/test/xi2/protocol-xigetclientpointer.c
+++ b/xorg-server/test/xi2/protocol-xigetclientpointer.c
@@ -1,167 +1,162 @@
-/**
- * Copyright © 2009 Red Hat, Inc.
- *
- * 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, sublicense,
- * 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 NONINFRINGEMENT. IN NO EVENT SHALL
- * THE AUTHORS OR COPYRIGHT HOLDERS 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.
- */
-
-#ifdef HAVE_DIX_CONFIG_H
-#include <dix-config.h>
-#endif
-
-/*
- * Protocol testing for XIGetClientPointer request.
- */
-#include <stdint.h>
-#include <X11/X.h>
-#include <X11/Xproto.h>
-#include <X11/extensions/XI2proto.h>
-#include "inputstr.h"
-#include "windowstr.h"
-#include "scrnintstr.h"
-#include "xigetclientpointer.h"
-#include "exevents.h"
-
-#include "protocol-common.h"
-#include <glib.h>
-
-struct {
- int cp_is_set;
- DeviceIntPtr dev;
- int win;
-} test_data;
-
-static ClientRec client_window;
-static ClientRec client_request;
-
-int __wrap_dixLookupClient(ClientPtr *pClient, XID rid, ClientPtr client, Mask access)
-{
- if (rid == ROOT_WINDOW_ID)
- return BadWindow;
-
- if (rid == CLIENT_WINDOW_ID)
- {
- *pClient = &client_window;
- return Success;
- }
-
- return __real_dixLookupClient(pClient, rid, client, access);
-}
-
-
-static void reply_XIGetClientPointer(ClientPtr client, int len, char *data, void *userdata)
-{
- xXIGetClientPointerReply *rep = (xXIGetClientPointerReply*)data;
-
- if (client->swapped)
- {
- char n;
- swapl(&rep->length, n);
- swaps(&rep->sequenceNumber, n);
- swaps(&rep->deviceid, n);
- }
-
- reply_check_defaults(rep, len, XIGetClientPointer);
-
- g_assert(rep->set == test_data.cp_is_set);
- if (rep->set)
- g_assert(rep->deviceid == test_data.dev->id);
-}
-
-static void request_XIGetClientPointer(ClientPtr client, xXIGetClientPointerReq* req, int error)
-{
- char n;
- int rc;
-
- test_data.win = req->win;
-
- rc = ProcXIGetClientPointer(&client_request);
- g_assert(rc == error);
-
- if (rc == BadWindow)
- g_assert(client_request.errorValue == req->win);
-
- client_request.swapped = TRUE;
- swapl(&req->win, n);
- swaps(&req->length, n);
- rc = SProcXIGetClientPointer(&client_request);
- g_assert(rc == error);
-
- if (rc == BadWindow)
- g_assert(client_request.errorValue == req->win);
-
-}
-
-static void test_XIGetClientPointer(void)
-{
- xXIGetClientPointerReq request;
-
- request_init(&request, XIGetClientPointer);
-
- request.win = CLIENT_WINDOW_ID;
-
-
- reply_handler = reply_XIGetClientPointer;
-
- client_request = init_client(request.length, &request);
-
- g_test_message("Testing invalid window");
- request.win = INVALID_WINDOW_ID;
- request_XIGetClientPointer(&client_request, &request, BadWindow);
-
- test_data.cp_is_set = FALSE;
-
- g_test_message("Testing window None, unset ClientPointer.");
- request.win = None;
- request_XIGetClientPointer(&client_request, &request, Success);
-
- g_test_message("Testing valid window, unset ClientPointer.");
- request.win = CLIENT_WINDOW_ID;
- request_XIGetClientPointer(&client_request, &request, Success);
-
- g_test_message("Testing valid window, set ClientPointer.");
- client_window.clientPtr = devices.vcp;
- test_data.dev = devices.vcp;
- test_data.cp_is_set = TRUE;
- request.win = CLIENT_WINDOW_ID;
- request_XIGetClientPointer(&client_request, &request, Success);
-
- client_window.clientPtr = NULL;
-
- g_test_message("Testing window None, set ClientPointer.");
- client_request.clientPtr = devices.vcp;
- test_data.dev = devices.vcp;
- test_data.cp_is_set = TRUE;
- request.win = None;
- request_XIGetClientPointer(&client_request, &request, Success);
-}
-
-int main(int argc, char** argv)
-{
- g_test_init(&argc, &argv,NULL);
- g_test_bug_base("https://bugzilla.freedesktop.org/show_bug.cgi?id=");
-
- init_simple();
- client_window = init_client(0, NULL);
-
-
- g_test_add_func("/xi2/protocol/XIGetClientPointer", test_XIGetClientPointer);
-
- return g_test_run();
-}
+/**
+ * Copyright © 2009 Red Hat, Inc.
+ *
+ * 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, sublicense,
+ * 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 NONINFRINGEMENT. IN NO EVENT SHALL
+ * THE AUTHORS OR COPYRIGHT HOLDERS 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.
+ */
+
+#ifdef HAVE_DIX_CONFIG_H
+#include <dix-config.h>
+#endif
+
+/*
+ * Protocol testing for XIGetClientPointer request.
+ */
+#include <stdint.h>
+#include <X11/X.h>
+#include <X11/Xproto.h>
+#include <X11/extensions/XI2proto.h>
+#include "inputstr.h"
+#include "windowstr.h"
+#include "scrnintstr.h"
+#include "xigetclientpointer.h"
+#include "exevents.h"
+
+#include "protocol-common.h"
+
+struct {
+ int cp_is_set;
+ DeviceIntPtr dev;
+ int win;
+} test_data;
+
+static ClientRec client_window;
+static ClientRec client_request;
+
+int __wrap_dixLookupClient(ClientPtr *pClient, XID rid, ClientPtr client, Mask access)
+{
+ if (rid == ROOT_WINDOW_ID)
+ return BadWindow;
+
+ if (rid == CLIENT_WINDOW_ID)
+ {
+ *pClient = &client_window;
+ return Success;
+ }
+
+ return __real_dixLookupClient(pClient, rid, client, access);
+}
+
+
+static void reply_XIGetClientPointer(ClientPtr client, int len, char *data, void *userdata)
+{
+ xXIGetClientPointerReply *rep = (xXIGetClientPointerReply*)data;
+
+ if (client->swapped)
+ {
+ char n;
+ swapl(&rep->length, n);
+ swaps(&rep->sequenceNumber, n);
+ swaps(&rep->deviceid, n);
+ }
+
+ reply_check_defaults(rep, len, XIGetClientPointer);
+
+ assert(rep->set == test_data.cp_is_set);
+ if (rep->set)
+ assert(rep->deviceid == test_data.dev->id);
+}
+
+static void request_XIGetClientPointer(ClientPtr client, xXIGetClientPointerReq* req, int error)
+{
+ char n;
+ int rc;
+
+ test_data.win = req->win;
+
+ rc = ProcXIGetClientPointer(&client_request);
+ assert(rc == error);
+
+ if (rc == BadWindow)
+ assert(client_request.errorValue == req->win);
+
+ client_request.swapped = TRUE;
+ swapl(&req->win, n);
+ swaps(&req->length, n);
+ rc = SProcXIGetClientPointer(&client_request);
+ assert(rc == error);
+
+ if (rc == BadWindow)
+ assert(client_request.errorValue == req->win);
+
+}
+
+static void test_XIGetClientPointer(void)
+{
+ xXIGetClientPointerReq request;
+
+ request_init(&request, XIGetClientPointer);
+
+ request.win = CLIENT_WINDOW_ID;
+
+
+ reply_handler = reply_XIGetClientPointer;
+
+ client_request = init_client(request.length, &request);
+
+ printf("Testing invalid window\n");
+ request.win = INVALID_WINDOW_ID;
+ request_XIGetClientPointer(&client_request, &request, BadWindow);
+
+ test_data.cp_is_set = FALSE;
+
+ printf("Testing window None, unset ClientPointer.\n");
+ request.win = None;
+ request_XIGetClientPointer(&client_request, &request, Success);
+
+ printf("Testing valid window, unset ClientPointer.\n");
+ request.win = CLIENT_WINDOW_ID;
+ request_XIGetClientPointer(&client_request, &request, Success);
+
+ printf("Testing valid window, set ClientPointer.\n");
+ client_window.clientPtr = devices.vcp;
+ test_data.dev = devices.vcp;
+ test_data.cp_is_set = TRUE;
+ request.win = CLIENT_WINDOW_ID;
+ request_XIGetClientPointer(&client_request, &request, Success);
+
+ client_window.clientPtr = NULL;
+
+ printf("Testing window None, set ClientPointer.\n");
+ client_request.clientPtr = devices.vcp;
+ test_data.dev = devices.vcp;
+ test_data.cp_is_set = TRUE;
+ request.win = None;
+ request_XIGetClientPointer(&client_request, &request, Success);
+}
+
+int main(int argc, char** argv)
+{
+ init_simple();
+ client_window = init_client(0, NULL);
+
+ test_XIGetClientPointer();
+
+ return 0;
+}
diff --git a/xorg-server/test/xi2/protocol-xigetselectedevents.c b/xorg-server/test/xi2/protocol-xigetselectedevents.c
index 97aae159f..b85f57aaf 100644
--- a/xorg-server/test/xi2/protocol-xigetselectedevents.c
+++ b/xorg-server/test/xi2/protocol-xigetselectedevents.c
@@ -1,241 +1,237 @@
-/**
- * Copyright © 2009 Red Hat, Inc.
- *
- * 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, sublicense,
- * 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 NONINFRINGEMENT. IN NO EVENT SHALL
- * THE AUTHORS OR COPYRIGHT HOLDERS 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.
- */
-
-#ifdef HAVE_DIX_CONFIG_H
-#include <dix-config.h>
-#endif
-
-/*
- * Protocol testing for XIGetSelectedEvents request.
- *
- * Tests include:
- * BadWindow on wrong window.
- * Zero-length masks if no masks are set.
- * Valid masks for valid devices.
- * Masks set on non-existent devices are not returned.
- *
- * Note that this test is not connected to the XISelectEvents request.
- */
-#include <stdint.h>
-#include <X11/X.h>
-#include <X11/Xproto.h>
-#include <X11/extensions/XI2proto.h>
-#include "inputstr.h"
-#include "windowstr.h"
-#include "extinit.h" /* for XInputExtensionInit */
-#include "scrnintstr.h"
-#include "xiselectev.h"
-#include "exevents.h"
-
-#include "protocol-common.h"
-#include <glib.h>
-
-static void reply_XIGetSelectedEvents(ClientPtr client, int len, char *data, void *userdata);
-static void reply_XIGetSelectedEvents_data(ClientPtr client, int len, char *data, void *userdata);
-
-
-struct {
- int num_masks_expected;
- unsigned char mask[MAXDEVICES][XI2LASTEVENT]; /* intentionally bigger */
- int mask_len;
-} test_data;
-
-/* dixLookupWindow requires a lot of setup not necessary for this test.
- * Simple wrapper that returns either one of the fake root window or the
- * fake client window. If the requested ID is neither of those wanted,
- * return whatever the real dixLookupWindow does.
- */
-int __wrap_dixLookupWindow(WindowPtr *win, XID id, ClientPtr client, Mask access)
-{
- if (id == root.drawable.id)
- {
- *win = &root;
- return Success;
- } else if (id == window.drawable.id)
- {
- *win = &window;
- return Success;
- }
-
- return __real_dixLookupWindow(win, id, client, access);
-}
-
-/* AddResource is called from XISetSEventMask, we don't need this */
-Bool __wrap_AddResource(XID id, RESTYPE type, pointer value)
-{
- return TRUE;
-}
-
-static void reply_XIGetSelectedEvents(ClientPtr client, int len, char *data, void *userdata)
-{
- xXIGetSelectedEventsReply *rep = (xXIGetSelectedEventsReply*)data;
-
- if (client->swapped)
- {
- char n;
- swapl(&rep->length, n);
- swaps(&rep->sequenceNumber, n);
- swaps(&rep->num_masks, n);
- }
-
- reply_check_defaults(rep, len, XIGetSelectedEvents);
-
- g_assert(rep->num_masks == test_data.num_masks_expected);
-
- reply_handler = reply_XIGetSelectedEvents_data;
-}
-
-static void reply_XIGetSelectedEvents_data(ClientPtr client, int len, char *data, void *userdata)
-{
- int i;
- xXIEventMask *mask;
- unsigned char *bitmask;
-
- mask = (xXIEventMask*)data;
- for (i = 0; i < test_data.num_masks_expected; i++)
- {
- if (client->swapped)
- {
- char n;
- swaps(&mask->deviceid, n);
- swaps(&mask->mask_len, n);
- }
-
- g_assert(mask->deviceid < 6);
- g_assert(mask->mask_len <= (((XI2LASTEVENT + 8)/8) + 3)/4) ;
-
- bitmask = (unsigned char*)&mask[1];
- g_assert(memcmp(bitmask,
- test_data.mask[mask->deviceid],
- mask->mask_len * 4) == 0);
-
- mask = (xXIEventMask*)((char*)mask + mask->mask_len * 4 + sizeof(xXIEventMask));
- }
-
-
-}
-
-static void request_XIGetSelectedEvents(xXIGetSelectedEventsReq* req, int error)
-{
- char n;
- int rc;
- ClientRec client;
- client = init_client(req->length, req);
-
- reply_handler = reply_XIGetSelectedEvents;
-
- rc = ProcXIGetSelectedEvents(&client);
- g_assert(rc == error);
-
- reply_handler = reply_XIGetSelectedEvents;
- client.swapped = TRUE;
- swapl(&req->win, n);
- swaps(&req->length, n);
- rc = SProcXIGetSelectedEvents(&client);
- g_assert(rc == error);
-}
-
-static void test_XIGetSelectedEvents(void)
-{
- int i, j;
- xXIGetSelectedEventsReq request;
- ClientRec client = init_client(0, NULL);
- unsigned char *mask;
- DeviceIntRec dev;
-
- request_init(&request, XIGetSelectedEvents);
-
- g_test_message("Testing for BadWindow on invalid window.");
- request.win = None;
- request_XIGetSelectedEvents(&request, BadWindow);
-
- g_test_message("Testing for zero-length (unset) masks.");
- /* No masks set yet */
- test_data.num_masks_expected = 0;
- request.win = ROOT_WINDOW_ID;
- request_XIGetSelectedEvents(&request, Success);
-
- request.win = CLIENT_WINDOW_ID;
- request_XIGetSelectedEvents(&request, Success);
-
- memset(test_data.mask, 0,
- sizeof(test_data.mask));
-
- g_test_message("Testing for valid masks");
- memset(&dev, 0, sizeof(dev)); /* dev->id is enough for XISetEventMask */
- request.win = ROOT_WINDOW_ID;
-
- /* devices 6 - MAXDEVICES don't exist, they mustn't be included in the
- * reply even if a mask is set */
- for (j = 0; j < MAXDEVICES; j++)
- {
- test_data.num_masks_expected = min(j + 1, devices.num_devices + 2);
- dev.id = j;
- mask = test_data.mask[j];
- /* bits one-by-one */
- for (i = 0; i < XI2LASTEVENT; i++)
- {
- SetBit(mask, i);
- XISetEventMask(&dev, &root, &client, (i + 8)/8, mask);
- request_XIGetSelectedEvents(&request, Success);
- ClearBit(mask, i);
- }
-
- /* all valid mask bits */
- for (i = 0; i < XI2LASTEVENT; i++)
- {
- SetBit(mask, i);
- XISetEventMask(&dev, &root, &client, (i + 8)/8, mask);
- request_XIGetSelectedEvents(&request, Success);
- }
- }
-
- g_test_message("Testing removing all masks");
- /* Unset all masks one-by-one */
- for (j = MAXDEVICES - 1; j >= 0; j--)
- {
- if (j < devices.num_devices + 2)
- test_data.num_masks_expected--;
-
- mask = test_data.mask[j];
- memset(mask, 0, XI2LASTEVENT);
-
- dev.id = j;
- XISetEventMask(&dev, &root, &client, 0, NULL);
-
- request_XIGetSelectedEvents(&request, Success);
- }
-}
-
-int main(int argc, char** argv)
-{
- g_test_init(&argc, &argv,NULL);
- g_test_bug_base("https://bugzilla.freedesktop.org/show_bug.cgi?id=");
-
- init_simple();
-
- g_test_add_func("/xi2/protocol/XIGetSelectedEvents", test_XIGetSelectedEvents);
-
- return g_test_run();
-}
-
+/**
+ * Copyright © 2009 Red Hat, Inc.
+ *
+ * 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, sublicense,
+ * 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 NONINFRINGEMENT. IN NO EVENT SHALL
+ * THE AUTHORS OR COPYRIGHT HOLDERS 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.
+ */
+
+#ifdef HAVE_DIX_CONFIG_H
+#include <dix-config.h>
+#endif
+
+/*
+ * Protocol testing for XIGetSelectedEvents request.
+ *
+ * Tests include:
+ * BadWindow on wrong window.
+ * Zero-length masks if no masks are set.
+ * Valid masks for valid devices.
+ * Masks set on non-existent devices are not returned.
+ *
+ * Note that this test is not connected to the XISelectEvents request.
+ */
+#include <stdint.h>
+#include <X11/X.h>
+#include <X11/Xproto.h>
+#include <X11/extensions/XI2proto.h>
+#include "inputstr.h"
+#include "windowstr.h"
+#include "extinit.h" /* for XInputExtensionInit */
+#include "scrnintstr.h"
+#include "xiselectev.h"
+#include "exevents.h"
+
+#include "protocol-common.h"
+
+static void reply_XIGetSelectedEvents(ClientPtr client, int len, char *data, void *userdata);
+static void reply_XIGetSelectedEvents_data(ClientPtr client, int len, char *data, void *userdata);
+
+
+struct {
+ int num_masks_expected;
+ unsigned char mask[MAXDEVICES][XI2LASTEVENT]; /* intentionally bigger */
+ int mask_len;
+} test_data;
+
+/* dixLookupWindow requires a lot of setup not necessary for this test.
+ * Simple wrapper that returns either one of the fake root window or the
+ * fake client window. If the requested ID is neither of those wanted,
+ * return whatever the real dixLookupWindow does.
+ */
+int __wrap_dixLookupWindow(WindowPtr *win, XID id, ClientPtr client, Mask access)
+{
+ if (id == root.drawable.id)
+ {
+ *win = &root;
+ return Success;
+ } else if (id == window.drawable.id)
+ {
+ *win = &window;
+ return Success;
+ }
+
+ return __real_dixLookupWindow(win, id, client, access);
+}
+
+/* AddResource is called from XISetSEventMask, we don't need this */
+Bool __wrap_AddResource(XID id, RESTYPE type, pointer value)
+{
+ return TRUE;
+}
+
+static void reply_XIGetSelectedEvents(ClientPtr client, int len, char *data, void *userdata)
+{
+ xXIGetSelectedEventsReply *rep = (xXIGetSelectedEventsReply*)data;
+
+ if (client->swapped)
+ {
+ char n;
+ swapl(&rep->length, n);
+ swaps(&rep->sequenceNumber, n);
+ swaps(&rep->num_masks, n);
+ }
+
+ reply_check_defaults(rep, len, XIGetSelectedEvents);
+
+ assert(rep->num_masks == test_data.num_masks_expected);
+
+ reply_handler = reply_XIGetSelectedEvents_data;
+}
+
+static void reply_XIGetSelectedEvents_data(ClientPtr client, int len, char *data, void *userdata)
+{
+ int i;
+ xXIEventMask *mask;
+ unsigned char *bitmask;
+
+ mask = (xXIEventMask*)data;
+ for (i = 0; i < test_data.num_masks_expected; i++)
+ {
+ if (client->swapped)
+ {
+ char n;
+ swaps(&mask->deviceid, n);
+ swaps(&mask->mask_len, n);
+ }
+
+ assert(mask->deviceid < 6);
+ assert(mask->mask_len <= (((XI2LASTEVENT + 8)/8) + 3)/4) ;
+
+ bitmask = (unsigned char*)&mask[1];
+ assert(memcmp(bitmask,
+ test_data.mask[mask->deviceid],
+ mask->mask_len * 4) == 0);
+
+ mask = (xXIEventMask*)((char*)mask + mask->mask_len * 4 + sizeof(xXIEventMask));
+ }
+
+
+}
+
+static void request_XIGetSelectedEvents(xXIGetSelectedEventsReq* req, int error)
+{
+ char n;
+ int rc;
+ ClientRec client;
+ client = init_client(req->length, req);
+
+ reply_handler = reply_XIGetSelectedEvents;
+
+ rc = ProcXIGetSelectedEvents(&client);
+ assert(rc == error);
+
+ reply_handler = reply_XIGetSelectedEvents;
+ client.swapped = TRUE;
+ swapl(&req->win, n);
+ swaps(&req->length, n);
+ rc = SProcXIGetSelectedEvents(&client);
+ assert(rc == error);
+}
+
+static void test_XIGetSelectedEvents(void)
+{
+ int i, j;
+ xXIGetSelectedEventsReq request;
+ ClientRec client = init_client(0, NULL);
+ unsigned char *mask;
+ DeviceIntRec dev;
+
+ request_init(&request, XIGetSelectedEvents);
+
+ printf("Testing for BadWindow on invalid window.\n");
+ request.win = None;
+ request_XIGetSelectedEvents(&request, BadWindow);
+
+ printf("Testing for zero-length (unset) masks.\n");
+ /* No masks set yet */
+ test_data.num_masks_expected = 0;
+ request.win = ROOT_WINDOW_ID;
+ request_XIGetSelectedEvents(&request, Success);
+
+ request.win = CLIENT_WINDOW_ID;
+ request_XIGetSelectedEvents(&request, Success);
+
+ memset(test_data.mask, 0,
+ sizeof(test_data.mask));
+
+ printf("Testing for valid masks\n");
+ memset(&dev, 0, sizeof(dev)); /* dev->id is enough for XISetEventMask */
+ request.win = ROOT_WINDOW_ID;
+
+ /* devices 6 - MAXDEVICES don't exist, they mustn't be included in the
+ * reply even if a mask is set */
+ for (j = 0; j < MAXDEVICES; j++)
+ {
+ test_data.num_masks_expected = min(j + 1, devices.num_devices + 2);
+ dev.id = j;
+ mask = test_data.mask[j];
+ /* bits one-by-one */
+ for (i = 0; i < XI2LASTEVENT; i++)
+ {
+ SetBit(mask, i);
+ XISetEventMask(&dev, &root, &client, (i + 8)/8, mask);
+ request_XIGetSelectedEvents(&request, Success);
+ ClearBit(mask, i);
+ }
+
+ /* all valid mask bits */
+ for (i = 0; i < XI2LASTEVENT; i++)
+ {
+ SetBit(mask, i);
+ XISetEventMask(&dev, &root, &client, (i + 8)/8, mask);
+ request_XIGetSelectedEvents(&request, Success);
+ }
+ }
+
+ printf("Testing removing all masks\n");
+ /* Unset all masks one-by-one */
+ for (j = MAXDEVICES - 1; j >= 0; j--)
+ {
+ if (j < devices.num_devices + 2)
+ test_data.num_masks_expected--;
+
+ mask = test_data.mask[j];
+ memset(mask, 0, XI2LASTEVENT);
+
+ dev.id = j;
+ XISetEventMask(&dev, &root, &client, 0, NULL);
+
+ request_XIGetSelectedEvents(&request, Success);
+ }
+}
+
+int main(int argc, char** argv)
+{
+ init_simple();
+
+ test_XIGetSelectedEvents();
+
+ return 0;
+}
+
diff --git a/xorg-server/test/xi2/protocol-xipassivegrabdevice.c b/xorg-server/test/xi2/protocol-xipassivegrabdevice.c
new file mode 100644
index 000000000..a61c1549c
--- /dev/null
+++ b/xorg-server/test/xi2/protocol-xipassivegrabdevice.c
@@ -0,0 +1,234 @@
+/**
+ * Copyright © 2011 Red Hat, Inc.
+ *
+ * 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, sublicense,
+ * 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 NONINFRINGEMENT. IN NO EVENT SHALL
+ * THE AUTHORS OR COPYRIGHT HOLDERS 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.
+ */
+
+#ifdef HAVE_DIX_CONFIG_H
+#include <dix-config.h>
+#endif
+
+/*
+ * Protocol testing for XIPassiveGrab request.
+ */
+#include <stdint.h>
+#include <X11/X.h>
+#include <X11/Xproto.h>
+#include <X11/extensions/XI2proto.h>
+#include "inputstr.h"
+#include "windowstr.h"
+#include "scrnintstr.h"
+#include "xipassivegrab.h"
+#include "exevents.h"
+
+#include "protocol-common.h"
+
+static ClientRec client_request;
+#define N_MODS 7
+static uint32_t modifiers[N_MODS] = {1, 2, 3, 4, 5, 6, 7};
+
+struct test_data {
+ int num_modifiers;
+} testdata;
+
+int __wrap_GrabButton(ClientPtr client, DeviceIntPtr dev, DeviceIntPtr modifier_device,
+ int button, GrabParameters *param, GrabType grabtype,
+ GrabMask *mask);
+static void reply_XIPassiveGrabDevice_data(ClientPtr client, int len, char *data, void *userdata);
+
+int __wrap_dixLookupWindow(WindowPtr *win, XID id, ClientPtr client, Mask access)
+{
+ if (id == root.drawable.id)
+ {
+ *win = &root;
+ return Success;
+ } else if (id == window.drawable.id)
+ {
+ *win = &window;
+ return Success;
+ }
+
+ return __real_dixLookupWindow(win, id, client, access);
+}
+
+int __wrap_GrabButton(ClientPtr client, DeviceIntPtr dev, DeviceIntPtr modifier_device,
+ int button, GrabParameters *param, GrabType grabtype,
+ GrabMask *mask)
+{
+ /* Fail every odd modifier */
+ if (param->modifiers % 2)
+ return BadAccess;
+
+ return Success;
+}
+
+static void reply_XIPassiveGrabDevice(ClientPtr client, int len, char *data, void *userdata)
+{
+ xXIPassiveGrabDeviceReply *rep = (xXIPassiveGrabDeviceReply*)data;
+
+ if (client->swapped)
+ {
+ char n;
+ swaps(&rep->sequenceNumber, n);
+ swapl(&rep->length, n);
+ swaps(&rep->num_modifiers, n);
+
+ testdata.num_modifiers = rep->num_modifiers;
+ }
+
+ reply_check_defaults(rep, len, XIPassiveGrabDevice);
+
+ /* ProcXIPassiveGrabDevice sends the data in two batches, let the second
+ * handler handle the modifier data */
+ if (rep->num_modifiers > 0)
+ reply_handler = reply_XIPassiveGrabDevice_data;
+}
+
+static void reply_XIPassiveGrabDevice_data(ClientPtr client, int len, char *data, void *userdata)
+{
+ int i;
+ int n;
+
+ xXIGrabModifierInfo *mods = (xXIGrabModifierInfo*)data;
+
+ for (i = 0; i < testdata.num_modifiers; i++, mods++)
+ {
+ if (client->swapped)
+ swapl(&mods->modifiers, n);
+
+ /* 1 - 7 is the range we use for the global modifiers array
+ * above */
+ assert(mods->modifiers > 0);
+ assert(mods->modifiers <= 7);
+ assert(mods->modifiers % 2 == 1); /* because we fail odd ones */
+ assert(mods->status != Success);
+ assert(mods->pad0 == 0);
+ assert(mods->pad1 == 0);
+ }
+
+ reply_handler = reply_XIPassiveGrabDevice;
+}
+
+static void request_XIPassiveGrabDevice(ClientPtr client, xXIPassiveGrabDeviceReq* req, int error, int errval)
+{
+ char n;
+ int rc;
+ int modifiers;
+
+ rc = ProcXIPassiveGrabDevice(&client_request);
+ assert(rc == error);
+
+ if (rc != Success)
+ assert(client_request.errorValue == errval);
+
+ client_request.swapped = TRUE;
+ swaps(&req->length, n);
+ swapl(&req->time, n);
+ swapl(&req->grab_window, n);
+ swapl(&req->cursor, n);
+ swapl(&req->detail, n);
+ swaps(&req->deviceid, n);
+ modifiers = req->num_modifiers;
+ swaps(&req->num_modifiers, n);
+ swaps(&req->mask_len, n);
+
+ while(modifiers--)
+ {
+ CARD32 *mod = ((CARD32*)(req + 1)) + modifiers;
+ swapl(mod, n);
+ }
+
+ rc = SProcXIPassiveGrabDevice(&client_request);
+ assert(rc == error);
+
+ if (rc != Success)
+ assert(client_request.errorValue == errval);
+}
+
+static unsigned char *data[4096]; /* the request buffer */
+static void test_XIPassiveGrabDevice(void)
+{
+ int i;
+ xXIPassiveGrabDeviceReq *request = (xXIPassiveGrabDeviceReq*)data;
+ unsigned char *mask;
+
+ request_init(request, XIPassiveGrabDevice);
+
+ request->grab_window = CLIENT_WINDOW_ID;
+
+ reply_handler = reply_XIPassiveGrabDevice;
+ client_request = init_client(request->length, request);
+
+ printf("Testing invalid device\n");
+ request->deviceid = 12;
+ request_XIPassiveGrabDevice(&client_request, request, BadDevice, request->deviceid);
+
+ request->deviceid = XIAllMasterDevices;
+
+ printf("Testing invalid grab types\n");
+ for (i = XIGrabtypeFocusIn + 1; i < 0xFF; i++)
+ {
+ request->grab_type = i;
+ request_XIPassiveGrabDevice(&client_request, request, BadValue, request->grab_type);
+ }
+
+ printf("Testing invalid grab type + detail combinations\n");
+ request->grab_type = XIGrabtypeEnter;
+ request->detail = 1;
+ request_XIPassiveGrabDevice(&client_request, request, BadValue, request->detail);
+
+ request->grab_type = XIGrabtypeFocusIn;
+ request_XIPassiveGrabDevice(&client_request, request, BadValue, request->detail);
+
+ request->detail = 0;
+
+ printf("Testing invalid masks\n");
+ mask = (unsigned char*)&request[1];
+
+ request->mask_len = bytes_to_int32(XI2LASTEVENT + 1);
+ request->length += request->mask_len;
+ SetBit(mask, XI2LASTEVENT + 1);
+ request_XIPassiveGrabDevice(&client_request, request, BadValue, XI2LASTEVENT + 1);
+
+ ClearBit(mask, XI2LASTEVENT + 1);
+
+ /* tested all special cases now, test a few valid cases */
+
+ /* no modifiers */
+ request->deviceid = XIAllDevices;
+ request->grab_type = XIGrabtypeButton;
+ request->detail = XIAnyButton;
+ request_XIPassiveGrabDevice(&client_request, request, Success, 0);
+
+ /* some modifiers */
+ request->num_modifiers = N_MODS;
+ request->length += N_MODS;
+ memcpy((uint32_t*)(request + 1) + request->mask_len, modifiers, sizeof(modifiers));
+ request_XIPassiveGrabDevice(&client_request, request, Success, 0);
+}
+
+int main(int argc, char** argv)
+{
+ init_simple();
+
+ test_XIPassiveGrabDevice();
+
+ return 0;
+}
diff --git a/xorg-server/test/xi2/protocol-xiquerydevice.c b/xorg-server/test/xi2/protocol-xiquerydevice.c
index 508fc4dfb..7a631e0dd 100644
--- a/xorg-server/test/xi2/protocol-xiquerydevice.c
+++ b/xorg-server/test/xi2/protocol-xiquerydevice.c
@@ -1,316 +1,312 @@
-/**
- * Copyright © 2009 Red Hat, Inc.
- *
- * 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, sublicense,
- * 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 NONINFRINGEMENT. IN NO EVENT SHALL
- * THE AUTHORS OR COPYRIGHT HOLDERS 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.
- */
-
-#ifdef HAVE_DIX_CONFIG_H
-#include <dix-config.h>
-#endif
-
-#include <stdint.h>
-#include <X11/X.h>
-#include <X11/Xproto.h>
-#include <X11/extensions/XI2proto.h>
-#include <X11/Xatom.h>
-#include "inputstr.h"
-#include "extinit.h"
-#include "scrnintstr.h"
-#include "xkbsrv.h"
-
-#include "xiquerydevice.h"
-
-#include "protocol-common.h"
-#include <glib.h>
-/*
- * Protocol testing for XIQueryDevice request and reply.
- *
- * Test approach:
- * Wrap WriteToClient to intercept server's reply. ProcXIQueryDevice returns
- * data in two batches, once for the request, once for the trailing data
- * with the device information.
- * Repeatedly test with varying deviceids and check against data in reply.
- */
-
-struct test_data {
- int which_device;
- int num_devices_in_reply;
-};
-
-static void reply_XIQueryDevice_data(ClientPtr client, int len, char *data, void *userdata);
-static void reply_XIQueryDevice(ClientPtr client, int len, char* data, void *userdata);
-
-/* reply handling for the first bytes that constitute the reply */
-static void reply_XIQueryDevice(ClientPtr client, int len, char* data, void *userdata)
-{
- xXIQueryDeviceReply *rep = (xXIQueryDeviceReply*)data;
- struct test_data *querydata = (struct test_data*)userdata;
-
- if (client->swapped)
- {
- char n;
- swapl(&rep->length, n);
- swaps(&rep->sequenceNumber, n);
- swaps(&rep->num_devices, n);
- }
-
- reply_check_defaults(rep, len, XIQueryDevice);
-
- if (querydata->which_device == XIAllDevices)
- g_assert(rep->num_devices == devices.num_devices);
- else if (querydata->which_device == XIAllMasterDevices)
- g_assert(rep->num_devices == devices.num_master_devices);
- else
- g_assert(rep->num_devices == 1);
-
- querydata->num_devices_in_reply = rep->num_devices;
- reply_handler = reply_XIQueryDevice_data;
-}
-
-/* reply handling for the trailing bytes that constitute the device info */
-static void reply_XIQueryDevice_data(ClientPtr client, int len, char *data, void *userdata)
-{
- char n;
- int i, j;
- struct test_data *querydata = (struct test_data*)userdata;
-
- DeviceIntPtr dev;
- xXIDeviceInfo *info = (xXIDeviceInfo*)data;
- xXIAnyInfo *any;
-
- for (i = 0; i < querydata->num_devices_in_reply; i++)
- {
- if (client->swapped)
- {
- swaps(&info->deviceid, n);
- swaps(&info->attachment, n);
- swaps(&info->use, n);
- swaps(&info->num_classes, n);
- swaps(&info->name_len, n);
- }
-
- if (querydata->which_device > XIAllMasterDevices)
- g_assert(info->deviceid == querydata->which_device);
-
- g_assert(info->deviceid >= 2); /* 0 and 1 is reserved */
-
-
- switch(info->deviceid)
- {
- case 2: /* VCP */
- dev = devices.vcp;
- g_assert(info->use == XIMasterPointer);
- g_assert(info->attachment == devices.vck->id);
- g_assert(info->num_classes == 3); /* 2 axes + button */
- break;
- case 3: /* VCK */
- dev = devices.vck;
- g_assert(info->use == XIMasterKeyboard);
- g_assert(info->attachment == devices.vcp->id);
- g_assert(info->num_classes == 1);
- break;
- case 4: /* mouse */
- dev = devices.mouse;
- g_assert(info->use == XISlavePointer);
- g_assert(info->attachment == devices.vcp->id);
- g_assert(info->num_classes == 3); /* 2 axes + button */
- break;
- case 5: /* keyboard */
- dev = devices.kbd;
- g_assert(info->use == XISlaveKeyboard);
- g_assert(info->attachment == devices.vck->id);
- g_assert(info->num_classes == 1);
- break;
-
- default:
- /* We shouldn't get here */
- g_assert(0);
- break;
- }
- g_assert(info->enabled == dev->enabled);
- g_assert(info->name_len == strlen(dev->name));
- g_assert(strncmp((char*)&info[1], dev->name, info->name_len) == 0);
-
- any = (xXIAnyInfo*)((char*)&info[1] + ((info->name_len + 3)/4) * 4);
- for (j = 0; j < info->num_classes; j++)
- {
- if (client->swapped)
- {
- swaps(&any->type, n);
- swaps(&any->length, n);
- swaps(&any->sourceid, n);
- }
-
- switch(info->deviceid)
- {
- case 3: /* VCK and kbd have the same properties */
- case 5:
- {
- int k;
- xXIKeyInfo *ki = (xXIKeyInfo*)any;
- XkbDescPtr xkb = devices.vck->key->xkbInfo->desc;
- uint32_t *kc;
-
- if (client->swapped)
- swaps(&ki->num_keycodes, n);
-
- g_assert(any->type == XIKeyClass);
- g_assert(ki->num_keycodes == (xkb->max_key_code - xkb->min_key_code + 1));
- g_assert(any->length == (2 + ki->num_keycodes));
-
- kc = (uint32_t*)&ki[1];
- for (k = 0; k < ki->num_keycodes; k++, kc++)
- {
- if (client->swapped)
- swapl(kc, n);
-
- g_assert(*kc >= xkb->min_key_code);
- g_assert(*kc <= xkb->max_key_code);
- }
- break;
- }
- case 2: /* VCP and mouse have the same properties */
- case 4:
- {
- g_assert(any->type == XIButtonClass ||
- any->type == XIValuatorClass);
-
- if (any->type == XIButtonClass)
- {
- int len;
- xXIButtonInfo *bi = (xXIButtonInfo*)any;
-
- if (client->swapped)
- swaps(&bi->num_buttons, n);
-
- g_assert(bi->num_buttons == devices.vcp->button->numButtons);
-
- len = 2 + bi->num_buttons + bytes_to_int32(bits_to_bytes(bi->num_buttons));
- g_assert(bi->length == len);
- } else if (any->type == XIValuatorClass)
- {
- xXIValuatorInfo *vi = (xXIValuatorInfo*)any;
-
- if (client->swapped)
- {
- swaps(&vi->number, n);
- swapl(&vi->label, n);
- swapl(&vi->min.integral, n);
- swapl(&vi->min.frac, n);
- swapl(&vi->max.integral, n);
- swapl(&vi->max.frac, n);
- swapl(&vi->resolution, n);
- }
-
- g_assert(vi->length == 11);
- g_assert(vi->number == 0 ||
- vi->number == 1);
- g_assert(vi->mode == XIModeRelative);
- /* device was set up as relative, so standard
- * values here. */
- g_assert(vi->min.integral == -1);
- g_assert(vi->min.frac == 0);
- g_assert(vi->max.integral == -1);
- g_assert(vi->max.frac == 0);
- g_assert(vi->resolution == 0);
- }
- }
- break;
- }
- any = (xXIAnyInfo*)(((char*)any) + any->length * 4);
- }
-
- info = (xXIDeviceInfo*)any;
- }
-}
-
-static void request_XIQueryDevice(struct test_data *querydata,
- int deviceid, int error)
-{
- int rc;
- char n;
- ClientRec client;
- xXIQueryDeviceReq request;
-
- request_init(&request, XIQueryDevice);
- client = init_client(request.length, &request);
- reply_handler = reply_XIQueryDevice;
-
- querydata->which_device = deviceid;
-
- request.deviceid = deviceid;
- rc = ProcXIQueryDevice(&client);
- g_assert(rc == error);
-
- if (rc != Success)
- g_assert(client.errorValue == deviceid);
-
- reply_handler = reply_XIQueryDevice;
-
- client.swapped = TRUE;
- swaps(&request.length, n);
- swaps(&request.deviceid, n);
- rc = SProcXIQueryDevice(&client);
- g_assert(rc == error);
-
- if (rc != Success)
- g_assert(client.errorValue == deviceid);
-}
-
-static void test_XIQueryDevice(void)
-{
- int i;
- xXIQueryDeviceReq request;
- struct test_data data;
-
- reply_handler = reply_XIQueryDevice;
- userdata = &data;
- request_init(&request, XIQueryDevice);
-
- g_test_message("Testing XIAllDevices.");
- request_XIQueryDevice(&data, XIAllDevices, Success);
- g_test_message("Testing XIAllMasterDevices.");
- request_XIQueryDevice(&data, XIAllMasterDevices, Success);
-
- g_test_message("Testing existing device ids.");
- for (i = 2; i < 6; i++)
- request_XIQueryDevice(&data, i, Success);
-
- g_test_message("Testing non-existing device ids.");
- for (i = 6; i <= 0xFFFF; i++)
- request_XIQueryDevice(&data, i, BadDevice);
-
-
- reply_handler = NULL;
-
-}
-
-int main(int argc, char** argv)
-{
- g_test_init(&argc, &argv,NULL);
- g_test_bug_base("https://bugzilla.freedesktop.org/show_bug.cgi?id=");
-
- init_simple();
-
- g_test_add_func("/dix/xi2protocol/XIQueryDevice", test_XIQueryDevice);
-
- return g_test_run();
-}
-
+/**
+ * Copyright © 2009 Red Hat, Inc.
+ *
+ * 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, sublicense,
+ * 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 NONINFRINGEMENT. IN NO EVENT SHALL
+ * THE AUTHORS OR COPYRIGHT HOLDERS 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.
+ */
+
+#ifdef HAVE_DIX_CONFIG_H
+#include <dix-config.h>
+#endif
+
+#include <stdint.h>
+#include <X11/X.h>
+#include <X11/Xproto.h>
+#include <X11/extensions/XI2proto.h>
+#include <X11/Xatom.h>
+#include "inputstr.h"
+#include "extinit.h"
+#include "scrnintstr.h"
+#include "xkbsrv.h"
+
+#include "xiquerydevice.h"
+
+#include "protocol-common.h"
+/*
+ * Protocol testing for XIQueryDevice request and reply.
+ *
+ * Test approach:
+ * Wrap WriteToClient to intercept server's reply. ProcXIQueryDevice returns
+ * data in two batches, once for the request, once for the trailing data
+ * with the device information.
+ * Repeatedly test with varying deviceids and check against data in reply.
+ */
+
+struct test_data {
+ int which_device;
+ int num_devices_in_reply;
+};
+
+static void reply_XIQueryDevice_data(ClientPtr client, int len, char *data, void *userdata);
+static void reply_XIQueryDevice(ClientPtr client, int len, char* data, void *userdata);
+
+/* reply handling for the first bytes that constitute the reply */
+static void reply_XIQueryDevice(ClientPtr client, int len, char* data, void *userdata)
+{
+ xXIQueryDeviceReply *rep = (xXIQueryDeviceReply*)data;
+ struct test_data *querydata = (struct test_data*)userdata;
+
+ if (client->swapped)
+ {
+ char n;
+ swapl(&rep->length, n);
+ swaps(&rep->sequenceNumber, n);
+ swaps(&rep->num_devices, n);
+ }
+
+ reply_check_defaults(rep, len, XIQueryDevice);
+
+ if (querydata->which_device == XIAllDevices)
+ assert(rep->num_devices == devices.num_devices);
+ else if (querydata->which_device == XIAllMasterDevices)
+ assert(rep->num_devices == devices.num_master_devices);
+ else
+ assert(rep->num_devices == 1);
+
+ querydata->num_devices_in_reply = rep->num_devices;
+ reply_handler = reply_XIQueryDevice_data;
+}
+
+/* reply handling for the trailing bytes that constitute the device info */
+static void reply_XIQueryDevice_data(ClientPtr client, int len, char *data, void *userdata)
+{
+ char n;
+ int i, j;
+ struct test_data *querydata = (struct test_data*)userdata;
+
+ DeviceIntPtr dev;
+ xXIDeviceInfo *info = (xXIDeviceInfo*)data;
+ xXIAnyInfo *any;
+
+ for (i = 0; i < querydata->num_devices_in_reply; i++)
+ {
+ if (client->swapped)
+ {
+ swaps(&info->deviceid, n);
+ swaps(&info->attachment, n);
+ swaps(&info->use, n);
+ swaps(&info->num_classes, n);
+ swaps(&info->name_len, n);
+ }
+
+ if (querydata->which_device > XIAllMasterDevices)
+ assert(info->deviceid == querydata->which_device);
+
+ assert(info->deviceid >= 2); /* 0 and 1 is reserved */
+
+
+ switch(info->deviceid)
+ {
+ case 2: /* VCP */
+ dev = devices.vcp;
+ assert(info->use == XIMasterPointer);
+ assert(info->attachment == devices.vck->id);
+ assert(info->num_classes == 3); /* 2 axes + button */
+ break;
+ case 3: /* VCK */
+ dev = devices.vck;
+ assert(info->use == XIMasterKeyboard);
+ assert(info->attachment == devices.vcp->id);
+ assert(info->num_classes == 1);
+ break;
+ case 4: /* mouse */
+ dev = devices.mouse;
+ assert(info->use == XISlavePointer);
+ assert(info->attachment == devices.vcp->id);
+ assert(info->num_classes == 3); /* 2 axes + button */
+ break;
+ case 5: /* keyboard */
+ dev = devices.kbd;
+ assert(info->use == XISlaveKeyboard);
+ assert(info->attachment == devices.vck->id);
+ assert(info->num_classes == 1);
+ break;
+
+ default:
+ /* We shouldn't get here */
+ assert(0);
+ break;
+ }
+ assert(info->enabled == dev->enabled);
+ assert(info->name_len == strlen(dev->name));
+ assert(strncmp((char*)&info[1], dev->name, info->name_len) == 0);
+
+ any = (xXIAnyInfo*)((char*)&info[1] + ((info->name_len + 3)/4) * 4);
+ for (j = 0; j < info->num_classes; j++)
+ {
+ if (client->swapped)
+ {
+ swaps(&any->type, n);
+ swaps(&any->length, n);
+ swaps(&any->sourceid, n);
+ }
+
+ switch(info->deviceid)
+ {
+ case 3: /* VCK and kbd have the same properties */
+ case 5:
+ {
+ int k;
+ xXIKeyInfo *ki = (xXIKeyInfo*)any;
+ XkbDescPtr xkb = devices.vck->key->xkbInfo->desc;
+ uint32_t *kc;
+
+ if (client->swapped)
+ swaps(&ki->num_keycodes, n);
+
+ assert(any->type == XIKeyClass);
+ assert(ki->num_keycodes == (xkb->max_key_code - xkb->min_key_code + 1));
+ assert(any->length == (2 + ki->num_keycodes));
+
+ kc = (uint32_t*)&ki[1];
+ for (k = 0; k < ki->num_keycodes; k++, kc++)
+ {
+ if (client->swapped)
+ swapl(kc, n);
+
+ assert(*kc >= xkb->min_key_code);
+ assert(*kc <= xkb->max_key_code);
+ }
+ break;
+ }
+ case 2: /* VCP and mouse have the same properties */
+ case 4:
+ {
+ assert(any->type == XIButtonClass ||
+ any->type == XIValuatorClass);
+
+ if (any->type == XIButtonClass)
+ {
+ int len;
+ xXIButtonInfo *bi = (xXIButtonInfo*)any;
+
+ if (client->swapped)
+ swaps(&bi->num_buttons, n);
+
+ assert(bi->num_buttons == devices.vcp->button->numButtons);
+
+ len = 2 + bi->num_buttons + bytes_to_int32(bits_to_bytes(bi->num_buttons));
+ assert(bi->length == len);
+ } else if (any->type == XIValuatorClass)
+ {
+ xXIValuatorInfo *vi = (xXIValuatorInfo*)any;
+
+ if (client->swapped)
+ {
+ swaps(&vi->number, n);
+ swapl(&vi->label, n);
+ swapl(&vi->min.integral, n);
+ swapl(&vi->min.frac, n);
+ swapl(&vi->max.integral, n);
+ swapl(&vi->max.frac, n);
+ swapl(&vi->resolution, n);
+ }
+
+ assert(vi->length == 11);
+ assert(vi->number == 0 ||
+ vi->number == 1);
+ assert(vi->mode == XIModeRelative);
+ /* device was set up as relative, so standard
+ * values here. */
+ assert(vi->min.integral == -1);
+ assert(vi->min.frac == 0);
+ assert(vi->max.integral == -1);
+ assert(vi->max.frac == 0);
+ assert(vi->resolution == 0);
+ }
+ }
+ break;
+ }
+ any = (xXIAnyInfo*)(((char*)any) + any->length * 4);
+ }
+
+ info = (xXIDeviceInfo*)any;
+ }
+}
+
+static void request_XIQueryDevice(struct test_data *querydata,
+ int deviceid, int error)
+{
+ int rc;
+ char n;
+ ClientRec client;
+ xXIQueryDeviceReq request;
+
+ request_init(&request, XIQueryDevice);
+ client = init_client(request.length, &request);
+ reply_handler = reply_XIQueryDevice;
+
+ querydata->which_device = deviceid;
+
+ request.deviceid = deviceid;
+ rc = ProcXIQueryDevice(&client);
+ assert(rc == error);
+
+ if (rc != Success)
+ assert(client.errorValue == deviceid);
+
+ reply_handler = reply_XIQueryDevice;
+
+ client.swapped = TRUE;
+ swaps(&request.length, n);
+ swaps(&request.deviceid, n);
+ rc = SProcXIQueryDevice(&client);
+ assert(rc == error);
+
+ if (rc != Success)
+ assert(client.errorValue == deviceid);
+}
+
+static void test_XIQueryDevice(void)
+{
+ int i;
+ xXIQueryDeviceReq request;
+ struct test_data data;
+
+ reply_handler = reply_XIQueryDevice;
+ userdata = &data;
+ request_init(&request, XIQueryDevice);
+
+ printf("Testing XIAllDevices.\n");
+ request_XIQueryDevice(&data, XIAllDevices, Success);
+ printf("Testing XIAllMasterDevices.\n");
+ request_XIQueryDevice(&data, XIAllMasterDevices, Success);
+
+ printf("Testing existing device ids.\n");
+ for (i = 2; i < 6; i++)
+ request_XIQueryDevice(&data, i, Success);
+
+ printf("Testing non-existing device ids.\n");
+ for (i = 6; i <= 0xFFFF; i++)
+ request_XIQueryDevice(&data, i, BadDevice);
+
+
+ reply_handler = NULL;
+
+}
+
+int main(int argc, char** argv)
+{
+ init_simple();
+
+ test_XIQueryDevice();
+
+ return 0;
+}
+
diff --git a/xorg-server/test/xi2/protocol-xiquerypointer.c b/xorg-server/test/xi2/protocol-xiquerypointer.c
index 95c8b4bc1..15ebc5a24 100644
--- a/xorg-server/test/xi2/protocol-xiquerypointer.c
+++ b/xorg-server/test/xi2/protocol-xiquerypointer.c
@@ -39,7 +39,6 @@
#include "exevents.h"
#include "protocol-common.h"
-#include <glib.h>
static ClientRec client_request;
static void reply_XIQueryPointer_data(ClientPtr client, int len,
@@ -96,18 +95,18 @@ static void reply_XIQueryPointer(ClientPtr client, int len, char *data,
reply_check_defaults(rep, len, XIQueryPointer);
- g_assert(rep->root == root.drawable.id);
- g_assert(rep->same_screen == xTrue);
+ assert(rep->root == root.drawable.id);
+ assert(rep->same_screen == xTrue);
sprite = test_data.dev->spriteInfo->sprite;
- g_assert((rep->root_x >> 16) == sprite->hot.x);
- g_assert((rep->root_y >> 16) == sprite->hot.y);
+ assert((rep->root_x >> 16) == sprite->hot.x);
+ assert((rep->root_y >> 16) == sprite->hot.y);
if (test_data.win == &root)
{
- g_assert(rep->root_x == rep->win_x);
- g_assert(rep->root_y == rep->win_y);
- g_assert(rep->child == window.drawable.id);
+ assert(rep->root_x == rep->win_x);
+ assert(rep->root_y == rep->win_y);
+ assert(rep->child == window.drawable.id);
} else
{
int x, y;
@@ -115,13 +114,13 @@ static void reply_XIQueryPointer(ClientPtr client, int len, char *data,
x = sprite->hot.x - window.drawable.x;
y = sprite->hot.y - window.drawable.y;
- g_assert((rep->win_x >> 16) == x);
- g_assert((rep->win_y >> 16) == y);
- g_assert(rep->child == None);
+ assert((rep->win_x >> 16) == x);
+ assert((rep->win_y >> 16) == y);
+ assert(rep->child == None);
}
- g_assert(rep->same_screen == xTrue);
+ assert(rep->same_screen == xTrue);
reply_handler = reply_XIQueryPointer_data;
}
@@ -137,19 +136,19 @@ static void request_XIQueryPointer(ClientPtr client, xXIQueryPointerReq* req, in
int rc;
rc = ProcXIQueryPointer(&client_request);
- g_assert(rc == error);
+ assert(rc == error);
if (rc == BadDevice)
- g_assert(client_request.errorValue == req->deviceid);
+ assert(client_request.errorValue == req->deviceid);
client_request.swapped = TRUE;
swaps(&req->deviceid, n);
swaps(&req->length, n);
rc = SProcXIQueryPointer(&client_request);
- g_assert(rc == error);
+ assert(rc == error);
if (rc == BadDevice)
- g_assert(client_request.errorValue == req->deviceid);
+ assert(client_request.errorValue == req->deviceid);
}
static void test_XIQueryPointer(void)
@@ -209,12 +208,9 @@ static void test_XIQueryPointer(void)
int main(int argc, char** argv)
{
- g_test_init(&argc, &argv,NULL);
- g_test_bug_base("https://bugzilla.freedesktop.org/show_bug.cgi?id=");
-
init_simple();
- g_test_add_func("/xi2/protocol/XIQueryPointer", test_XIQueryPointer);
+ test_XIQueryPointer();
- return g_test_run();
+ return 0;
}
diff --git a/xorg-server/test/xi2/protocol-xiqueryversion.c b/xorg-server/test/xi2/protocol-xiqueryversion.c
index 46e62acbd..7c4c018b1 100644
--- a/xorg-server/test/xi2/protocol-xiqueryversion.c
+++ b/xorg-server/test/xi2/protocol-xiqueryversion.c
@@ -1,186 +1,182 @@
-/**
- * Copyright © 2009 Red Hat, Inc.
- *
- * 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, sublicense,
- * 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 NONINFRINGEMENT. IN NO EVENT SHALL
- * THE AUTHORS OR COPYRIGHT HOLDERS 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.
- */
-
-#ifdef HAVE_DIX_CONFIG_H
-#include <dix-config.h>
-#endif
-
-/*
- * Protocol testing for XIQueryVersion request and reply.
- *
- * Test approach:
- * Wrap WriteToClient to intercept the server's reply.
- * Repeatedly test a client/server version combination, compare version in
- * reply with versions given. Version must be equal to either
- * server version or client version, whichever is smaller.
- * Client version less than 2 must return BadValue.
- */
-
-#include <stdint.h>
-#include <X11/X.h>
-#include <X11/Xproto.h>
-#include <X11/extensions/XI2proto.h>
-#include "inputstr.h"
-#include "extinit.h" /* for XInputExtensionInit */
-#include "scrnintstr.h"
-#include "xiqueryversion.h"
-
-#include "protocol-common.h"
-#include <glib.h>
-
-extern XExtensionVersion XIVersion;
-
-struct test_data {
- int major_client;
- int minor_client;
- int major_server;
- int minor_server;
-};
-
-static void reply_XIQueryVersion(ClientPtr client, int len, char* data, void *userdata)
-{
- xXIQueryVersionReply *rep = (xXIQueryVersionReply*)data;
- struct test_data *versions = (struct test_data*)userdata;
- unsigned int sver, cver, ver;
-
- if (client->swapped)
- {
- char n;
- swapl(&rep->length, n);
- swaps(&rep->sequenceNumber, n);
- swaps(&rep->major_version, n);
- swaps(&rep->minor_version, n);
- }
-
- reply_check_defaults(rep, len, XIQueryVersion);
-
- g_assert(rep->length == 0);
-
- sver = versions->major_server * 1000 + versions->minor_server;
- cver = versions->major_client * 1000 + versions->minor_client;
- ver = rep->major_version * 1000 + rep->minor_version;
-
- g_assert(ver >= 2000);
- g_assert((sver > cver) ? ver == cver : ver == sver);
-}
-
-/**
- * Run a single test with server version smaj.smin and client
- * version cmaj.cmin. Verify that return code is equal to 'error'.
- *
- * Test is run normal, then for a swapped client.
- */
-static void request_XIQueryVersion(int smaj, int smin, int cmaj, int cmin, int error)
-{
- char n;
- int rc;
- struct test_data versions;
- xXIQueryVersionReq request;
- ClientRec client;
-
- request_init(&request, XIQueryVersion);
- client = init_client(request.length, &request);
- userdata = (void*)&versions;
-
- /* Change the server to support smaj.smin */
- XIVersion.major_version = smaj;
- XIVersion.minor_version = smin;
-
- /* remember versions we send and expect */
- versions.major_client = cmaj;
- versions.minor_client = cmin;
- versions.major_server = XIVersion.major_version;
- versions.minor_server = XIVersion.minor_version;
-
- request.major_version = versions.major_client;
- request.minor_version = versions.minor_client;
- rc = ProcXIQueryVersion(&client);
- g_assert(rc == error);
-
- client.swapped = TRUE;
-
- swaps(&request.length, n);
- swaps(&request.major_version, n);
- swaps(&request.minor_version, n);
-
- rc = SProcXIQueryVersion(&client);
- g_assert(rc == error);
-}
-
-/* Client version less than 2.0 must return BadValue, all other combinations
- * Success */
-static void test_XIQueryVersion(void)
-{
- reply_handler = reply_XIQueryVersion;
-
- g_test_message("Server version 2.0 - client versions [1..3].0");
- /* some simple tests to catch common errors quickly */
- request_XIQueryVersion(2, 0, 1, 0, BadValue);
- request_XIQueryVersion(2, 0, 2, 0, Success);
- request_XIQueryVersion(2, 0, 3, 0, Success);
-
- g_test_message("Server version 3.0 - client versions [1..3].0");
- request_XIQueryVersion(3, 0, 1, 0, BadValue);
- request_XIQueryVersion(3, 0, 2, 0, Success);
- request_XIQueryVersion(3, 0, 3, 0, Success);
-
- g_test_message("Server version 2.0 - client versions [1..3].[1..3]");
- request_XIQueryVersion(2, 0, 1, 1, BadValue);
- request_XIQueryVersion(2, 0, 2, 2, Success);
- request_XIQueryVersion(2, 0, 3, 3, Success);
-
- g_test_message("Server version 2.2 - client versions [1..3].0");
- request_XIQueryVersion(2, 2, 1, 0, BadValue);
- request_XIQueryVersion(2, 2, 2, 0, Success);
- request_XIQueryVersion(2, 2, 3, 0, Success);
-
-#if 0
- /* this one takes a while */
- unsigned int cmin, cmaj, smin, smaj;
-
- g_test_message("Testing all combinations.");
- for (smaj = 2; smaj <= 0xFFFF; smaj++)
- for (smin = 0; smin <= 0xFFFF; smin++)
- for (cmin = 0; cmin <= 0xFFFF; cmin++)
- for (cmaj = 0; cmaj <= 0xFFFF; cmaj++)
- {
- int error = (cmaj < 2) ? BadValue : Success;
- request_XIQueryVersion(smaj, smin, cmaj, cmin, error);
- }
-
-#endif
-
- reply_handler = NULL;
-}
-
-int main(int argc, char** argv)
-{
- g_test_init(&argc, &argv,NULL);
- g_test_bug_base("https://bugzilla.freedesktop.org/show_bug.cgi?id=");
-
- init_simple();
-
- g_test_add_func("/xi2/protocol/XIQueryVersion", test_XIQueryVersion);
-
- return g_test_run();
-}
+/**
+ * Copyright © 2009 Red Hat, Inc.
+ *
+ * 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, sublicense,
+ * 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 NONINFRINGEMENT. IN NO EVENT SHALL
+ * THE AUTHORS OR COPYRIGHT HOLDERS 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.
+ */
+
+#ifdef HAVE_DIX_CONFIG_H
+#include <dix-config.h>
+#endif
+
+/*
+ * Protocol testing for XIQueryVersion request and reply.
+ *
+ * Test approach:
+ * Wrap WriteToClient to intercept the server's reply.
+ * Repeatedly test a client/server version combination, compare version in
+ * reply with versions given. Version must be equal to either
+ * server version or client version, whichever is smaller.
+ * Client version less than 2 must return BadValue.
+ */
+
+#include <stdint.h>
+#include <X11/X.h>
+#include <X11/Xproto.h>
+#include <X11/extensions/XI2proto.h>
+#include "inputstr.h"
+#include "extinit.h" /* for XInputExtensionInit */
+#include "scrnintstr.h"
+#include "xiqueryversion.h"
+
+#include "protocol-common.h"
+
+extern XExtensionVersion XIVersion;
+
+struct test_data {
+ int major_client;
+ int minor_client;
+ int major_server;
+ int minor_server;
+};
+
+static void reply_XIQueryVersion(ClientPtr client, int len, char* data, void *userdata)
+{
+ xXIQueryVersionReply *rep = (xXIQueryVersionReply*)data;
+ struct test_data *versions = (struct test_data*)userdata;
+ unsigned int sver, cver, ver;
+
+ if (client->swapped)
+ {
+ char n;
+ swapl(&rep->length, n);
+ swaps(&rep->sequenceNumber, n);
+ swaps(&rep->major_version, n);
+ swaps(&rep->minor_version, n);
+ }
+
+ reply_check_defaults(rep, len, XIQueryVersion);
+
+ assert(rep->length == 0);
+
+ sver = versions->major_server * 1000 + versions->minor_server;
+ cver = versions->major_client * 1000 + versions->minor_client;
+ ver = rep->major_version * 1000 + rep->minor_version;
+
+ assert(ver >= 2000);
+ assert((sver > cver) ? ver == cver : ver == sver);
+}
+
+/**
+ * Run a single test with server version smaj.smin and client
+ * version cmaj.cmin. Verify that return code is equal to 'error'.
+ *
+ * Test is run normal, then for a swapped client.
+ */
+static void request_XIQueryVersion(int smaj, int smin, int cmaj, int cmin, int error)
+{
+ char n;
+ int rc;
+ struct test_data versions;
+ xXIQueryVersionReq request;
+ ClientRec client;
+
+ request_init(&request, XIQueryVersion);
+ client = init_client(request.length, &request);
+ userdata = (void*)&versions;
+
+ /* Change the server to support smaj.smin */
+ XIVersion.major_version = smaj;
+ XIVersion.minor_version = smin;
+
+ /* remember versions we send and expect */
+ versions.major_client = cmaj;
+ versions.minor_client = cmin;
+ versions.major_server = XIVersion.major_version;
+ versions.minor_server = XIVersion.minor_version;
+
+ request.major_version = versions.major_client;
+ request.minor_version = versions.minor_client;
+ rc = ProcXIQueryVersion(&client);
+ assert(rc == error);
+
+ client.swapped = TRUE;
+
+ swaps(&request.length, n);
+ swaps(&request.major_version, n);
+ swaps(&request.minor_version, n);
+
+ rc = SProcXIQueryVersion(&client);
+ assert(rc == error);
+}
+
+/* Client version less than 2.0 must return BadValue, all other combinations
+ * Success */
+static void test_XIQueryVersion(void)
+{
+ reply_handler = reply_XIQueryVersion;
+
+ printf("Server version 2.0 - client versions [1..3].0\n");
+ /* some simple tests to catch common errors quickly */
+ request_XIQueryVersion(2, 0, 1, 0, BadValue);
+ request_XIQueryVersion(2, 0, 2, 0, Success);
+ request_XIQueryVersion(2, 0, 3, 0, Success);
+
+ printf("Server version 3.0 - client versions [1..3].0\n");
+ request_XIQueryVersion(3, 0, 1, 0, BadValue);
+ request_XIQueryVersion(3, 0, 2, 0, Success);
+ request_XIQueryVersion(3, 0, 3, 0, Success);
+
+ printf("Server version 2.0 - client versions [1..3].[1..3]\n");
+ request_XIQueryVersion(2, 0, 1, 1, BadValue);
+ request_XIQueryVersion(2, 0, 2, 2, Success);
+ request_XIQueryVersion(2, 0, 3, 3, Success);
+
+ printf("Server version 2.2 - client versions [1..3].0\n");
+ request_XIQueryVersion(2, 2, 1, 0, BadValue);
+ request_XIQueryVersion(2, 2, 2, 0, Success);
+ request_XIQueryVersion(2, 2, 3, 0, Success);
+
+#if 0
+ /* this one takes a while */
+ unsigned int cmin, cmaj, smin, smaj;
+
+ printf("Testing all combinations.\n");
+ for (smaj = 2; smaj <= 0xFFFF; smaj++)
+ for (smin = 0; smin <= 0xFFFF; smin++)
+ for (cmin = 0; cmin <= 0xFFFF; cmin++)
+ for (cmaj = 0; cmaj <= 0xFFFF; cmaj++)
+ {
+ int error = (cmaj < 2) ? BadValue : Success;
+ request_XIQueryVersion(smaj, smin, cmaj, cmin, error);
+ }
+
+#endif
+
+ reply_handler = NULL;
+}
+
+int main(int argc, char** argv)
+{
+ init_simple();
+
+ test_XIQueryVersion();
+
+ return 0;
+}
diff --git a/xorg-server/test/xi2/protocol-xiselectevents.c b/xorg-server/test/xi2/protocol-xiselectevents.c
index f951a14fe..fc780b358 100644
--- a/xorg-server/test/xi2/protocol-xiselectevents.c
+++ b/xorg-server/test/xi2/protocol-xiselectevents.c
@@ -1,338 +1,334 @@
-/**
- * Copyright © 2009 Red Hat, Inc.
- *
- * 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, sublicense,
- * 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 NONINFRINGEMENT. IN NO EVENT SHALL
- * THE AUTHORS OR COPYRIGHT HOLDERS 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.
- */
-
-#ifdef HAVE_DIX_CONFIG_H
-#include <dix-config.h>
-#endif
-
-/*
- * Protocol testing for XISelectEvents request.
- *
- * Test approach:
- *
- * Wrap XISetEventMask to intercept when the server tries to apply the event
- * mask. Ensure that the mask passed in is equivalent to the one supplied by
- * the client. Ensure that invalid devices and invalid masks return errors
- * as appropriate.
- *
- * Tests included:
- * BadValue for num_masks < 0
- * BadWindow for invalid windows
- * BadDevice for non-existing devices
- * BadImplemenation for devices >= 0xFF
- * BadValue if HierarchyChanged bit is set for devices other than
- * XIAllDevices
- * BadValue for invalid mask bits
- * Sucecss for excessive mask lengths
- *
- */
-
-#include <stdint.h>
-#include <X11/X.h>
-#include <X11/Xproto.h>
-#include <X11/extensions/XI2proto.h>
-#include "inputstr.h"
-#include "windowstr.h"
-#include "extinit.h" /* for XInputExtensionInit */
-#include "scrnintstr.h"
-#include "xiselectev.h"
-
-#include "protocol-common.h"
-#include <glib.h>
-
-static unsigned char *data[4096 * 20]; /* the request data buffer */
-
-int __wrap_XISetEventMask(DeviceIntPtr dev, WindowPtr win, int len, unsigned char* mask)
-{
- return Success;
-}
-
-/* dixLookupWindow requires a lot of setup not necessary for this test.
- * Simple wrapper that returns either one of the fake root window or the
- * fake client window. If the requested ID is neither of those wanted,
- * return whatever the real dixLookupWindow does.
- */
-int __wrap_dixLookupWindow(WindowPtr *win, XID id, ClientPtr client, Mask access)
-{
- if (id == root.drawable.id)
- {
- *win = &root;
- return Success;
- } else if (id == window.drawable.id)
- {
- *win = &window;
- return Success;
- }
-
- return __real_dixLookupWindow(win, id, client, access);
-}
-
-
-static void request_XISelectEvent(xXISelectEventsReq *req, int error)
-{
- char n;
- int i;
- int rc;
- ClientRec client;
- xXIEventMask *mask, *next;
-
- req->length = (sz_xXISelectEventsReq/4);
- mask = (xXIEventMask*)&req[1];
- for (i = 0; i < req->num_masks; i++)
- {
- req->length += sizeof(xXIEventMask)/4 + mask->mask_len;
- mask = (xXIEventMask*)((char*)&mask[1] + mask->mask_len * 4);
- }
-
- client = init_client(req->length, req);
-
- rc = ProcXISelectEvents(&client);
- g_assert(rc == error);
-
- client.swapped = TRUE;
-
- mask = (xXIEventMask*)&req[1];
- for (i = 0; i < req->num_masks; i++)
- {
- next = (xXIEventMask*)((char*)&mask[1] + mask->mask_len * 4);
- swaps(&mask->deviceid, n);
- swaps(&mask->mask_len, n);
- mask = next;
- }
-
- swapl(&req->win, n);
- swaps(&req->length, n);
- swaps(&req->num_masks, n);
- rc = SProcXISelectEvents(&client);
- g_assert(rc == error);
-}
-
-static void request_XISelectEvents_masks(xXISelectEventsReq *req)
-{
- int i, j;
- xXIEventMask *mask;
- int nmasks = (XI2LASTEVENT + 7)/8;
- unsigned char *bits;
-
- mask = (xXIEventMask*)&req[1];
- req->win = ROOT_WINDOW_ID;
-
- /* if a clients submits more than 100 masks, consider it insane and untested */
- for (i = 1; i <= 1000; i++)
- {
- req->num_masks = i;
- mask->deviceid = XIAllDevices;
-
- /* Test 0:
- * mask_len is 0 -> Success
- */
- mask->mask_len = 0;
- request_XISelectEvent(req, Success);
-
- /* Test 1:
- * mask may be larger than needed for XI2LASTEVENT.
- * Test setting each valid mask bit, while leaving unneeded bits 0.
- * -> Success
- */
- bits = (unsigned char*)&mask[1];
- mask->mask_len = (nmasks + 3)/4 * 10;
- memset(bits, 0, mask->mask_len * 4);
- for (j = 0; j <= XI2LASTEVENT; j++)
- {
- SetBit(bits, j);
- request_XISelectEvent(req, Success);
- ClearBit(bits, j);
- }
-
- /* Test 2:
- * mask may be larger than needed for XI2LASTEVENT.
- * Test setting all valid mask bits, while leaving unneeded bits 0.
- * -> Success
- */
- bits = (unsigned char*)&mask[1];
- mask->mask_len = (nmasks + 3)/4 * 10;
- memset(bits, 0, mask->mask_len * 4);
-
- for (j = 0; j <= XI2LASTEVENT; j++)
- {
- SetBit(bits, j);
- request_XISelectEvent(req, Success);
- }
-
- /* Test 3:
- * mask is larger than needed for XI2LASTEVENT. If any unneeded bit
- * is set -> BadValue
- */
- bits = (unsigned char*)&mask[1];
- mask->mask_len = (nmasks + 3)/4 * 10;
- memset(bits, 0, mask->mask_len * 4);
-
- for (j = XI2LASTEVENT + 1; j < mask->mask_len * 4; j++)
- {
- SetBit(bits, j);
- request_XISelectEvent(req, BadValue);
- ClearBit(bits, j);
- }
-
- /* Test 4:
- * Mask len is a sensible length, only valid bits are set -> Success
- */
- bits = (unsigned char*)&mask[1];
- mask->mask_len = (nmasks + 3)/4;
- memset(bits, 0, mask->mask_len * 4);
- for (j = 0; j <= XI2LASTEVENT; j++)
- {
- SetBit(bits, j);
- request_XISelectEvent(req, Success);
- }
-
- /* Test 5:
- * HierarchyChanged bit is BadValue for devices other than
- * XIAllDevices
- */
- bits = (unsigned char*)&mask[1];
- mask->mask_len = (nmasks + 3)/4;
- memset(bits, 0, mask->mask_len * 4);
- SetBit(bits, XI_HierarchyChanged);
- mask->deviceid = XIAllDevices;
- request_XISelectEvent(req, Success);
- for (j = 1; j < devices.num_devices; j++)
- {
- mask->deviceid = j;
- request_XISelectEvent(req, BadValue);
- }
-
- /* Test 6:
- * All bits set minus hierarchy changed bit -> Success
- */
- bits = (unsigned char*)&mask[1];
- mask->mask_len = (nmasks + 3)/4;
- memset(bits, 0, mask->mask_len * 4);
- for (j = 0; j <= XI2LASTEVENT; j++)
- SetBit(bits, j);
- ClearBit(bits, XI_HierarchyChanged);
- for (j = 1; j < 6; j++)
- {
- mask->deviceid = j;
- request_XISelectEvent(req, Success);
- }
-
- mask = (xXIEventMask*)((char*)mask + sizeof(xXIEventMask) + mask->mask_len * 4);
- }
-}
-
-static void test_XISelectEvents(void)
-{
- int i;
- xXIEventMask *mask;
- xXISelectEventsReq *req;
- req = (xXISelectEventsReq*)data;
-
- request_init(req, XISelectEvents);
-
- g_test_message("Testing for BadValue on zero-length masks");
- /* zero masks are BadValue, regardless of the window */
- req->num_masks = 0;
-
- req->win = None;
- request_XISelectEvent(req, BadValue);
-
- req->win = ROOT_WINDOW_ID;
- request_XISelectEvent(req, BadValue);
-
- req->win = CLIENT_WINDOW_ID;
- request_XISelectEvent(req, BadValue);
-
- g_test_message("Testing for BadWindow.");
- /* None window is BadWindow, regardless of the masks.
- * We don't actually need to set the masks here, BadWindow must occur
- * before checking the masks.
- */
- req->win = None;
- req->num_masks = 1;
- request_XISelectEvent(req, BadWindow);
-
- req->num_masks = 2;
- request_XISelectEvent(req, BadWindow);
-
- req->num_masks = 0xFF;
- request_XISelectEvent(req, BadWindow);
-
- /* request size is 3, so 0xFFFC is the highest num_mask that doesn't
- * overflow req->length */
- req->num_masks = 0xFFFC;
- request_XISelectEvent(req, BadWindow);
-
- g_test_message("Triggering num_masks/length overflow");
- req->win = ROOT_WINDOW_ID;
- /* Integer overflow - req->length can't hold that much */
- req->num_masks = 0xFFFF;
- request_XISelectEvent(req, BadLength);
-
- req->win = ROOT_WINDOW_ID;
- req->num_masks = 1;
-
- g_test_message("Triggering bogus mask length error");
- mask = (xXIEventMask*)&req[1];
- mask->deviceid = 0;
- mask->mask_len = 0xFFFF;
- request_XISelectEvent(req, BadLength);
-
- /* testing various device ids */
- g_test_message("Testing existing device ids.");
- for (i = 0; i < 6; i++)
- {
- mask = (xXIEventMask*)&req[1];
- mask->deviceid = i;
- mask->mask_len = 1;
- req->win = ROOT_WINDOW_ID;
- req->num_masks = 1;
- request_XISelectEvent(req, Success);
- }
-
- g_test_message("Testing non-existing device ids.");
- for (i = 6; i <= 0xFFFF; i++)
- {
- req->win = ROOT_WINDOW_ID;
- req->num_masks = 1;
- mask = (xXIEventMask*)&req[1];
- mask->deviceid = i;
- mask->mask_len = 1;
- request_XISelectEvent(req, BadDevice);
- }
-
- request_XISelectEvents_masks(req);
-}
-
-int main(int argc, char** argv)
-{
- g_test_init(&argc, &argv,NULL);
- g_test_bug_base("https://bugzilla.freedesktop.org/show_bug.cgi?id=");
-
- init_simple();
-
- g_test_add_func("/xi2/protocol/XISelectEvents", test_XISelectEvents);
-
- return g_test_run();
-}
-
+/**
+ * Copyright © 2009 Red Hat, Inc.
+ *
+ * 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, sublicense,
+ * 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 NONINFRINGEMENT. IN NO EVENT SHALL
+ * THE AUTHORS OR COPYRIGHT HOLDERS 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.
+ */
+
+#ifdef HAVE_DIX_CONFIG_H
+#include <dix-config.h>
+#endif
+
+/*
+ * Protocol testing for XISelectEvents request.
+ *
+ * Test approach:
+ *
+ * Wrap XISetEventMask to intercept when the server tries to apply the event
+ * mask. Ensure that the mask passed in is equivalent to the one supplied by
+ * the client. Ensure that invalid devices and invalid masks return errors
+ * as appropriate.
+ *
+ * Tests included:
+ * BadValue for num_masks < 0
+ * BadWindow for invalid windows
+ * BadDevice for non-existing devices
+ * BadImplemenation for devices >= 0xFF
+ * BadValue if HierarchyChanged bit is set for devices other than
+ * XIAllDevices
+ * BadValue for invalid mask bits
+ * Sucecss for excessive mask lengths
+ *
+ */
+
+#include <stdint.h>
+#include <X11/X.h>
+#include <X11/Xproto.h>
+#include <X11/extensions/XI2proto.h>
+#include "inputstr.h"
+#include "windowstr.h"
+#include "extinit.h" /* for XInputExtensionInit */
+#include "scrnintstr.h"
+#include "xiselectev.h"
+
+#include "protocol-common.h"
+
+static unsigned char *data[4096 * 20]; /* the request data buffer */
+
+int __wrap_XISetEventMask(DeviceIntPtr dev, WindowPtr win, int len, unsigned char* mask)
+{
+ return Success;
+}
+
+/* dixLookupWindow requires a lot of setup not necessary for this test.
+ * Simple wrapper that returns either one of the fake root window or the
+ * fake client window. If the requested ID is neither of those wanted,
+ * return whatever the real dixLookupWindow does.
+ */
+int __wrap_dixLookupWindow(WindowPtr *win, XID id, ClientPtr client, Mask access)
+{
+ if (id == root.drawable.id)
+ {
+ *win = &root;
+ return Success;
+ } else if (id == window.drawable.id)
+ {
+ *win = &window;
+ return Success;
+ }
+
+ return __real_dixLookupWindow(win, id, client, access);
+}
+
+
+static void request_XISelectEvent(xXISelectEventsReq *req, int error)
+{
+ char n;
+ int i;
+ int rc;
+ ClientRec client;
+ xXIEventMask *mask, *next;
+
+ req->length = (sz_xXISelectEventsReq/4);
+ mask = (xXIEventMask*)&req[1];
+ for (i = 0; i < req->num_masks; i++)
+ {
+ req->length += sizeof(xXIEventMask)/4 + mask->mask_len;
+ mask = (xXIEventMask*)((char*)&mask[1] + mask->mask_len * 4);
+ }
+
+ client = init_client(req->length, req);
+
+ rc = ProcXISelectEvents(&client);
+ assert(rc == error);
+
+ client.swapped = TRUE;
+
+ mask = (xXIEventMask*)&req[1];
+ for (i = 0; i < req->num_masks; i++)
+ {
+ next = (xXIEventMask*)((char*)&mask[1] + mask->mask_len * 4);
+ swaps(&mask->deviceid, n);
+ swaps(&mask->mask_len, n);
+ mask = next;
+ }
+
+ swapl(&req->win, n);
+ swaps(&req->length, n);
+ swaps(&req->num_masks, n);
+ rc = SProcXISelectEvents(&client);
+ assert(rc == error);
+}
+
+static void request_XISelectEvents_masks(xXISelectEventsReq *req)
+{
+ int i, j;
+ xXIEventMask *mask;
+ int nmasks = (XI2LASTEVENT + 7)/8;
+ unsigned char *bits;
+
+ mask = (xXIEventMask*)&req[1];
+ req->win = ROOT_WINDOW_ID;
+
+ /* if a clients submits more than 100 masks, consider it insane and untested */
+ for (i = 1; i <= 1000; i++)
+ {
+ req->num_masks = i;
+ mask->deviceid = XIAllDevices;
+
+ /* Test 0:
+ * mask_len is 0 -> Success
+ */
+ mask->mask_len = 0;
+ request_XISelectEvent(req, Success);
+
+ /* Test 1:
+ * mask may be larger than needed for XI2LASTEVENT.
+ * Test setting each valid mask bit, while leaving unneeded bits 0.
+ * -> Success
+ */
+ bits = (unsigned char*)&mask[1];
+ mask->mask_len = (nmasks + 3)/4 * 10;
+ memset(bits, 0, mask->mask_len * 4);
+ for (j = 0; j <= XI2LASTEVENT; j++)
+ {
+ SetBit(bits, j);
+ request_XISelectEvent(req, Success);
+ ClearBit(bits, j);
+ }
+
+ /* Test 2:
+ * mask may be larger than needed for XI2LASTEVENT.
+ * Test setting all valid mask bits, while leaving unneeded bits 0.
+ * -> Success
+ */
+ bits = (unsigned char*)&mask[1];
+ mask->mask_len = (nmasks + 3)/4 * 10;
+ memset(bits, 0, mask->mask_len * 4);
+
+ for (j = 0; j <= XI2LASTEVENT; j++)
+ {
+ SetBit(bits, j);
+ request_XISelectEvent(req, Success);
+ }
+
+ /* Test 3:
+ * mask is larger than needed for XI2LASTEVENT. If any unneeded bit
+ * is set -> BadValue
+ */
+ bits = (unsigned char*)&mask[1];
+ mask->mask_len = (nmasks + 3)/4 * 10;
+ memset(bits, 0, mask->mask_len * 4);
+
+ for (j = XI2LASTEVENT + 1; j < mask->mask_len * 4; j++)
+ {
+ SetBit(bits, j);
+ request_XISelectEvent(req, BadValue);
+ ClearBit(bits, j);
+ }
+
+ /* Test 4:
+ * Mask len is a sensible length, only valid bits are set -> Success
+ */
+ bits = (unsigned char*)&mask[1];
+ mask->mask_len = (nmasks + 3)/4;
+ memset(bits, 0, mask->mask_len * 4);
+ for (j = 0; j <= XI2LASTEVENT; j++)
+ {
+ SetBit(bits, j);
+ request_XISelectEvent(req, Success);
+ }
+
+ /* Test 5:
+ * HierarchyChanged bit is BadValue for devices other than
+ * XIAllDevices
+ */
+ bits = (unsigned char*)&mask[1];
+ mask->mask_len = (nmasks + 3)/4;
+ memset(bits, 0, mask->mask_len * 4);
+ SetBit(bits, XI_HierarchyChanged);
+ mask->deviceid = XIAllDevices;
+ request_XISelectEvent(req, Success);
+ for (j = 1; j < devices.num_devices; j++)
+ {
+ mask->deviceid = j;
+ request_XISelectEvent(req, BadValue);
+ }
+
+ /* Test 6:
+ * All bits set minus hierarchy changed bit -> Success
+ */
+ bits = (unsigned char*)&mask[1];
+ mask->mask_len = (nmasks + 3)/4;
+ memset(bits, 0, mask->mask_len * 4);
+ for (j = 0; j <= XI2LASTEVENT; j++)
+ SetBit(bits, j);
+ ClearBit(bits, XI_HierarchyChanged);
+ for (j = 1; j < 6; j++)
+ {
+ mask->deviceid = j;
+ request_XISelectEvent(req, Success);
+ }
+
+ mask = (xXIEventMask*)((char*)mask + sizeof(xXIEventMask) + mask->mask_len * 4);
+ }
+}
+
+static void test_XISelectEvents(void)
+{
+ int i;
+ xXIEventMask *mask;
+ xXISelectEventsReq *req;
+ req = (xXISelectEventsReq*)data;
+
+ request_init(req, XISelectEvents);
+
+ printf("Testing for BadValue on zero-length masks\n");
+ /* zero masks are BadValue, regardless of the window */
+ req->num_masks = 0;
+
+ req->win = None;
+ request_XISelectEvent(req, BadValue);
+
+ req->win = ROOT_WINDOW_ID;
+ request_XISelectEvent(req, BadValue);
+
+ req->win = CLIENT_WINDOW_ID;
+ request_XISelectEvent(req, BadValue);
+
+ printf("Testing for BadWindow.\n");
+ /* None window is BadWindow, regardless of the masks.
+ * We don't actually need to set the masks here, BadWindow must occur
+ * before checking the masks.
+ */
+ req->win = None;
+ req->num_masks = 1;
+ request_XISelectEvent(req, BadWindow);
+
+ req->num_masks = 2;
+ request_XISelectEvent(req, BadWindow);
+
+ req->num_masks = 0xFF;
+ request_XISelectEvent(req, BadWindow);
+
+ /* request size is 3, so 0xFFFC is the highest num_mask that doesn't
+ * overflow req->length */
+ req->num_masks = 0xFFFC;
+ request_XISelectEvent(req, BadWindow);
+
+ printf("Triggering num_masks/length overflow\n");
+ req->win = ROOT_WINDOW_ID;
+ /* Integer overflow - req->length can't hold that much */
+ req->num_masks = 0xFFFF;
+ request_XISelectEvent(req, BadLength);
+
+ req->win = ROOT_WINDOW_ID;
+ req->num_masks = 1;
+
+ printf("Triggering bogus mask length error\n");
+ mask = (xXIEventMask*)&req[1];
+ mask->deviceid = 0;
+ mask->mask_len = 0xFFFF;
+ request_XISelectEvent(req, BadLength);
+
+ /* testing various device ids */
+ printf("Testing existing device ids.\n");
+ for (i = 0; i < 6; i++)
+ {
+ mask = (xXIEventMask*)&req[1];
+ mask->deviceid = i;
+ mask->mask_len = 1;
+ req->win = ROOT_WINDOW_ID;
+ req->num_masks = 1;
+ request_XISelectEvent(req, Success);
+ }
+
+ printf("Testing non-existing device ids.\n");
+ for (i = 6; i <= 0xFFFF; i++)
+ {
+ req->win = ROOT_WINDOW_ID;
+ req->num_masks = 1;
+ mask = (xXIEventMask*)&req[1];
+ mask->deviceid = i;
+ mask->mask_len = 1;
+ request_XISelectEvent(req, BadDevice);
+ }
+
+ request_XISelectEvents_masks(req);
+}
+
+int main(int argc, char** argv)
+{
+ init_simple();
+
+ test_XISelectEvents();
+
+ return 0;
+}
+
diff --git a/xorg-server/test/xi2/protocol-xisetclientpointer.c b/xorg-server/test/xi2/protocol-xisetclientpointer.c
index 2e638eea7..fa3c87f62 100644
--- a/xorg-server/test/xi2/protocol-xisetclientpointer.c
+++ b/xorg-server/test/xi2/protocol-xisetclientpointer.c
@@ -1,149 +1,145 @@
-/**
- * Copyright © 2009 Red Hat, Inc.
- *
- * 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, sublicense,
- * 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 NONINFRINGEMENT. IN NO EVENT SHALL
- * THE AUTHORS OR COPYRIGHT HOLDERS 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.
- */
-
-#ifdef HAVE_DIX_CONFIG_H
-#include <dix-config.h>
-#endif
-
-/*
- * Protocol testing for XISetClientPointer request.
- *
- * Tests include:
- * BadDevice of all devices except master pointers.
- * Success for a valid window.
- * Success for window None.
- * BadWindow for invalid windows.
- */
-#include <stdint.h>
-#include <X11/X.h>
-#include <X11/Xproto.h>
-#include <X11/extensions/XI2proto.h>
-#include "inputstr.h"
-#include "windowstr.h"
-#include "extinit.h" /* for XInputExtensionInit */
-#include "scrnintstr.h"
-#include "xisetclientpointer.h"
-#include "exevents.h"
-
-#include "protocol-common.h"
-#include <glib.h>
-
-static ClientRec client_window;
-static ClientRec client_request;
-
-int __wrap_dixLookupClient(ClientPtr *pClient, XID rid, ClientPtr client, Mask access)
-{
- if (rid == ROOT_WINDOW_ID)
- return BadWindow;
-
- if (rid == CLIENT_WINDOW_ID)
- {
- *pClient = &client_window;
- return Success;
- }
-
- return __real_dixLookupClient(pClient, rid, client, access);
-}
-
-static void request_XISetClientPointer(xXISetClientPointerReq* req, int error)
-{
- char n;
- int rc;
- client_request = init_client(req->length, req);
-
- rc = ProcXISetClientPointer(&client_request);
- g_assert(rc == error);
-
- if (rc == BadDevice)
- g_assert(client_request.errorValue == req->deviceid);
-
- client_request.swapped = TRUE;
- swapl(&req->win, n);
- swaps(&req->length, n);
- swaps(&req->deviceid, n);
- rc = SProcXISetClientPointer(&client_request);
- g_assert(rc == error);
-
- if (rc == BadDevice)
- g_assert(client_request.errorValue == req->deviceid);
-
-}
-
-static void test_XISetClientPointer(void)
-{
- int i;
- xXISetClientPointerReq request;
-
- request_init(&request, XISetClientPointer);
-
- request.win = CLIENT_WINDOW_ID;
-
- g_test_message("Testing BadDevice error for XIAllDevices and XIMasterDevices.");
- request.deviceid = XIAllDevices;
- request_XISetClientPointer(&request, BadDevice);
-
- request.deviceid = XIAllMasterDevices;
- request_XISetClientPointer(&request, BadDevice);
-
- g_test_message("Testing Success for VCP and VCK.");
- request.deviceid = devices.vcp->id; /* 2 */
- request_XISetClientPointer(&request, Success);
- g_assert(client_window.clientPtr->id == 2);
-
- request.deviceid = devices.vck->id; /* 3 */
- request_XISetClientPointer(&request, Success);
- g_assert(client_window.clientPtr->id == 2);
-
- g_test_message("Testing BadDevice error for all other devices.");
- for (i = 4; i <= 0xFFFF; i++)
- {
- request.deviceid = i;
- request_XISetClientPointer(&request, BadDevice);
- }
-
- g_test_message("Testing window None");
- request.win = None;
- request.deviceid = devices.vcp->id; /* 2 */
- request_XISetClientPointer(&request, Success);
- g_assert(client_request.clientPtr->id == 2);
-
- g_test_message("Testing invalid window");
- request.win = INVALID_WINDOW_ID;
- request.deviceid = devices.vcp->id;
- request_XISetClientPointer(&request, BadWindow);
-
-}
-
-
-int main(int argc, char** argv)
-{
- g_test_init(&argc, &argv,NULL);
- g_test_bug_base("https://bugzilla.freedesktop.org/show_bug.cgi?id=");
-
- init_simple();
- client_window = init_client(0, NULL);
-
- g_test_add_func("/xi2/protocol/XISetClientPointer", test_XISetClientPointer);
-
- return g_test_run();
-}
+/**
+ * Copyright © 2009 Red Hat, Inc.
+ *
+ * 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, sublicense,
+ * 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 NONINFRINGEMENT. IN NO EVENT SHALL
+ * THE AUTHORS OR COPYRIGHT HOLDERS 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.
+ */
+
+#ifdef HAVE_DIX_CONFIG_H
+#include <dix-config.h>
+#endif
+
+/*
+ * Protocol testing for XISetClientPointer request.
+ *
+ * Tests include:
+ * BadDevice of all devices except master pointers.
+ * Success for a valid window.
+ * Success for window None.
+ * BadWindow for invalid windows.
+ */
+#include <stdint.h>
+#include <X11/X.h>
+#include <X11/Xproto.h>
+#include <X11/extensions/XI2proto.h>
+#include "inputstr.h"
+#include "windowstr.h"
+#include "extinit.h" /* for XInputExtensionInit */
+#include "scrnintstr.h"
+#include "xisetclientpointer.h"
+#include "exevents.h"
+
+#include "protocol-common.h"
+
+static ClientRec client_window;
+static ClientRec client_request;
+
+int __wrap_dixLookupClient(ClientPtr *pClient, XID rid, ClientPtr client, Mask access)
+{
+ if (rid == ROOT_WINDOW_ID)
+ return BadWindow;
+
+ if (rid == CLIENT_WINDOW_ID)
+ {
+ *pClient = &client_window;
+ return Success;
+ }
+
+ return __real_dixLookupClient(pClient, rid, client, access);
+}
+
+static void request_XISetClientPointer(xXISetClientPointerReq* req, int error)
+{
+ char n;
+ int rc;
+ client_request = init_client(req->length, req);
+
+ rc = ProcXISetClientPointer(&client_request);
+ assert(rc == error);
+
+ if (rc == BadDevice)
+ assert(client_request.errorValue == req->deviceid);
+
+ client_request.swapped = TRUE;
+ swapl(&req->win, n);
+ swaps(&req->length, n);
+ swaps(&req->deviceid, n);
+ rc = SProcXISetClientPointer(&client_request);
+ assert(rc == error);
+
+ if (rc == BadDevice)
+ assert(client_request.errorValue == req->deviceid);
+
+}
+
+static void test_XISetClientPointer(void)
+{
+ int i;
+ xXISetClientPointerReq request;
+
+ request_init(&request, XISetClientPointer);
+
+ request.win = CLIENT_WINDOW_ID;
+
+ printf("Testing BadDevice error for XIAllDevices and XIMasterDevices.\n");
+ request.deviceid = XIAllDevices;
+ request_XISetClientPointer(&request, BadDevice);
+
+ request.deviceid = XIAllMasterDevices;
+ request_XISetClientPointer(&request, BadDevice);
+
+ printf("Testing Success for VCP and VCK.\n");
+ request.deviceid = devices.vcp->id; /* 2 */
+ request_XISetClientPointer(&request, Success);
+ assert(client_window.clientPtr->id == 2);
+
+ request.deviceid = devices.vck->id; /* 3 */
+ request_XISetClientPointer(&request, Success);
+ assert(client_window.clientPtr->id == 2);
+
+ printf("Testing BadDevice error for all other devices.\n");
+ for (i = 4; i <= 0xFFFF; i++)
+ {
+ request.deviceid = i;
+ request_XISetClientPointer(&request, BadDevice);
+ }
+
+ printf("Testing window None\n");
+ request.win = None;
+ request.deviceid = devices.vcp->id; /* 2 */
+ request_XISetClientPointer(&request, Success);
+ assert(client_request.clientPtr->id == 2);
+
+ printf("Testing invalid window\n");
+ request.win = INVALID_WINDOW_ID;
+ request.deviceid = devices.vcp->id;
+ request_XISetClientPointer(&request, BadWindow);
+
+}
+
+
+int main(int argc, char** argv)
+{
+ init_simple();
+ client_window = init_client(0, NULL);
+
+ test_XISetClientPointer();
+
+ return 0;
+}
diff --git a/xorg-server/test/xi2/protocol-xiwarppointer.c b/xorg-server/test/xi2/protocol-xiwarppointer.c
index 98169b154..7faf593c6 100644
--- a/xorg-server/test/xi2/protocol-xiwarppointer.c
+++ b/xorg-server/test/xi2/protocol-xiwarppointer.c
@@ -39,7 +39,6 @@
#include "exevents.h"
#include "protocol-common.h"
-#include <glib.h>
static int expected_x = SPRITE_X;
static int expected_y = SPRITE_Y;
@@ -70,8 +69,8 @@ int __wrap_dixLookupWindow(WindowPtr *win, XID id, ClientPtr client, Mask access
static Bool ScreenSetCursorPosition(DeviceIntPtr dev, ScreenPtr screen,
int x, int y, Bool generateEvent)
{
- g_assert(x == expected_x);
- g_assert(y == expected_y);
+ assert(x == expected_x);
+ assert(y == expected_y);
return TRUE;
}
@@ -83,12 +82,12 @@ static void request_XIWarpPointer(ClientPtr client, xXIWarpPointerReq* req,
int rc;
rc = ProcXIWarpPointer(client);
- g_assert(rc == error);
+ assert(rc == error);
if (rc == BadDevice)
- g_assert(client->errorValue == req->deviceid);
+ assert(client->errorValue == req->deviceid);
else if (rc == BadWindow)
- g_assert(client->errorValue == req->dst_win ||
+ assert(client->errorValue == req->dst_win ||
client->errorValue == req->src_win);
@@ -105,12 +104,12 @@ static void request_XIWarpPointer(ClientPtr client, xXIWarpPointerReq* req,
swaps(&req->deviceid, n);
rc = SProcXIWarpPointer(client);
- g_assert(rc == error);
+ assert(rc == error);
if (rc == BadDevice)
- g_assert(client->errorValue == req->deviceid);
+ assert(client->errorValue == req->deviceid);
else if (rc == BadWindow)
- g_assert(client->errorValue == req->dst_win ||
+ assert(client->errorValue == req->dst_win ||
client->errorValue == req->src_win);
client->swapped = FALSE;
@@ -204,13 +203,10 @@ static void test_XIWarpPointer(void)
int main(int argc, char** argv)
{
- g_test_init(&argc, &argv,NULL);
- g_test_bug_base("https://bugzilla.freedesktop.org/show_bug.cgi?id=");
-
init_simple();
screen.SetCursorPosition = ScreenSetCursorPosition;
- g_test_add_func("/xi2/protocol/XIWarpPointer", test_XIWarpPointer);
+ test_XIWarpPointer();
- return g_test_run();
+ return 0;
}
diff --git a/xorg-server/test/xkb.c b/xorg-server/test/xkb.c
index 6fbb26a01..775390eb9 100644
--- a/xorg-server/test/xkb.c
+++ b/xorg-server/test/xkb.c
@@ -1,173 +1,169 @@
-/**
- * Copyright © 2009 Red Hat, Inc.
- *
- * 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, sublicense,
- * 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 NONINFRINGEMENT. IN NO EVENT SHALL
- * THE AUTHORS OR COPYRIGHT HOLDERS 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.
- */
-
-#ifdef HAVE_DIX_CONFIG_H
-#include <dix-config.h>
-#endif
-
-#include <xkb-config.h>
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <ctype.h>
-#include <unistd.h>
-#include <math.h>
-#include <X11/X.h>
-#include <X11/Xproto.h>
-#include <X11/keysym.h>
-#include <X11/Xatom.h>
-#include "misc.h"
-#include "inputstr.h"
-#include "opaque.h"
-#include "property.h"
-#define XKBSRV_NEED_FILE_FUNCS
-#include <xkbsrv.h>
-#include "../xkb/xkbgeom.h"
-#include <X11/extensions/XKMformat.h>
-#include "xkbfile.h"
-#include "../xkb/xkb.h"
-
-#include <glib.h>
-
-/**
- * Initialize an empty XkbRMLVOSet.
- * Call XkbGetRulesDflts to obtain the default ruleset.
- * Compare obtained ruleset with the built-in defaults.
- *
- * Result: RMLVO defaults are the same as obtained.
- */
-static void xkb_get_rules_test(void)
-{
- XkbRMLVOSet rmlvo = { NULL};
- XkbGetRulesDflts(&rmlvo);
-
-
- g_assert(rmlvo.rules);
- g_assert(rmlvo.model);
- g_assert(rmlvo.layout);
- g_assert(rmlvo.variant);
- g_assert(rmlvo.options);
- g_assert(strcmp(rmlvo.rules, XKB_DFLT_RULES) == 0);
- g_assert(strcmp(rmlvo.model, XKB_DFLT_MODEL) == 0);
- g_assert(strcmp(rmlvo.layout, XKB_DFLT_LAYOUT) == 0);
- g_assert(strcmp(rmlvo.variant, XKB_DFLT_VARIANT) == 0);
- g_assert(strcmp(rmlvo.options, XKB_DFLT_OPTIONS) == 0);
-}
-
-/**
- * Initialize an random XkbRMLVOSet.
- * Call XkbGetRulesDflts to obtain the default ruleset.
- * Compare obtained ruleset with the built-in defaults.
- * Result: RMLVO defaults are the same as obtained.
- */
-static void xkb_set_rules_test(void)
-{
- XkbRMLVOSet rmlvo = {
- .rules = "test-rules",
- .model = "test-model",
- .layout = "test-layout",
- .variant = "test-variant",
- .options = "test-options"
- };
- XkbRMLVOSet rmlvo_new = { NULL };
-
- XkbSetRulesDflts(&rmlvo);
- XkbGetRulesDflts(&rmlvo_new);
-
- /* XkbGetRulesDflts strdups the values */
- g_assert(rmlvo.rules != rmlvo_new.rules);
- g_assert(rmlvo.model != rmlvo_new.model);
- g_assert(rmlvo.layout != rmlvo_new.layout);
- g_assert(rmlvo.variant != rmlvo_new.variant);
- g_assert(rmlvo.options != rmlvo_new.options);
-
- g_assert(strcmp(rmlvo.rules, rmlvo_new.rules) == 0);
- g_assert(strcmp(rmlvo.model, rmlvo_new.model) == 0);
- g_assert(strcmp(rmlvo.layout, rmlvo_new.layout) == 0);
- g_assert(strcmp(rmlvo.variant, rmlvo_new.variant) == 0);
- g_assert(strcmp(rmlvo.options, rmlvo_new.options) == 0);
-}
-
-
-/**
- * Get the default RMLVO set.
- * Set the default RMLVO set.
- * Get the default RMLVO set.
- * Repeat the last two steps.
- *
- * Result: RMLVO set obtained is the same as previously set.
- */
-static void xkb_set_get_rules_test(void)
-{
-/* This test failed before XkbGetRulesDftlts changed to strdup.
- We test this twice because the first time using XkbGetRulesDflts we obtain
- the built-in defaults. The unexpected free isn't triggered until the second
- XkbSetRulesDefaults.
- */
- XkbRMLVOSet rmlvo = { NULL };
- XkbRMLVOSet rmlvo_backup;
-
- XkbGetRulesDflts(&rmlvo);
-
- /* pass 1 */
- XkbSetRulesDflts(&rmlvo);
- XkbGetRulesDflts(&rmlvo);
-
- /* Make a backup copy */
- rmlvo_backup.rules = strdup(rmlvo.rules);
- rmlvo_backup.layout = strdup(rmlvo.layout);
- rmlvo_backup.model = strdup(rmlvo.model);
- rmlvo_backup.variant = strdup(rmlvo.variant);
- rmlvo_backup.options = strdup(rmlvo.options);
-
- /* pass 2 */
- XkbSetRulesDflts(&rmlvo);
-
- /* This test is iffy, because strictly we may be comparing against already
- * freed memory */
- g_assert(strcmp(rmlvo.rules, rmlvo_backup.rules) == 0);
- g_assert(strcmp(rmlvo.model, rmlvo_backup.model) == 0);
- g_assert(strcmp(rmlvo.layout, rmlvo_backup.layout) == 0);
- g_assert(strcmp(rmlvo.variant, rmlvo_backup.variant) == 0);
- g_assert(strcmp(rmlvo.options, rmlvo_backup.options) == 0);
-
- XkbGetRulesDflts(&rmlvo);
- g_assert(strcmp(rmlvo.rules, rmlvo_backup.rules) == 0);
- g_assert(strcmp(rmlvo.model, rmlvo_backup.model) == 0);
- g_assert(strcmp(rmlvo.layout, rmlvo_backup.layout) == 0);
- g_assert(strcmp(rmlvo.variant, rmlvo_backup.variant) == 0);
- g_assert(strcmp(rmlvo.options, rmlvo_backup.options) == 0);
-}
-
-
-int main(int argc, char** argv)
-{
- g_test_init(&argc, &argv,NULL);
- g_test_bug_base("https://bugzilla.freedesktop.org/show_bug.cgi?id=");
-
- g_test_add_func("/xkb/set-get-rules", xkb_set_get_rules_test);
- g_test_add_func("/xkb/get-rules", xkb_get_rules_test);
- g_test_add_func("/xkb/set-rules", xkb_set_rules_test);
-
- return g_test_run();
-}
+/**
+ * Copyright © 2009 Red Hat, Inc.
+ *
+ * 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, sublicense,
+ * 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 NONINFRINGEMENT. IN NO EVENT SHALL
+ * THE AUTHORS OR COPYRIGHT HOLDERS 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.
+ */
+
+#ifdef HAVE_DIX_CONFIG_H
+#include <dix-config.h>
+#endif
+
+#include <xkb-config.h>
+
+#include <stdio.h>
+#include <stdlib.h>
+#include <ctype.h>
+#include <unistd.h>
+#include <math.h>
+#include <X11/X.h>
+#include <X11/Xproto.h>
+#include <X11/keysym.h>
+#include <X11/Xatom.h>
+#include "misc.h"
+#include "inputstr.h"
+#include "opaque.h"
+#include "property.h"
+#define XKBSRV_NEED_FILE_FUNCS
+#include <xkbsrv.h>
+#include "../xkb/xkbgeom.h"
+#include <X11/extensions/XKMformat.h>
+#include "xkbfile.h"
+#include "../xkb/xkb.h"
+#include <assert.h>
+
+/**
+ * Initialize an empty XkbRMLVOSet.
+ * Call XkbGetRulesDflts to obtain the default ruleset.
+ * Compare obtained ruleset with the built-in defaults.
+ *
+ * Result: RMLVO defaults are the same as obtained.
+ */
+static void xkb_get_rules_test(void)
+{
+ XkbRMLVOSet rmlvo = { NULL};
+ XkbGetRulesDflts(&rmlvo);
+
+
+ assert(rmlvo.rules);
+ assert(rmlvo.model);
+ assert(rmlvo.layout);
+ assert(rmlvo.variant);
+ assert(rmlvo.options);
+ assert(strcmp(rmlvo.rules, XKB_DFLT_RULES) == 0);
+ assert(strcmp(rmlvo.model, XKB_DFLT_MODEL) == 0);
+ assert(strcmp(rmlvo.layout, XKB_DFLT_LAYOUT) == 0);
+ assert(strcmp(rmlvo.variant, XKB_DFLT_VARIANT) == 0);
+ assert(strcmp(rmlvo.options, XKB_DFLT_OPTIONS) == 0);
+}
+
+/**
+ * Initialize an random XkbRMLVOSet.
+ * Call XkbGetRulesDflts to obtain the default ruleset.
+ * Compare obtained ruleset with the built-in defaults.
+ * Result: RMLVO defaults are the same as obtained.
+ */
+static void xkb_set_rules_test(void)
+{
+ XkbRMLVOSet rmlvo = {
+ .rules = "test-rules",
+ .model = "test-model",
+ .layout = "test-layout",
+ .variant = "test-variant",
+ .options = "test-options"
+ };
+ XkbRMLVOSet rmlvo_new = { NULL };
+
+ XkbSetRulesDflts(&rmlvo);
+ XkbGetRulesDflts(&rmlvo_new);
+
+ /* XkbGetRulesDflts strdups the values */
+ assert(rmlvo.rules != rmlvo_new.rules);
+ assert(rmlvo.model != rmlvo_new.model);
+ assert(rmlvo.layout != rmlvo_new.layout);
+ assert(rmlvo.variant != rmlvo_new.variant);
+ assert(rmlvo.options != rmlvo_new.options);
+
+ assert(strcmp(rmlvo.rules, rmlvo_new.rules) == 0);
+ assert(strcmp(rmlvo.model, rmlvo_new.model) == 0);
+ assert(strcmp(rmlvo.layout, rmlvo_new.layout) == 0);
+ assert(strcmp(rmlvo.variant, rmlvo_new.variant) == 0);
+ assert(strcmp(rmlvo.options, rmlvo_new.options) == 0);
+}
+
+
+/**
+ * Get the default RMLVO set.
+ * Set the default RMLVO set.
+ * Get the default RMLVO set.
+ * Repeat the last two steps.
+ *
+ * Result: RMLVO set obtained is the same as previously set.
+ */
+static void xkb_set_get_rules_test(void)
+{
+/* This test failed before XkbGetRulesDftlts changed to strdup.
+ We test this twice because the first time using XkbGetRulesDflts we obtain
+ the built-in defaults. The unexpected free isn't triggered until the second
+ XkbSetRulesDefaults.
+ */
+ XkbRMLVOSet rmlvo = { NULL };
+ XkbRMLVOSet rmlvo_backup;
+
+ XkbGetRulesDflts(&rmlvo);
+
+ /* pass 1 */
+ XkbSetRulesDflts(&rmlvo);
+ XkbGetRulesDflts(&rmlvo);
+
+ /* Make a backup copy */
+ rmlvo_backup.rules = strdup(rmlvo.rules);
+ rmlvo_backup.layout = strdup(rmlvo.layout);
+ rmlvo_backup.model = strdup(rmlvo.model);
+ rmlvo_backup.variant = strdup(rmlvo.variant);
+ rmlvo_backup.options = strdup(rmlvo.options);
+
+ /* pass 2 */
+ XkbSetRulesDflts(&rmlvo);
+
+ /* This test is iffy, because strictly we may be comparing against already
+ * freed memory */
+ assert(strcmp(rmlvo.rules, rmlvo_backup.rules) == 0);
+ assert(strcmp(rmlvo.model, rmlvo_backup.model) == 0);
+ assert(strcmp(rmlvo.layout, rmlvo_backup.layout) == 0);
+ assert(strcmp(rmlvo.variant, rmlvo_backup.variant) == 0);
+ assert(strcmp(rmlvo.options, rmlvo_backup.options) == 0);
+
+ XkbGetRulesDflts(&rmlvo);
+ assert(strcmp(rmlvo.rules, rmlvo_backup.rules) == 0);
+ assert(strcmp(rmlvo.model, rmlvo_backup.model) == 0);
+ assert(strcmp(rmlvo.layout, rmlvo_backup.layout) == 0);
+ assert(strcmp(rmlvo.variant, rmlvo_backup.variant) == 0);
+ assert(strcmp(rmlvo.options, rmlvo_backup.options) == 0);
+}
+
+
+int main(int argc, char** argv)
+{
+ xkb_set_get_rules_test();
+ xkb_get_rules_test();
+ xkb_set_rules_test();
+
+ return 0;
+}
diff --git a/xorg-server/test/xtest.c b/xorg-server/test/xtest.c
index cd8f23bff..d7e3feaa3 100644
--- a/xorg-server/test/xtest.c
+++ b/xorg-server/test/xtest.c
@@ -33,8 +33,6 @@
#include "xkbsrv.h"
#include "xserver-properties.h"
-#include <glib.h>
-
/**
*/
@@ -65,14 +63,14 @@ static void xtest_init_devices(void)
/* this also inits the xtest devices */
InitCoreDevices();
- g_assert(xtestpointer);
- g_assert(xtestkeyboard);
- g_assert(IsXTestDevice(xtestpointer, NULL));
- g_assert(IsXTestDevice(xtestkeyboard, NULL));
- g_assert(IsXTestDevice(xtestpointer, inputInfo.pointer));
- g_assert(IsXTestDevice(xtestkeyboard, inputInfo.keyboard));
- g_assert(GetXTestDevice(inputInfo.pointer) == xtestpointer);
- g_assert(GetXTestDevice(inputInfo.keyboard) == xtestkeyboard);
+ assert(xtestpointer);
+ assert(xtestkeyboard);
+ assert(IsXTestDevice(xtestpointer, NULL));
+ assert(IsXTestDevice(xtestkeyboard, NULL));
+ assert(IsXTestDevice(xtestpointer, inputInfo.pointer));
+ assert(IsXTestDevice(xtestkeyboard, inputInfo.keyboard));
+ assert(GetXTestDevice(inputInfo.pointer) == xtestpointer);
+ assert(GetXTestDevice(inputInfo.keyboard) == xtestkeyboard);
}
/**
@@ -87,32 +85,29 @@ static void xtest_properties(void)
Atom xtest_prop = XIGetKnownProperty(XI_PROP_XTEST_DEVICE);
rc = XIGetDeviceProperty(xtestpointer, xtest_prop, &prop);
- g_assert(rc == Success);
- g_assert(prop);
+ assert(rc == Success);
+ assert(prop);
rc = XIGetDeviceProperty(xtestkeyboard, xtest_prop, &prop);
- g_assert(rc == Success);
- g_assert(prop != NULL);
+ assert(rc == Success);
+ assert(prop != NULL);
rc = XIChangeDeviceProperty(xtestpointer, xtest_prop,
XA_INTEGER, 8, PropModeReplace, 1, &value, FALSE);
- g_assert(rc == BadAccess);
+ assert(rc == BadAccess);
rc = XIChangeDeviceProperty(xtestkeyboard, xtest_prop,
XA_INTEGER, 8, PropModeReplace, 1, &value, FALSE);
- g_assert(rc == BadAccess);
+ assert(rc == BadAccess);
}
int main(int argc, char** argv)
{
- g_test_init(&argc, &argv,NULL);
- g_test_bug_base("https://bugzilla.freedesktop.org/show_bug.cgi?id=");
-
- g_test_add_func("/dix/xtest/init", xtest_init_devices);
- g_test_add_func("/dix/xtest/properties", xtest_properties);
+ xtest_init_devices();
+ xtest_properties();
- return g_test_run();
+ return 0;
}
diff --git a/xorg-server/xkeyboard-config/rules/base.extras.xml.in b/xorg-server/xkeyboard-config/rules/base.extras.xml.in
index c3dcaa46f..f13f28101 100644
--- a/xorg-server/xkeyboard-config/rules/base.extras.xml.in
+++ b/xorg-server/xkeyboard-config/rules/base.extras.xml.in
@@ -7,7 +7,7 @@
<configItem>
<name>apl</name>
<_shortDescription>APL</_shortDescription>
- <_description>APL</_description>
+ <_description>APL Keyboard Symbols</_description>
<languageList><iso639Id>eng</iso639Id></languageList>
</configItem>
<variantList/>
@@ -40,7 +40,7 @@
<configItem>
<name>ir</name>
<_shortDescription>Iran</_shortDescription>
- <_description>Iran</_description>
+ <_description>Persian</_description>
<languageList><iso639Id>per</iso639Id></languageList>
</configItem>
<variantList>
@@ -88,13 +88,13 @@
<variant>
<configItem>
<name>ykeydvorak</name>
- <_description>Latvian (US Dvorak, Y-letter variant)</_description>
+ <_description>Latvian (US Dvorak, Y variant)</_description>
</configItem>
</variant>
<variant>
<configItem>
<name>minuskeydvorak</name>
- <_description>Latvian (US Dvorak, minus-letter variant)</_description>
+ <_description>Latvian (US Dvorak, minus variant)</_description>
</configItem>
</variant>
<variant>
@@ -106,13 +106,13 @@
<variant>
<configItem>
<name>ykeydvorakprogr</name>
- <_description>Latvian (programmer US Dvorak, Y-letter variant)</_description>
+ <_description>Latvian (programmer US Dvorak, Y variant)</_description>
</configItem>
</variant>
<variant>
<configItem>
<name>minuskeydvorakprogr</name>
- <_description>Latvian (programmer US Dvorak - minus-letter variant)</_description>
+ <_description>Latvian (programmer US Dvorak, minus variant)</_description>
</configItem>
</variant>
<variant>
@@ -132,15 +132,15 @@
<layout>
<configItem>
<name>us</name>
- <_shortDescription>USA</_shortDescription>
- <_description>USA</_description>
+ <_shortDescription>en</_shortDescription>
+ <_description>English (US)</_description>
<languageList><iso639Id>eng</iso639Id></languageList>
</configItem>
<variantList>
<variant>
<configItem>
<name>intl-unicode</name>
- <_description>English (US, international (AltGr Unicode combining)</_description>
+ <_description>English (US, international AltGr Unicode combining)</_description>
</configItem>
</variant>
<variant>
@@ -185,7 +185,7 @@
<configItem>
<name>rs</name>
<_shortDescription>Srb</_shortDescription>
- <_description>Serbia</_description>
+ <_description>Serbian</_description>
<languageList><iso639Id>srp</iso639Id></languageList>
</configItem>
<variantList>
diff --git a/xorg-server/xkeyboard-config/symbols/apl b/xorg-server/xkeyboard-config/symbols/apl
index 4421cc398..d4853e68d 100644
--- a/xorg-server/xkeyboard-config/symbols/apl
+++ b/xorg-server/xkeyboard-config/symbols/apl
@@ -1,296 +1,296 @@
-// EXTRAS:
-//
-// APL Keyboard Layouts
-
-// This file supports:
-// - The Sharp APL for Unix (SAX) layout
-// - The IBM APL2 layout
-// - The Manugistics APL*PLUS II (Version 5.1, 1993) keyboard layout
-
-// Unicode APL table: http://aplwiki.com/UnicodeAplTable
-// ...and another: http://publibfp.boulder.ibm.com/epubs/pdf/h2110611.pdf (appendix A)
-// Generic Unicode stuff: http://www.fileformat.info/info/unicode/category/index.htm
-
-// Tim Nelson (this file's creator) says:
-
-// This file doesn't deal with all the combining stuff -- I'm not an APL programmer,
-// and am not quite sure what's needed here. However, it may be possible to get this
-// working with dead keys and the like. Patches gratefully accepted.
-
-// Some of the shift-key assignments may differ from the APL tradition. If
-// that's not considered acceptable, it should be possible to remap the
-// shift keys. I have striven, however, to ensure that the use of shift keys
-// in these maps is at least self-consistent.
-
-// I'm assuming that this will be used with another keyboard layout (ie. for
-// your language), with a special shift key to use these maps.
-
-partial alphanumeric_keys modifier_keys
-xkb_symbols "common" {
- name[Group1]= "APL";
-
- key <AE01> { [ diaeresis ] };
- key <AE02> { [ U00AF ] }; // ¯ -- Macron
- key <AE03> { [ less ] };
- key <AE04> { [ U2264 ] }; // ≤ -- Less-than Or Equal To
- key <AE05> { [ equal ] };
- key <AE06> { [ U2265 ] }; // ≥ -- Greater-than Or Equal To
- key <AE07> { [ greater ] };
- key <AE08> { [ U2260 ] }; // ≠ -- Not Equal To
- key <AE09> { [ U2228 ] }; // ∨ -- Logical Or
- key <AE10> { [ U2227 ] }; // ∧ -- Logical And
-
- // Q
- key <AD01> { [ question ] };
- // W
- key <AD02> { [ U2375 ] }; // ⍵ -- APL Functional Symbol Omega
- // E
- key <AD03> { [ U220A ] }; // ∊ -- Small Element Of
- // R
- key <AD04> { [ U2374 ] }; // ⍴ -- APL Functional Symbol Rho
- // T
- key <AD05> { [ asciitilde ] };
- // Y
- key <AD06> { [ U2191 ] }; // ↑ -- Upwards Arrow
- // U
- key <AD07> { [ U2193 ] }; // ↓ -- Downwards Arrow
- // I
- key <AD08> { [ U2373 ] }; // ⍳ -- APL Functional Symbol Iota
- // O
- key <AD09> { [ U25CB ] }; // ○ -- White Circle
- // P
- key <AD10> { [ U22C6 ] }; // ⋆ -- Should this be a plain asterisk, or the star operator???
- // [
- key <AD11> { [ U2190 ] }; // ← -- Leftwards Arrow
-
- // A
- key <AC01> { [ U237A ] }; // ⍺ -- APL Functional Symbol Alpha
- // S
- key <AC02> { [ U2308 ] }; // ⌈ -- Left Ceiling
- // D
- key <AC03> { [ U230A ] }; // ⌊ -- Left Floor
- // F
- key <AC04> { [ underscore ] };
- // G
- key <AC05> { [ U2207 ] }; // ∇ -- Nabla
- // H
- key <AC06> { [ U2206 ] }; // ∆ -- Increment
- // J
- key <AC07> { [ U2218 ] }; // ∘ -- Ring Operator
- // K
- key <AC08> { [ apostrophe ] };
- // L
- key <AC09> { [ U2395 ] }; // ⎕ -- APL Functional Symbol Quad
-
- // Z
- key <AB01> { [ U2282 ] }; // ⊂ -- Subset Of
- // X
- key <AB02> { [ U2283 ] }; // ⊃ -- Superset Of
- // C
- key <AB03> { [ U2229 ] }; // ∩ -- Intersection
- // V
- key <AB04> { [ U222A ] }; // ∪ -- Union
- // B
- key <AB05> { [ U22A5 ] }; // ⊥ -- Up Tack
- // N
- key <AB06> { [ U22A4 ] }; // ⊤ -- Down Tack
- // M
- key <AB07> { [ U007C ] }; // | -- Vertical Line
-};
-
-// Keys common to a number of keyboards that allow normal language usage alongside APL
-partial alphanumeric_keys modifier_keys
-xkb_symbols "unified" {
- name[Group1]= "APL Keyboard Symbols: Unified Layout";
-
- include "apl(common)"
-
- // `
- key <TLDE> { [ U22C4 ] }; // ⋄ -- Diamond Operator
- key <AE09> { [ NoSymbol, U2371 ] }; // ⍱ -- APL Functional Symbol Down Caret Tilde
- key <AE10> { [ NoSymbol, U2372 ] }; // ⍲ -- APL Functional Symbol Up Caret Tilde
- // -
- key <AE11> { [ U00D7 ] }; // × -- Multiplication Sign
- // =
- key <AE12> { [ U00F7, U2339 ] }; // ÷ ⌹ -- Division Sign / APL Functional Symbol Quad Divide
-
- // ]
- key <AD12> { [ U2192 ] }; // → -- Rightwards Arrow
-};
-
-// Layout: http://www.wickensonline.co.uk/apl-unicomp.html
-default
-partial alphanumeric_keys modifier_keys
-xkb_symbols "sax" {
- name[Group1]= "APL Keyboard Symbols: Sharp APL for Unix";
-
- include "apl(unified)"
-
- key <AE01> { [ NoSymbol, U00A1 ] }; // ¡ -- Inverted Exclamation Mark
- key <AE04> { [ NoSymbol, cent ] };
- key <AE08> { [ NoSymbol, U2342 ] }; // ⍂ -- APL Functional Symbol Quad Backslash
- // -
- key <AE11> { [ NoSymbol, U2261 ] }; // ≡ -- Identical To
-
- // Q
- key <AD01> { [ NoSymbol, U00BF ] }; // ¿ -- Inverted Question Mark
- // W
- key <AD02> { [ NoSymbol, U233D ] }; // ⌽ -- APL Functional Symbol Circle Stile
- // E
- key <AD03> { [ NoSymbol, U2377 ] }; // ⍷ -- APL Functional Symbol Epsilon Underbar
- // T
- key <AD05> { [ NoSymbol, U2349 ] }; // ⍉ -- APL Functional Symbol Circle Backslash
- // I
- key <AD08> { [ NoSymbol, U2378 ] }; // ⍸ -- APL Functional Symbol Iota Underbar
- // O
- key <AD09> { [ NoSymbol, U2365 ] }; // ⍥ -- APL Functional Symbol Circle Diaeresis
- // P
- key <AD10> { [ NoSymbol, U235F ] }; // ⍟ -- APL Functional Symbol Circle Star
-
- // A
- key <AC01> { [ NoSymbol, U2296 ] }; // ⊖ -- Circled Minus
- // F
- key <AC04> { [ NoSymbol, U236B ] }; // ⍫ -- APL Functional Symbol Del Tilde
- // G
- key <AC05> { [ NoSymbol, U2352 ] }; // ∇ ⍒ -- APL Functional Symbol Del Stile
- // H
- key <AC06> { [ NoSymbol, U234B ] }; // ∆ ⍋ -- APL Functional Symbol Delta Stile
- // J
- key <AC07> { [ NoSymbol, U2364 ] }; // ⍤ -- APL Functional Symbol Jot Diaeresis
- // K
- key <AC08> { [ NoSymbol, U233B ] }; // ⌻
- // L
- key <AC09> { [ NoSymbol, U235E ] }; // ⍞ -- APL Functional Symbol Quote Quad
- // ;
- key <AC10> { [ U22A2 ] }; // ⊢ -- Right Tack
- // '
- key <AC11> { [ U22A3 ] }; // ⊣ -- Left Tack
-
- // C
- key <AB03> { [ NoSymbol, U235D ] }; // ⍝ -- APL Functional Symbol Up Shoe Jot
- // B
- key <AB05> { [ NoSymbol, U234E ] }; // ⍎ -- APL Functional Symbol Down Tack Jot (Unicode got the name wrong; it should have been "Up Tack")
- // N
- key <AB06> { [ NoSymbol, U2355 ] }; // ⍕ -- APL Functional Symbol Up Tack Jot (Unicode got the name wrong; it should have been "Down Tack")
- // M
- key <AB07> { [ NoSymbol, U2336 ] }; // ⌶ -- APL Functional Symbol I-Beam
- // ,
- key <AB08> { [ U235E, U236A ] }; // ⍞ ⍪ -- APL Functional Symbol Quote Quad / APL Functional Symbol Comma Bar
- // .
- key <AB09> { [ U234E, U2359 ] }; // ⍎ ⍙ -- [See B key] / APL Functional Symbol Delta Underbar
- // /
- key <AB10> { [ U2355, U233F ] }; // ⍕ ⌿ -- [See N key] / APL Functional Symbol Slash Bar
-
- key <BKSL> { [ U235D, U2340 ] }; // ⍝ ⍀ -- APL Functional Symbol Up Shoe Jot / APL Functional Symbol Backslash Bar
-};
-
-// Layout: http://www.wickensonline.co.uk/apl-unicomp.html
-partial alphanumeric_keys modifier_keys
-xkb_symbols "apl2" {
- name[Group1]= "APL Keyboard Symbols: IBM APL2";
-
- include "apl(common)"
-
- // The first column is NoSymbol because it inherits. The second is NoSymbol because those keys don't do anything
-
- // `
- key <TLDE> { [ NoSymbol, U233B, U2342 ] }; // ⌻ ⍂ --
- key <AE01> { [ NoSymbol, NoSymbol, U2336 ] }; // ⌶ -- APL Functional Symbol I-Beam
- key <AE02> { [ NoSymbol, NoSymbol, U236B ] }; // ⍫ -- APL Functional Symbol Del Tilde
- key <AE03> { [ NoSymbol, NoSymbol, U2353 ] }; // ⍒ -- APL Functional Symbol Del Stile
- key <AE04> { [ NoSymbol, NoSymbol, U234B ] }; // ⍋ -- APL Functional Symbol Delta Stile
- key <AE05> { [ NoSymbol, NoSymbol, U233D ] }; // ⌽ -- APL Functional Symbol Circle Stile
- key <AE06> { [ NoSymbol, NoSymbol, U2349 ] }; // ⍉ -- APL Functional Symbol Circle Backslash
- key <AE07> { [ NoSymbol, NoSymbol, U2296 ] }; // ⊖ -- Circled Minus
- key <AE08> { [ NoSymbol, NoSymbol, U235F ] }; // ⍟ -- APL Functional Symbol Circle Star
- key <AE09> { [ NoSymbol, NoSymbol, U2371 ] }; // ⍱ -- APL Functional Symbol Down Caret Tilde
- key <AE10> { [ NoSymbol, NoSymbol, U2372 ] }; // ⍲ -- APL Functional Symbol Up Caret Tilde
- // -
- key <AE11> { [ plus, minus, exclam ] };
- // =
- key <AE12> { [ U00D7, U00F7, U2339 ] }; // × ÷ ⌹ -- Multiplication Sign / Division Sign / APL Functional Symbol Quad Divide
-
- // [
- key <AD11> { [ NoSymbol, U2192, U235E ] }; // (←) → ⍞ -- Rightwards Arrow / APL Functional Symbol Quote Quad
- // ]
- key <AD12> { [ U2337, U2378, U2359 ] }; // ⌷ ⍸ ⍙ -- APL Functional Symbol Squish Quad / APL Functional Symbol Iota Underbar / APL Functional Symbol Delta Underbar
-
- // ;
- key <AC10> { [ bracketleft, parenleft, U234E ] }; // ⍎ -- [See B key in SAX layout]
- // '
- key <AC11> { [ bracketright, parenright, U2355 ] }; // ⍕ -- [See N key in SAX layout]
-
- // ,
- key <AB08> { [ comma, semicolon, U235D ] }; // ⍝ -- APL Functional Symbol Up Shoe Jot
- // .
- key <AB09> { [ period, colon, U2340 ] }; // ⍀ -- APL Functional Symbol Backslash Bar
- // /
- key <AB10> { [ slash, backslash, U233F ] }; // ⌿ -- APL Functional Symbol Slash Bar
-
- key <BKSL> { [ U2261, U2377, U2364 ] }; // ≡ ⍷ ⍤ -- Identical To / APL Functional Symbol Epsilon Underbar / APL Functional Symbol Jot Diaeresis
-};
-
-partial alphanumeric_keys modifier_keys
-xkb_symbols "aplplusII" {
- name[Group1]= "APL Keyboard Symbols: Manugistics APL*PLUS II";
-
- include "apl(apl2)"
-
- // `
- key <TLDE> { [ dollar, U22C4, U236A ] }; // ⋄ ⍪ -- Diamond Operator / APL Functional Symbol Comma Bar
- key <AE01> { [ NoSymbol, NoSymbol, U2261 ] }; // ≡ -- Identical To
-
- // [
- key <AD11> { [ U2190, NoSymbol, U235E ] }; // ← ⍞ -- Leftwards Arrow / APL Functional Symbol Quote Quad
- // ]
- key <AD12> { [ U2192, NoSymbol, U236C ] }; // → ⍬ -- Rightwards Arrow / APL Functional Symbol Zilde
-
- // ;
- key <AC10> { [ bracketleft, parenleft, U234E ] }; // ⍎ -- [See B key in SAX layout]
- // '
- key <AC11> { [ bracketright, parenright, U2355 ] }; // ⍕ -- [See N key in SAX layout]
-
- key <BKSL> { [ U22A3, U22A2, U2359 ] }; // ⊣ ⊢ ⍙ -- Left Tack / Right Tack / APL Functional Symbol Delta Underbar
-};
-
-
-// MicroAPL layout: http://aplwiki.com/APLXKeyboardLayouts
-// I didn't do the old-style MicroAPL layout; patches gratefully accepted
-partial alphanumeric_keys modifier_keys
-xkb_symbols "aplx" {
- name[Group1]= "APL Keyboard Symbols: APLX Unified APL Layout";
-
- include "apl(unified)"
-
- // `
- key <TLDE> { [ NoSymbol, U235E ] }; // ⍞ -- APL Functional Symbol Quote Quad
- key <AE01> { [ NoSymbol, U2336 ] }; // ⌶ -- APL Functional Symbol I-Beam
- key <AE02> { [ NoSymbol, U236B ] }; // ⍫ -- APL Functional Symbol Del Tilde
- key <AE03> { [ NoSymbol, U2353 ] }; // ⍒ -- APL Functional Symbol Del Stile
- key <AE04> { [ NoSymbol, U234B ] }; // ⍋ -- APL Functional Symbol Delta Stile
- key <AE05> { [ NoSymbol, U233D ] }; // ⌽ -- APL Functional Symbol Circle Stile
- key <AE06> { [ NoSymbol, U2349 ] }; // ⍉ -- APL Functional Symbol Circle Backslash
- key <AE07> { [ NoSymbol, U2296 ] }; // ⊖ -- Circled Minus
- key <AE08> { [ NoSymbol, U235F ] }; // ⍟ -- APL Functional Symbol Circle Star
- // -
- key <AE11> { [ NoSymbol, exclam ] };
-
- // [
- key <AD11> { [ NoSymbol, U2347 ] }; // ⍇ -- Box With Left Arrow
- // ]
- key <AD12> { [ NoSymbol, U2348 ] }; // ⍈ -- Box With Right Arrow
-
- // ;
- key <AC10> { [ U234E, U2261 ] }; // ⍎ ≡ -- [See B key in SAX layout] / Identical To
- // '
- key <AC11> { [ U2355, U2262 ] }; // ⍕ ≢ -- [See N key in SAX layout] / Not Identical To
-
- // ,
- key <AB08> { [ U235D, U236A ] }; // ⍝ ⍪ -- APL Functional Symbol Up Shoe Jot / APL Functional Symbol Comma Bar
- // .
- key <AB09> { [ U2340, U2364 ] }; // ⍀ ⍤ -- APL Functional Symbol Backslash Bar / APL Functional Symbol Jot Diaeresis
- // /
- key <AB10> { [ U233F ] }; // ⌿ -- APL Functional Symbol Slash Bar
-
- key <BKSL> { [ U22A3, U22A3 ] }; // ⊣ ⊢ -- Left Tack / Right Tack
-};
+// EXTRAS:
+//
+// APL Keyboard Layouts
+
+// This file supports:
+// - The Sharp APL for Unix (SAX) layout
+// - The IBM APL2 layout
+// - The Manugistics APL*PLUS II (Version 5.1, 1993) keyboard layout
+
+// Unicode APL table: http://aplwiki.com/UnicodeAplTable
+// ...and another: http://publibfp.boulder.ibm.com/epubs/pdf/h2110611.pdf (appendix A)
+// Generic Unicode stuff: http://www.fileformat.info/info/unicode/category/index.htm
+
+// Tim Nelson (this file's creator) says:
+
+// This file doesn't deal with all the combining stuff -- I'm not an APL programmer,
+// and am not quite sure what's needed here. However, it may be possible to get this
+// working with dead keys and the like. Patches gratefully accepted.
+
+// Some of the shift-key assignments may differ from the APL tradition. If
+// that's not considered acceptable, it should be possible to remap the
+// shift keys. I have striven, however, to ensure that the use of shift keys
+// in these maps is at least self-consistent.
+
+// I'm assuming that this will be used with another keyboard layout (ie. for
+// your language), with a special shift key to use these maps.
+
+partial alphanumeric_keys modifier_keys
+xkb_symbols "common" {
+ name[Group1]= "APL";
+
+ key <AE01> { [ diaeresis ] };
+ key <AE02> { [ U00AF ] }; // ¯ -- Macron
+ key <AE03> { [ less ] };
+ key <AE04> { [ U2264 ] }; // ≤ -- Less-than Or Equal To
+ key <AE05> { [ equal ] };
+ key <AE06> { [ U2265 ] }; // ≥ -- Greater-than Or Equal To
+ key <AE07> { [ greater ] };
+ key <AE08> { [ U2260 ] }; // ≠ -- Not Equal To
+ key <AE09> { [ U2228 ] }; // ∨ -- Logical Or
+ key <AE10> { [ U2227 ] }; // ∧ -- Logical And
+
+ // Q
+ key <AD01> { [ question ] };
+ // W
+ key <AD02> { [ U2375 ] }; // ⍵ -- APL Functional Symbol Omega
+ // E
+ key <AD03> { [ U220A ] }; // ∊ -- Small Element Of
+ // R
+ key <AD04> { [ U2374 ] }; // ⍴ -- APL Functional Symbol Rho
+ // T
+ key <AD05> { [ asciitilde ] };
+ // Y
+ key <AD06> { [ U2191 ] }; // ↑ -- Upwards Arrow
+ // U
+ key <AD07> { [ U2193 ] }; // ↓ -- Downwards Arrow
+ // I
+ key <AD08> { [ U2373 ] }; // ⍳ -- APL Functional Symbol Iota
+ // O
+ key <AD09> { [ U25CB ] }; // ○ -- White Circle
+ // P
+ key <AD10> { [ U22C6 ] }; // ⋆ -- Should this be a plain asterisk, or the star operator???
+ // [
+ key <AD11> { [ U2190 ] }; // ← -- Leftwards Arrow
+
+ // A
+ key <AC01> { [ U237A ] }; // ⍺ -- APL Functional Symbol Alpha
+ // S
+ key <AC02> { [ U2308 ] }; // ⌈ -- Left Ceiling
+ // D
+ key <AC03> { [ U230A ] }; // ⌊ -- Left Floor
+ // F
+ key <AC04> { [ underscore ] };
+ // G
+ key <AC05> { [ U2207 ] }; // ∇ -- Nabla
+ // H
+ key <AC06> { [ U2206 ] }; // ∆ -- Increment
+ // J
+ key <AC07> { [ U2218 ] }; // ∘ -- Ring Operator
+ // K
+ key <AC08> { [ apostrophe ] };
+ // L
+ key <AC09> { [ U2395 ] }; // ⎕ -- APL Functional Symbol Quad
+
+ // Z
+ key <AB01> { [ U2282 ] }; // ⊂ -- Subset Of
+ // X
+ key <AB02> { [ U2283 ] }; // ⊃ -- Superset Of
+ // C
+ key <AB03> { [ U2229 ] }; // ∩ -- Intersection
+ // V
+ key <AB04> { [ U222A ] }; // ∪ -- Union
+ // B
+ key <AB05> { [ U22A5 ] }; // ⊥ -- Up Tack
+ // N
+ key <AB06> { [ U22A4 ] }; // ⊤ -- Down Tack
+ // M
+ key <AB07> { [ U007C ] }; // | -- Vertical Line
+};
+
+// Keys common to a number of keyboards that allow normal language usage alongside APL
+partial alphanumeric_keys modifier_keys
+xkb_symbols "unified" {
+ name[Group1]= "APL Keyboard Symbols: Unified Layout";
+
+ include "apl(common)"
+
+ // `
+ key <TLDE> { [ U22C4 ] }; // ⋄ -- Diamond Operator
+ key <AE09> { [ NoSymbol, U2371 ] }; // ⍱ -- APL Functional Symbol Down Caret Tilde
+ key <AE10> { [ NoSymbol, U2372 ] }; // ⍲ -- APL Functional Symbol Up Caret Tilde
+ // -
+ key <AE11> { [ U00D7 ] }; // × -- Multiplication Sign
+ // =
+ key <AE12> { [ U00F7, U2339 ] }; // ÷ ⌹ -- Division Sign / APL Functional Symbol Quad Divide
+
+ // ]
+ key <AD12> { [ U2192 ] }; // → -- Rightwards Arrow
+};
+
+// Layout: http://www.wickensonline.co.uk/apl-unicomp.html
+default
+partial alphanumeric_keys modifier_keys
+xkb_symbols "sax" {
+ name[Group1]= "APL Keyboard Symbols";
+
+ include "apl(unified)"
+
+ key <AE01> { [ NoSymbol, U00A1 ] }; // ¡ -- Inverted Exclamation Mark
+ key <AE04> { [ NoSymbol, cent ] };
+ key <AE08> { [ NoSymbol, U2342 ] }; // ⍂ -- APL Functional Symbol Quad Backslash
+ // -
+ key <AE11> { [ NoSymbol, U2261 ] }; // ≡ -- Identical To
+
+ // Q
+ key <AD01> { [ NoSymbol, U00BF ] }; // ¿ -- Inverted Question Mark
+ // W
+ key <AD02> { [ NoSymbol, U233D ] }; // ⌽ -- APL Functional Symbol Circle Stile
+ // E
+ key <AD03> { [ NoSymbol, U2377 ] }; // ⍷ -- APL Functional Symbol Epsilon Underbar
+ // T
+ key <AD05> { [ NoSymbol, U2349 ] }; // ⍉ -- APL Functional Symbol Circle Backslash
+ // I
+ key <AD08> { [ NoSymbol, U2378 ] }; // ⍸ -- APL Functional Symbol Iota Underbar
+ // O
+ key <AD09> { [ NoSymbol, U2365 ] }; // ⍥ -- APL Functional Symbol Circle Diaeresis
+ // P
+ key <AD10> { [ NoSymbol, U235F ] }; // ⍟ -- APL Functional Symbol Circle Star
+
+ // A
+ key <AC01> { [ NoSymbol, U2296 ] }; // ⊖ -- Circled Minus
+ // F
+ key <AC04> { [ NoSymbol, U236B ] }; // ⍫ -- APL Functional Symbol Del Tilde
+ // G
+ key <AC05> { [ NoSymbol, U2352 ] }; // ∇ ⍒ -- APL Functional Symbol Del Stile
+ // H
+ key <AC06> { [ NoSymbol, U234B ] }; // ∆ ⍋ -- APL Functional Symbol Delta Stile
+ // J
+ key <AC07> { [ NoSymbol, U2364 ] }; // ⍤ -- APL Functional Symbol Jot Diaeresis
+ // K
+ key <AC08> { [ NoSymbol, U233B ] }; // ⌻
+ // L
+ key <AC09> { [ NoSymbol, U235E ] }; // ⍞ -- APL Functional Symbol Quote Quad
+ // ;
+ key <AC10> { [ U22A2 ] }; // ⊢ -- Right Tack
+ // '
+ key <AC11> { [ U22A3 ] }; // ⊣ -- Left Tack
+
+ // C
+ key <AB03> { [ NoSymbol, U235D ] }; // ⍝ -- APL Functional Symbol Up Shoe Jot
+ // B
+ key <AB05> { [ NoSymbol, U234E ] }; // ⍎ -- APL Functional Symbol Down Tack Jot (Unicode got the name wrong; it should have been "Up Tack")
+ // N
+ key <AB06> { [ NoSymbol, U2355 ] }; // ⍕ -- APL Functional Symbol Up Tack Jot (Unicode got the name wrong; it should have been "Down Tack")
+ // M
+ key <AB07> { [ NoSymbol, U2336 ] }; // ⌶ -- APL Functional Symbol I-Beam
+ // ,
+ key <AB08> { [ U235E, U236A ] }; // ⍞ ⍪ -- APL Functional Symbol Quote Quad / APL Functional Symbol Comma Bar
+ // .
+ key <AB09> { [ U234E, U2359 ] }; // ⍎ ⍙ -- [See B key] / APL Functional Symbol Delta Underbar
+ // /
+ key <AB10> { [ U2355, U233F ] }; // ⍕ ⌿ -- [See N key] / APL Functional Symbol Slash Bar
+
+ key <BKSL> { [ U235D, U2340 ] }; // ⍝ ⍀ -- APL Functional Symbol Up Shoe Jot / APL Functional Symbol Backslash Bar
+};
+
+// Layout: http://www.wickensonline.co.uk/apl-unicomp.html
+partial alphanumeric_keys modifier_keys
+xkb_symbols "apl2" {
+ name[Group1]= "APL Keyboard Symbols: IBM APL2";
+
+ include "apl(common)"
+
+ // The first column is NoSymbol because it inherits. The second is NoSymbol because those keys don't do anything
+
+ // `
+ key <TLDE> { [ NoSymbol, U233B, U2342 ] }; // ⌻ ⍂ --
+ key <AE01> { [ NoSymbol, NoSymbol, U2336 ] }; // ⌶ -- APL Functional Symbol I-Beam
+ key <AE02> { [ NoSymbol, NoSymbol, U236B ] }; // ⍫ -- APL Functional Symbol Del Tilde
+ key <AE03> { [ NoSymbol, NoSymbol, U2353 ] }; // ⍒ -- APL Functional Symbol Del Stile
+ key <AE04> { [ NoSymbol, NoSymbol, U234B ] }; // ⍋ -- APL Functional Symbol Delta Stile
+ key <AE05> { [ NoSymbol, NoSymbol, U233D ] }; // ⌽ -- APL Functional Symbol Circle Stile
+ key <AE06> { [ NoSymbol, NoSymbol, U2349 ] }; // ⍉ -- APL Functional Symbol Circle Backslash
+ key <AE07> { [ NoSymbol, NoSymbol, U2296 ] }; // ⊖ -- Circled Minus
+ key <AE08> { [ NoSymbol, NoSymbol, U235F ] }; // ⍟ -- APL Functional Symbol Circle Star
+ key <AE09> { [ NoSymbol, NoSymbol, U2371 ] }; // ⍱ -- APL Functional Symbol Down Caret Tilde
+ key <AE10> { [ NoSymbol, NoSymbol, U2372 ] }; // ⍲ -- APL Functional Symbol Up Caret Tilde
+ // -
+ key <AE11> { [ plus, minus, exclam ] };
+ // =
+ key <AE12> { [ U00D7, U00F7, U2339 ] }; // × ÷ ⌹ -- Multiplication Sign / Division Sign / APL Functional Symbol Quad Divide
+
+ // [
+ key <AD11> { [ NoSymbol, U2192, U235E ] }; // (←) → ⍞ -- Rightwards Arrow / APL Functional Symbol Quote Quad
+ // ]
+ key <AD12> { [ U2337, U2378, U2359 ] }; // ⌷ ⍸ ⍙ -- APL Functional Symbol Squish Quad / APL Functional Symbol Iota Underbar / APL Functional Symbol Delta Underbar
+
+ // ;
+ key <AC10> { [ bracketleft, parenleft, U234E ] }; // ⍎ -- [See B key in SAX layout]
+ // '
+ key <AC11> { [ bracketright, parenright, U2355 ] }; // ⍕ -- [See N key in SAX layout]
+
+ // ,
+ key <AB08> { [ comma, semicolon, U235D ] }; // ⍝ -- APL Functional Symbol Up Shoe Jot
+ // .
+ key <AB09> { [ period, colon, U2340 ] }; // ⍀ -- APL Functional Symbol Backslash Bar
+ // /
+ key <AB10> { [ slash, backslash, U233F ] }; // ⌿ -- APL Functional Symbol Slash Bar
+
+ key <BKSL> { [ U2261, U2377, U2364 ] }; // ≡ ⍷ ⍤ -- Identical To / APL Functional Symbol Epsilon Underbar / APL Functional Symbol Jot Diaeresis
+};
+
+partial alphanumeric_keys modifier_keys
+xkb_symbols "aplplusII" {
+ name[Group1]= "APL Keyboard Symbols: Manugistics APL*PLUS II";
+
+ include "apl(apl2)"
+
+ // `
+ key <TLDE> { [ dollar, U22C4, U236A ] }; // ⋄ ⍪ -- Diamond Operator / APL Functional Symbol Comma Bar
+ key <AE01> { [ NoSymbol, NoSymbol, U2261 ] }; // ≡ -- Identical To
+
+ // [
+ key <AD11> { [ U2190, NoSymbol, U235E ] }; // ← ⍞ -- Leftwards Arrow / APL Functional Symbol Quote Quad
+ // ]
+ key <AD12> { [ U2192, NoSymbol, U236C ] }; // → ⍬ -- Rightwards Arrow / APL Functional Symbol Zilde
+
+ // ;
+ key <AC10> { [ bracketleft, parenleft, U234E ] }; // ⍎ -- [See B key in SAX layout]
+ // '
+ key <AC11> { [ bracketright, parenright, U2355 ] }; // ⍕ -- [See N key in SAX layout]
+
+ key <BKSL> { [ U22A3, U22A2, U2359 ] }; // ⊣ ⊢ ⍙ -- Left Tack / Right Tack / APL Functional Symbol Delta Underbar
+};
+
+
+// MicroAPL layout: http://aplwiki.com/APLXKeyboardLayouts
+// I didn't do the old-style MicroAPL layout; patches gratefully accepted
+partial alphanumeric_keys modifier_keys
+xkb_symbols "aplx" {
+ name[Group1]= "APL Keyboard Symbols: APLX Unified APL Layout";
+
+ include "apl(unified)"
+
+ // `
+ key <TLDE> { [ NoSymbol, U235E ] }; // ⍞ -- APL Functional Symbol Quote Quad
+ key <AE01> { [ NoSymbol, U2336 ] }; // ⌶ -- APL Functional Symbol I-Beam
+ key <AE02> { [ NoSymbol, U236B ] }; // ⍫ -- APL Functional Symbol Del Tilde
+ key <AE03> { [ NoSymbol, U2353 ] }; // ⍒ -- APL Functional Symbol Del Stile
+ key <AE04> { [ NoSymbol, U234B ] }; // ⍋ -- APL Functional Symbol Delta Stile
+ key <AE05> { [ NoSymbol, U233D ] }; // ⌽ -- APL Functional Symbol Circle Stile
+ key <AE06> { [ NoSymbol, U2349 ] }; // ⍉ -- APL Functional Symbol Circle Backslash
+ key <AE07> { [ NoSymbol, U2296 ] }; // ⊖ -- Circled Minus
+ key <AE08> { [ NoSymbol, U235F ] }; // ⍟ -- APL Functional Symbol Circle Star
+ // -
+ key <AE11> { [ NoSymbol, exclam ] };
+
+ // [
+ key <AD11> { [ NoSymbol, U2347 ] }; // ⍇ -- Box With Left Arrow
+ // ]
+ key <AD12> { [ NoSymbol, U2348 ] }; // ⍈ -- Box With Right Arrow
+
+ // ;
+ key <AC10> { [ U234E, U2261 ] }; // ⍎ ≡ -- [See B key in SAX layout] / Identical To
+ // '
+ key <AC11> { [ U2355, U2262 ] }; // ⍕ ≢ -- [See N key in SAX layout] / Not Identical To
+
+ // ,
+ key <AB08> { [ U235D, U236A ] }; // ⍝ ⍪ -- APL Functional Symbol Up Shoe Jot / APL Functional Symbol Comma Bar
+ // .
+ key <AB09> { [ U2340, U2364 ] }; // ⍀ ⍤ -- APL Functional Symbol Backslash Bar / APL Functional Symbol Jot Diaeresis
+ // /
+ key <AB10> { [ U233F ] }; // ⌿ -- APL Functional Symbol Slash Bar
+
+ key <BKSL> { [ U22A3, U22A3 ] }; // ⊣ ⊢ -- Left Tack / Right Tack
+};
diff --git a/xorg-server/xkeyboard-config/symbols/et b/xorg-server/xkeyboard-config/symbols/et
index e74c7cee0..d1aab8df9 100644
--- a/xorg-server/xkeyboard-config/symbols/et
+++ b/xorg-server/xkeyboard-config/symbols/et
@@ -14,7 +14,7 @@ xkb_symbols "basic" {
partial alphanumeric_keys
xkb_symbols "olpc" {
- name[Group1]="Ethiopia";
+ name[Group1]="Amharic";
key <AE01> { [ 0x01001369, 0x01001372 ] }; // 1
key <AE02> { [ 0x0100136a, 0x01001373 ] }; // 2
diff --git a/xorg-server/xkeyboard-config/symbols/lv b/xorg-server/xkeyboard-config/symbols/lv
index 176df5d28..532c49749 100644
--- a/xorg-server/xkeyboard-config/symbols/lv
+++ b/xorg-server/xkeyboard-config/symbols/lv
@@ -452,7 +452,7 @@ xkb_symbols "ykeydvorakprogr" {
include "lv(dvorakprogr)"
- name[Group1]= "Latvian (programmer US-Dvorak, Y variant)";
+ name[Group1]= "Latvian (programmer US Dvorak, Y variant)";
key <AD05> {[ISO_Level3_Latch, ISO_Level3_Latch, y, Y]};
key <SPCE> {[space, space, y, Y]};
diff --git a/xorg-server/xkeyboard-config/symbols/us b/xorg-server/xkeyboard-config/symbols/us
index 396dde6a9..5b5f03988 100644
--- a/xorg-server/xkeyboard-config/symbols/us
+++ b/xorg-server/xkeyboard-config/symbols/us
@@ -992,7 +992,7 @@ partial alphanumeric_keys
xkb_symbols "olpc" {
include "us(basic)"
- name[Group1]= "USA";
+ name[Group1]= "English (US)";
// OLPC international US English keyboard layout.
// It's a little different from the usual international layout.
@@ -1146,7 +1146,7 @@ xkb_symbols "hbs" {
partial alphanumeric_keys
xkb_symbols "htcdream" {
include "inet(htcdream)"
- name[Group1]= "English (USA)";
+ name[Group1]= "English (US)";
//second row
key <AD01> { [ q, Q, Tab, Tab ] };
diff --git a/xorg-server/xkeyboard-config/tests/genLists4Comparizon.sh b/xorg-server/xkeyboard-config/tests/genLists4Comparizon.sh
index ccaaba7e0..39205074f 100644
--- a/xorg-server/xkeyboard-config/tests/genLists4Comparizon.sh
+++ b/xorg-server/xkeyboard-config/tests/genLists4Comparizon.sh
@@ -9,8 +9,13 @@
ROOT="`dirname $0`/.."
F1=reg2ll.lst
F2=gn2ll.lst
+F1b=${F1}base
+F1e=${F1}extras
-xsltproc $ROOT/xslt/reg2ll.xsl $ROOT/rules/base.xml | sort | uniq > $F1
+xsltproc $ROOT/xslt/reg2ll.xsl $ROOT/rules/base.xml > $F1b
+xsltproc $ROOT/xslt/reg2ll.xsl $ROOT/rules/base.extras.xml > $F1e
+cat $F1b $F1e | sort | uniq > $F1
+rm -f $F1e $F1e
for i in $ROOT/symbols/*; do
if [ -f $i ]; then
@@ -34,7 +39,10 @@ for i in $ROOT/symbols/*; do
} else
{
name=$2;
- printf "%s(%s):\"%s\"\n", id, variant, name;
+ if (variant == "olpc" || variant == "htcdream")
+ printf "%s:\"%s\"\n", id, name;
+ else
+ printf "%s(%s):\"%s\"\n", id, variant, name;
}
}' $i
fi