1import xcffib
2import struct
3import six
4MAJOR_VERSION = 1
5MINOR_VERSION = 4
6key = xcffib.ExtensionKey("GLX")
7_events = {}
8_errors = {}
9from . import xproto
10class GenericError(xcffib.Error):
11    def __init__(self, unpacker):
12        if isinstance(unpacker, xcffib.Protobj):
13            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
14        xcffib.Error.__init__(self, unpacker)
15        base = unpacker.offset
16        self.bad_value, self.minor_opcode, self.major_opcode = unpacker.unpack("xx2xIHB21x")
17        self.bufsize = unpacker.offset - base
18    def pack(self):
19        buf = six.BytesIO()
20        buf.write(struct.pack("=B", -1))
21        buf.write(struct.pack("=x2xIHB21x", self.bad_value, self.minor_opcode, self.major_opcode))
22        return buf.getvalue()
23BadGeneric = GenericError
24_errors[-1] = GenericError
25class BadContextError(xcffib.Error):
26    def __init__(self, unpacker):
27        if isinstance(unpacker, xcffib.Protobj):
28            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
29        xcffib.Error.__init__(self, unpacker)
30        base = unpacker.offset
31        self.bad_value, self.minor_opcode, self.major_opcode = unpacker.unpack("xx2xIHB21x")
32        self.bufsize = unpacker.offset - base
33    def pack(self):
34        buf = six.BytesIO()
35        buf.write(struct.pack("=B", 0))
36        buf.write(struct.pack("=x2xIHB21x", self.bad_value, self.minor_opcode, self.major_opcode))
37        return buf.getvalue()
38BadBadContext = BadContextError
39_errors[0] = BadContextError
40class BadContextStateError(xcffib.Error):
41    def __init__(self, unpacker):
42        if isinstance(unpacker, xcffib.Protobj):
43            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
44        xcffib.Error.__init__(self, unpacker)
45        base = unpacker.offset
46        self.bad_value, self.minor_opcode, self.major_opcode = unpacker.unpack("xx2xIHB21x")
47        self.bufsize = unpacker.offset - base
48    def pack(self):
49        buf = six.BytesIO()
50        buf.write(struct.pack("=B", 1))
51        buf.write(struct.pack("=x2xIHB21x", self.bad_value, self.minor_opcode, self.major_opcode))
52        return buf.getvalue()
53BadBadContextState = BadContextStateError
54_errors[1] = BadContextStateError
55class BadDrawableError(xcffib.Error):
56    def __init__(self, unpacker):
57        if isinstance(unpacker, xcffib.Protobj):
58            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
59        xcffib.Error.__init__(self, unpacker)
60        base = unpacker.offset
61        self.bad_value, self.minor_opcode, self.major_opcode = unpacker.unpack("xx2xIHB21x")
62        self.bufsize = unpacker.offset - base
63    def pack(self):
64        buf = six.BytesIO()
65        buf.write(struct.pack("=B", 2))
66        buf.write(struct.pack("=x2xIHB21x", self.bad_value, self.minor_opcode, self.major_opcode))
67        return buf.getvalue()
68BadBadDrawable = BadDrawableError
69_errors[2] = BadDrawableError
70class BadPixmapError(xcffib.Error):
71    def __init__(self, unpacker):
72        if isinstance(unpacker, xcffib.Protobj):
73            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
74        xcffib.Error.__init__(self, unpacker)
75        base = unpacker.offset
76        self.bad_value, self.minor_opcode, self.major_opcode = unpacker.unpack("xx2xIHB21x")
77        self.bufsize = unpacker.offset - base
78    def pack(self):
79        buf = six.BytesIO()
80        buf.write(struct.pack("=B", 3))
81        buf.write(struct.pack("=x2xIHB21x", self.bad_value, self.minor_opcode, self.major_opcode))
82        return buf.getvalue()
83BadBadPixmap = BadPixmapError
84_errors[3] = BadPixmapError
85class BadContextTagError(xcffib.Error):
86    def __init__(self, unpacker):
87        if isinstance(unpacker, xcffib.Protobj):
88            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
89        xcffib.Error.__init__(self, unpacker)
90        base = unpacker.offset
91        self.bad_value, self.minor_opcode, self.major_opcode = unpacker.unpack("xx2xIHB21x")
92        self.bufsize = unpacker.offset - base
93    def pack(self):
94        buf = six.BytesIO()
95        buf.write(struct.pack("=B", 4))
96        buf.write(struct.pack("=x2xIHB21x", self.bad_value, self.minor_opcode, self.major_opcode))
97        return buf.getvalue()
98BadBadContextTag = BadContextTagError
99_errors[4] = BadContextTagError
100class BadCurrentWindowError(xcffib.Error):
101    def __init__(self, unpacker):
102        if isinstance(unpacker, xcffib.Protobj):
103            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
104        xcffib.Error.__init__(self, unpacker)
105        base = unpacker.offset
106        self.bad_value, self.minor_opcode, self.major_opcode = unpacker.unpack("xx2xIHB21x")
107        self.bufsize = unpacker.offset - base
108    def pack(self):
109        buf = six.BytesIO()
110        buf.write(struct.pack("=B", 5))
111        buf.write(struct.pack("=x2xIHB21x", self.bad_value, self.minor_opcode, self.major_opcode))
112        return buf.getvalue()
113BadBadCurrentWindow = BadCurrentWindowError
114_errors[5] = BadCurrentWindowError
115class BadRenderRequestError(xcffib.Error):
116    def __init__(self, unpacker):
117        if isinstance(unpacker, xcffib.Protobj):
118            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
119        xcffib.Error.__init__(self, unpacker)
120        base = unpacker.offset
121        self.bad_value, self.minor_opcode, self.major_opcode = unpacker.unpack("xx2xIHB21x")
122        self.bufsize = unpacker.offset - base
123    def pack(self):
124        buf = six.BytesIO()
125        buf.write(struct.pack("=B", 6))
126        buf.write(struct.pack("=x2xIHB21x", self.bad_value, self.minor_opcode, self.major_opcode))
127        return buf.getvalue()
128BadBadRenderRequest = BadRenderRequestError
129_errors[6] = BadRenderRequestError
130class BadLargeRequestError(xcffib.Error):
131    def __init__(self, unpacker):
132        if isinstance(unpacker, xcffib.Protobj):
133            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
134        xcffib.Error.__init__(self, unpacker)
135        base = unpacker.offset
136        self.bad_value, self.minor_opcode, self.major_opcode = unpacker.unpack("xx2xIHB21x")
137        self.bufsize = unpacker.offset - base
138    def pack(self):
139        buf = six.BytesIO()
140        buf.write(struct.pack("=B", 7))
141        buf.write(struct.pack("=x2xIHB21x", self.bad_value, self.minor_opcode, self.major_opcode))
142        return buf.getvalue()
143BadBadLargeRequest = BadLargeRequestError
144_errors[7] = BadLargeRequestError
145class UnsupportedPrivateRequestError(xcffib.Error):
146    def __init__(self, unpacker):
147        if isinstance(unpacker, xcffib.Protobj):
148            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
149        xcffib.Error.__init__(self, unpacker)
150        base = unpacker.offset
151        self.bad_value, self.minor_opcode, self.major_opcode = unpacker.unpack("xx2xIHB21x")
152        self.bufsize = unpacker.offset - base
153    def pack(self):
154        buf = six.BytesIO()
155        buf.write(struct.pack("=B", 8))
156        buf.write(struct.pack("=x2xIHB21x", self.bad_value, self.minor_opcode, self.major_opcode))
157        return buf.getvalue()
158BadUnsupportedPrivateRequest = UnsupportedPrivateRequestError
159_errors[8] = UnsupportedPrivateRequestError
160class BadFBConfigError(xcffib.Error):
161    def __init__(self, unpacker):
162        if isinstance(unpacker, xcffib.Protobj):
163            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
164        xcffib.Error.__init__(self, unpacker)
165        base = unpacker.offset
166        self.bad_value, self.minor_opcode, self.major_opcode = unpacker.unpack("xx2xIHB21x")
167        self.bufsize = unpacker.offset - base
168    def pack(self):
169        buf = six.BytesIO()
170        buf.write(struct.pack("=B", 9))
171        buf.write(struct.pack("=x2xIHB21x", self.bad_value, self.minor_opcode, self.major_opcode))
172        return buf.getvalue()
173BadBadFBConfig = BadFBConfigError
174_errors[9] = BadFBConfigError
175class BadPbufferError(xcffib.Error):
176    def __init__(self, unpacker):
177        if isinstance(unpacker, xcffib.Protobj):
178            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
179        xcffib.Error.__init__(self, unpacker)
180        base = unpacker.offset
181        self.bad_value, self.minor_opcode, self.major_opcode = unpacker.unpack("xx2xIHB21x")
182        self.bufsize = unpacker.offset - base
183    def pack(self):
184        buf = six.BytesIO()
185        buf.write(struct.pack("=B", 10))
186        buf.write(struct.pack("=x2xIHB21x", self.bad_value, self.minor_opcode, self.major_opcode))
187        return buf.getvalue()
188BadBadPbuffer = BadPbufferError
189_errors[10] = BadPbufferError
190class BadCurrentDrawableError(xcffib.Error):
191    def __init__(self, unpacker):
192        if isinstance(unpacker, xcffib.Protobj):
193            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
194        xcffib.Error.__init__(self, unpacker)
195        base = unpacker.offset
196        self.bad_value, self.minor_opcode, self.major_opcode = unpacker.unpack("xx2xIHB21x")
197        self.bufsize = unpacker.offset - base
198    def pack(self):
199        buf = six.BytesIO()
200        buf.write(struct.pack("=B", 11))
201        buf.write(struct.pack("=x2xIHB21x", self.bad_value, self.minor_opcode, self.major_opcode))
202        return buf.getvalue()
203BadBadCurrentDrawable = BadCurrentDrawableError
204_errors[11] = BadCurrentDrawableError
205class BadWindowError(xcffib.Error):
206    def __init__(self, unpacker):
207        if isinstance(unpacker, xcffib.Protobj):
208            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
209        xcffib.Error.__init__(self, unpacker)
210        base = unpacker.offset
211        self.bad_value, self.minor_opcode, self.major_opcode = unpacker.unpack("xx2xIHB21x")
212        self.bufsize = unpacker.offset - base
213    def pack(self):
214        buf = six.BytesIO()
215        buf.write(struct.pack("=B", 12))
216        buf.write(struct.pack("=x2xIHB21x", self.bad_value, self.minor_opcode, self.major_opcode))
217        return buf.getvalue()
218BadBadWindow = BadWindowError
219_errors[12] = BadWindowError
220class GLXBadProfileARBError(xcffib.Error):
221    def __init__(self, unpacker):
222        if isinstance(unpacker, xcffib.Protobj):
223            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
224        xcffib.Error.__init__(self, unpacker)
225        base = unpacker.offset
226        self.bad_value, self.minor_opcode, self.major_opcode = unpacker.unpack("xx2xIHB21x")
227        self.bufsize = unpacker.offset - base
228    def pack(self):
229        buf = six.BytesIO()
230        buf.write(struct.pack("=B", 13))
231        buf.write(struct.pack("=x2xIHB21x", self.bad_value, self.minor_opcode, self.major_opcode))
232        return buf.getvalue()
233BadGLXBadProfileARB = GLXBadProfileARBError
234_errors[13] = GLXBadProfileARBError
235class PbufferClobberEvent(xcffib.Event):
236    def __init__(self, unpacker):
237        if isinstance(unpacker, xcffib.Protobj):
238            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
239        xcffib.Event.__init__(self, unpacker)
240        base = unpacker.offset
241        self.event_type, self.draw_type, self.drawable, self.b_mask, self.aux_buffer, self.x, self.y, self.width, self.height, self.count = unpacker.unpack("xx2xHHIIHHHHHH4x")
242        self.bufsize = unpacker.offset - base
243    def pack(self):
244        buf = six.BytesIO()
245        buf.write(struct.pack("=B", 0))
246        buf.write(struct.pack("=x2xHHIIHHHHHH4x", self.event_type, self.draw_type, self.drawable, self.b_mask, self.aux_buffer, self.x, self.y, self.width, self.height, self.count))
247        buf_len = len(buf.getvalue())
248        if buf_len < 32:
249            buf.write(struct.pack("x" * (32 - buf_len)))
250        return buf.getvalue()
251    @classmethod
252    def synthetic(cls, event_type, draw_type, drawable, b_mask, aux_buffer, x, y, width, height, count):
253        self = cls.__new__(cls)
254        self.event_type = event_type
255        self.draw_type = draw_type
256        self.drawable = drawable
257        self.b_mask = b_mask
258        self.aux_buffer = aux_buffer
259        self.x = x
260        self.y = y
261        self.width = width
262        self.height = height
263        self.count = count
264        return self
265_events[0] = PbufferClobberEvent
266class BufferSwapCompleteEvent(xcffib.Event):
267    def __init__(self, unpacker):
268        if isinstance(unpacker, xcffib.Protobj):
269            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
270        xcffib.Event.__init__(self, unpacker)
271        base = unpacker.offset
272        self.event_type, self.drawable, self.ust_hi, self.ust_lo, self.msc_hi, self.msc_lo, self.sbc = unpacker.unpack("xx2xH2xIIIIII")
273        self.bufsize = unpacker.offset - base
274    def pack(self):
275        buf = six.BytesIO()
276        buf.write(struct.pack("=B", 1))
277        buf.write(struct.pack("=x2xH2xIIIIII", self.event_type, self.drawable, self.ust_hi, self.ust_lo, self.msc_hi, self.msc_lo, self.sbc))
278        buf_len = len(buf.getvalue())
279        if buf_len < 32:
280            buf.write(struct.pack("x" * (32 - buf_len)))
281        return buf.getvalue()
282    @classmethod
283    def synthetic(cls, event_type, drawable, ust_hi, ust_lo, msc_hi, msc_lo, sbc):
284        self = cls.__new__(cls)
285        self.event_type = event_type
286        self.drawable = drawable
287        self.ust_hi = ust_hi
288        self.ust_lo = ust_lo
289        self.msc_hi = msc_hi
290        self.msc_lo = msc_lo
291        self.sbc = sbc
292        return self
293_events[1] = BufferSwapCompleteEvent
294class PBCET:
295    Damaged = 32791
296    Saved = 32792
297class PBCDT:
298    Window = 32793
299    Pbuffer = 32794
300class MakeCurrentReply(xcffib.Reply):
301    def __init__(self, unpacker):
302        if isinstance(unpacker, xcffib.Protobj):
303            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
304        xcffib.Reply.__init__(self, unpacker)
305        base = unpacker.offset
306        self.context_tag, = unpacker.unpack("xx2x4xI20x")
307        self.bufsize = unpacker.offset - base
308class MakeCurrentCookie(xcffib.Cookie):
309    reply_type = MakeCurrentReply
310class IsDirectReply(xcffib.Reply):
311    def __init__(self, unpacker):
312        if isinstance(unpacker, xcffib.Protobj):
313            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
314        xcffib.Reply.__init__(self, unpacker)
315        base = unpacker.offset
316        self.is_direct, = unpacker.unpack("xx2x4xB23x")
317        self.bufsize = unpacker.offset - base
318class IsDirectCookie(xcffib.Cookie):
319    reply_type = IsDirectReply
320class QueryVersionReply(xcffib.Reply):
321    def __init__(self, unpacker):
322        if isinstance(unpacker, xcffib.Protobj):
323            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
324        xcffib.Reply.__init__(self, unpacker)
325        base = unpacker.offset
326        self.major_version, self.minor_version = unpacker.unpack("xx2x4xII16x")
327        self.bufsize = unpacker.offset - base
328class QueryVersionCookie(xcffib.Cookie):
329    reply_type = QueryVersionReply
330class GC:
331    GL_CURRENT_BIT = 1 << 0
332    GL_POINT_BIT = 1 << 1
333    GL_LINE_BIT = 1 << 2
334    GL_POLYGON_BIT = 1 << 3
335    GL_POLYGON_STIPPLE_BIT = 1 << 4
336    GL_PIXEL_MODE_BIT = 1 << 5
337    GL_LIGHTING_BIT = 1 << 6
338    GL_FOG_BIT = 1 << 7
339    GL_DEPTH_BUFFER_BIT = 1 << 8
340    GL_ACCUM_BUFFER_BIT = 1 << 9
341    GL_STENCIL_BUFFER_BIT = 1 << 10
342    GL_VIEWPORT_BIT = 1 << 11
343    GL_TRANSFORM_BIT = 1 << 12
344    GL_ENABLE_BIT = 1 << 13
345    GL_COLOR_BUFFER_BIT = 1 << 14
346    GL_HINT_BIT = 1 << 15
347    GL_EVAL_BIT = 1 << 16
348    GL_LIST_BIT = 1 << 17
349    GL_TEXTURE_BIT = 1 << 18
350    GL_SCISSOR_BIT = 1 << 19
351    GL_ALL_ATTRIB_BITS = 16777215
352class GetVisualConfigsReply(xcffib.Reply):
353    def __init__(self, unpacker):
354        if isinstance(unpacker, xcffib.Protobj):
355            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
356        xcffib.Reply.__init__(self, unpacker)
357        base = unpacker.offset
358        self.num_visuals, self.num_properties = unpacker.unpack("xx2x4xII16x")
359        self.property_list = xcffib.List(unpacker, "I", self.length)
360        self.bufsize = unpacker.offset - base
361class GetVisualConfigsCookie(xcffib.Cookie):
362    reply_type = GetVisualConfigsReply
363class VendorPrivateWithReplyReply(xcffib.Reply):
364    def __init__(self, unpacker):
365        if isinstance(unpacker, xcffib.Protobj):
366            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
367        xcffib.Reply.__init__(self, unpacker)
368        base = unpacker.offset
369        self.retval, = unpacker.unpack("xx2x4xI")
370        self.data1 = xcffib.List(unpacker, "B", 24)
371        unpacker.pad("B")
372        self.data2 = xcffib.List(unpacker, "B", self.length * 4)
373        self.bufsize = unpacker.offset - base
374class VendorPrivateWithReplyCookie(xcffib.Cookie):
375    reply_type = VendorPrivateWithReplyReply
376class QueryExtensionsStringReply(xcffib.Reply):
377    def __init__(self, unpacker):
378        if isinstance(unpacker, xcffib.Protobj):
379            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
380        xcffib.Reply.__init__(self, unpacker)
381        base = unpacker.offset
382        self.n, = unpacker.unpack("xx2x4x4xI16x")
383        self.bufsize = unpacker.offset - base
384class QueryExtensionsStringCookie(xcffib.Cookie):
385    reply_type = QueryExtensionsStringReply
386class QueryServerStringReply(xcffib.Reply):
387    def __init__(self, unpacker):
388        if isinstance(unpacker, xcffib.Protobj):
389            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
390        xcffib.Reply.__init__(self, unpacker)
391        base = unpacker.offset
392        self.str_len, = unpacker.unpack("xx2x4x4xI16x")
393        self.string = xcffib.List(unpacker, "c", self.str_len)
394        self.bufsize = unpacker.offset - base
395class QueryServerStringCookie(xcffib.Cookie):
396    reply_type = QueryServerStringReply
397class GetFBConfigsReply(xcffib.Reply):
398    def __init__(self, unpacker):
399        if isinstance(unpacker, xcffib.Protobj):
400            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
401        xcffib.Reply.__init__(self, unpacker)
402        base = unpacker.offset
403        self.num_FB_configs, self.num_properties = unpacker.unpack("xx2x4xII16x")
404        self.property_list = xcffib.List(unpacker, "I", self.length)
405        self.bufsize = unpacker.offset - base
406class GetFBConfigsCookie(xcffib.Cookie):
407    reply_type = GetFBConfigsReply
408class QueryContextReply(xcffib.Reply):
409    def __init__(self, unpacker):
410        if isinstance(unpacker, xcffib.Protobj):
411            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
412        xcffib.Reply.__init__(self, unpacker)
413        base = unpacker.offset
414        self.num_attribs, = unpacker.unpack("xx2x4xI20x")
415        self.attribs = xcffib.List(unpacker, "I", self.num_attribs * 2)
416        self.bufsize = unpacker.offset - base
417class QueryContextCookie(xcffib.Cookie):
418    reply_type = QueryContextReply
419class MakeContextCurrentReply(xcffib.Reply):
420    def __init__(self, unpacker):
421        if isinstance(unpacker, xcffib.Protobj):
422            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
423        xcffib.Reply.__init__(self, unpacker)
424        base = unpacker.offset
425        self.context_tag, = unpacker.unpack("xx2x4xI20x")
426        self.bufsize = unpacker.offset - base
427class MakeContextCurrentCookie(xcffib.Cookie):
428    reply_type = MakeContextCurrentReply
429class GetDrawableAttributesReply(xcffib.Reply):
430    def __init__(self, unpacker):
431        if isinstance(unpacker, xcffib.Protobj):
432            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
433        xcffib.Reply.__init__(self, unpacker)
434        base = unpacker.offset
435        self.num_attribs, = unpacker.unpack("xx2x4xI20x")
436        self.attribs = xcffib.List(unpacker, "I", self.num_attribs * 2)
437        self.bufsize = unpacker.offset - base
438class GetDrawableAttributesCookie(xcffib.Cookie):
439    reply_type = GetDrawableAttributesReply
440class GenListsReply(xcffib.Reply):
441    def __init__(self, unpacker):
442        if isinstance(unpacker, xcffib.Protobj):
443            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
444        xcffib.Reply.__init__(self, unpacker)
445        base = unpacker.offset
446        self.ret_val, = unpacker.unpack("xx2x4xI")
447        self.bufsize = unpacker.offset - base
448class GenListsCookie(xcffib.Cookie):
449    reply_type = GenListsReply
450class RenderModeReply(xcffib.Reply):
451    def __init__(self, unpacker):
452        if isinstance(unpacker, xcffib.Protobj):
453            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
454        xcffib.Reply.__init__(self, unpacker)
455        base = unpacker.offset
456        self.ret_val, self.n, self.new_mode = unpacker.unpack("xx2x4xIII12x")
457        self.data = xcffib.List(unpacker, "I", self.n)
458        self.bufsize = unpacker.offset - base
459class RenderModeCookie(xcffib.Cookie):
460    reply_type = RenderModeReply
461class RM:
462    GL_RENDER = 7168
463    GL_FEEDBACK = 7169
464    GL_SELECT = 7170
465class FinishReply(xcffib.Reply):
466    def __init__(self, unpacker):
467        if isinstance(unpacker, xcffib.Protobj):
468            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
469        xcffib.Reply.__init__(self, unpacker)
470        base = unpacker.offset
471        unpacker.unpack("xx2x4x")
472        self.bufsize = unpacker.offset - base
473class FinishCookie(xcffib.Cookie):
474    reply_type = FinishReply
475class ReadPixelsReply(xcffib.Reply):
476    def __init__(self, unpacker):
477        if isinstance(unpacker, xcffib.Protobj):
478            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
479        xcffib.Reply.__init__(self, unpacker)
480        base = unpacker.offset
481        unpacker.unpack("xx2x4x24x")
482        self.data = xcffib.List(unpacker, "B", self.length * 4)
483        self.bufsize = unpacker.offset - base
484class ReadPixelsCookie(xcffib.Cookie):
485    reply_type = ReadPixelsReply
486class GetBooleanvReply(xcffib.Reply):
487    def __init__(self, unpacker):
488        if isinstance(unpacker, xcffib.Protobj):
489            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
490        xcffib.Reply.__init__(self, unpacker)
491        base = unpacker.offset
492        self.n, self.datum = unpacker.unpack("xx2x4x4xIB15x")
493        self.data = xcffib.List(unpacker, "B", self.n)
494        self.bufsize = unpacker.offset - base
495class GetBooleanvCookie(xcffib.Cookie):
496    reply_type = GetBooleanvReply
497class GetErrorReply(xcffib.Reply):
498    def __init__(self, unpacker):
499        if isinstance(unpacker, xcffib.Protobj):
500            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
501        xcffib.Reply.__init__(self, unpacker)
502        base = unpacker.offset
503        self.error, = unpacker.unpack("xx2x4xi")
504        self.bufsize = unpacker.offset - base
505class GetErrorCookie(xcffib.Cookie):
506    reply_type = GetErrorReply
507class GetFloatvReply(xcffib.Reply):
508    def __init__(self, unpacker):
509        if isinstance(unpacker, xcffib.Protobj):
510            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
511        xcffib.Reply.__init__(self, unpacker)
512        base = unpacker.offset
513        self.n, self.datum = unpacker.unpack("xx2x4x4xIf12x")
514        self.data = xcffib.List(unpacker, "f", self.n)
515        self.bufsize = unpacker.offset - base
516class GetFloatvCookie(xcffib.Cookie):
517    reply_type = GetFloatvReply
518class GetIntegervReply(xcffib.Reply):
519    def __init__(self, unpacker):
520        if isinstance(unpacker, xcffib.Protobj):
521            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
522        xcffib.Reply.__init__(self, unpacker)
523        base = unpacker.offset
524        self.n, self.datum = unpacker.unpack("xx2x4x4xIi12x")
525        self.data = xcffib.List(unpacker, "i", self.n)
526        self.bufsize = unpacker.offset - base
527class GetIntegervCookie(xcffib.Cookie):
528    reply_type = GetIntegervReply
529class GetLightfvReply(xcffib.Reply):
530    def __init__(self, unpacker):
531        if isinstance(unpacker, xcffib.Protobj):
532            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
533        xcffib.Reply.__init__(self, unpacker)
534        base = unpacker.offset
535        self.n, self.datum = unpacker.unpack("xx2x4x4xIf12x")
536        self.data = xcffib.List(unpacker, "f", self.n)
537        self.bufsize = unpacker.offset - base
538class GetLightfvCookie(xcffib.Cookie):
539    reply_type = GetLightfvReply
540class GetLightivReply(xcffib.Reply):
541    def __init__(self, unpacker):
542        if isinstance(unpacker, xcffib.Protobj):
543            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
544        xcffib.Reply.__init__(self, unpacker)
545        base = unpacker.offset
546        self.n, self.datum = unpacker.unpack("xx2x4x4xIi12x")
547        self.data = xcffib.List(unpacker, "i", self.n)
548        self.bufsize = unpacker.offset - base
549class GetLightivCookie(xcffib.Cookie):
550    reply_type = GetLightivReply
551class GetMapfvReply(xcffib.Reply):
552    def __init__(self, unpacker):
553        if isinstance(unpacker, xcffib.Protobj):
554            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
555        xcffib.Reply.__init__(self, unpacker)
556        base = unpacker.offset
557        self.n, self.datum = unpacker.unpack("xx2x4x4xIf12x")
558        self.data = xcffib.List(unpacker, "f", self.n)
559        self.bufsize = unpacker.offset - base
560class GetMapfvCookie(xcffib.Cookie):
561    reply_type = GetMapfvReply
562class GetMapivReply(xcffib.Reply):
563    def __init__(self, unpacker):
564        if isinstance(unpacker, xcffib.Protobj):
565            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
566        xcffib.Reply.__init__(self, unpacker)
567        base = unpacker.offset
568        self.n, self.datum = unpacker.unpack("xx2x4x4xIi12x")
569        self.data = xcffib.List(unpacker, "i", self.n)
570        self.bufsize = unpacker.offset - base
571class GetMapivCookie(xcffib.Cookie):
572    reply_type = GetMapivReply
573class GetMaterialfvReply(xcffib.Reply):
574    def __init__(self, unpacker):
575        if isinstance(unpacker, xcffib.Protobj):
576            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
577        xcffib.Reply.__init__(self, unpacker)
578        base = unpacker.offset
579        self.n, self.datum = unpacker.unpack("xx2x4x4xIf12x")
580        self.data = xcffib.List(unpacker, "f", self.n)
581        self.bufsize = unpacker.offset - base
582class GetMaterialfvCookie(xcffib.Cookie):
583    reply_type = GetMaterialfvReply
584class GetMaterialivReply(xcffib.Reply):
585    def __init__(self, unpacker):
586        if isinstance(unpacker, xcffib.Protobj):
587            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
588        xcffib.Reply.__init__(self, unpacker)
589        base = unpacker.offset
590        self.n, self.datum = unpacker.unpack("xx2x4x4xIi12x")
591        self.data = xcffib.List(unpacker, "i", self.n)
592        self.bufsize = unpacker.offset - base
593class GetMaterialivCookie(xcffib.Cookie):
594    reply_type = GetMaterialivReply
595class GetPixelMapfvReply(xcffib.Reply):
596    def __init__(self, unpacker):
597        if isinstance(unpacker, xcffib.Protobj):
598            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
599        xcffib.Reply.__init__(self, unpacker)
600        base = unpacker.offset
601        self.n, self.datum = unpacker.unpack("xx2x4x4xIf12x")
602        self.data = xcffib.List(unpacker, "f", self.n)
603        self.bufsize = unpacker.offset - base
604class GetPixelMapfvCookie(xcffib.Cookie):
605    reply_type = GetPixelMapfvReply
606class GetPixelMapuivReply(xcffib.Reply):
607    def __init__(self, unpacker):
608        if isinstance(unpacker, xcffib.Protobj):
609            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
610        xcffib.Reply.__init__(self, unpacker)
611        base = unpacker.offset
612        self.n, self.datum = unpacker.unpack("xx2x4x4xII12x")
613        self.data = xcffib.List(unpacker, "I", self.n)
614        self.bufsize = unpacker.offset - base
615class GetPixelMapuivCookie(xcffib.Cookie):
616    reply_type = GetPixelMapuivReply
617class GetPixelMapusvReply(xcffib.Reply):
618    def __init__(self, unpacker):
619        if isinstance(unpacker, xcffib.Protobj):
620            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
621        xcffib.Reply.__init__(self, unpacker)
622        base = unpacker.offset
623        self.n, self.datum = unpacker.unpack("xx2x4x4xIH16x")
624        self.data = xcffib.List(unpacker, "H", self.n)
625        self.bufsize = unpacker.offset - base
626class GetPixelMapusvCookie(xcffib.Cookie):
627    reply_type = GetPixelMapusvReply
628class GetPolygonStippleReply(xcffib.Reply):
629    def __init__(self, unpacker):
630        if isinstance(unpacker, xcffib.Protobj):
631            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
632        xcffib.Reply.__init__(self, unpacker)
633        base = unpacker.offset
634        unpacker.unpack("xx2x4x24x")
635        self.data = xcffib.List(unpacker, "B", self.length * 4)
636        self.bufsize = unpacker.offset - base
637class GetPolygonStippleCookie(xcffib.Cookie):
638    reply_type = GetPolygonStippleReply
639class GetStringReply(xcffib.Reply):
640    def __init__(self, unpacker):
641        if isinstance(unpacker, xcffib.Protobj):
642            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
643        xcffib.Reply.__init__(self, unpacker)
644        base = unpacker.offset
645        self.n, = unpacker.unpack("xx2x4x4xI16x")
646        self.string = xcffib.List(unpacker, "c", self.n)
647        self.bufsize = unpacker.offset - base
648class GetStringCookie(xcffib.Cookie):
649    reply_type = GetStringReply
650class GetTexEnvfvReply(xcffib.Reply):
651    def __init__(self, unpacker):
652        if isinstance(unpacker, xcffib.Protobj):
653            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
654        xcffib.Reply.__init__(self, unpacker)
655        base = unpacker.offset
656        self.n, self.datum = unpacker.unpack("xx2x4x4xIf12x")
657        self.data = xcffib.List(unpacker, "f", self.n)
658        self.bufsize = unpacker.offset - base
659class GetTexEnvfvCookie(xcffib.Cookie):
660    reply_type = GetTexEnvfvReply
661class GetTexEnvivReply(xcffib.Reply):
662    def __init__(self, unpacker):
663        if isinstance(unpacker, xcffib.Protobj):
664            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
665        xcffib.Reply.__init__(self, unpacker)
666        base = unpacker.offset
667        self.n, self.datum = unpacker.unpack("xx2x4x4xIi12x")
668        self.data = xcffib.List(unpacker, "i", self.n)
669        self.bufsize = unpacker.offset - base
670class GetTexEnvivCookie(xcffib.Cookie):
671    reply_type = GetTexEnvivReply
672class GetTexGenfvReply(xcffib.Reply):
673    def __init__(self, unpacker):
674        if isinstance(unpacker, xcffib.Protobj):
675            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
676        xcffib.Reply.__init__(self, unpacker)
677        base = unpacker.offset
678        self.n, self.datum = unpacker.unpack("xx2x4x4xIf12x")
679        self.data = xcffib.List(unpacker, "f", self.n)
680        self.bufsize = unpacker.offset - base
681class GetTexGenfvCookie(xcffib.Cookie):
682    reply_type = GetTexGenfvReply
683class GetTexGenivReply(xcffib.Reply):
684    def __init__(self, unpacker):
685        if isinstance(unpacker, xcffib.Protobj):
686            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
687        xcffib.Reply.__init__(self, unpacker)
688        base = unpacker.offset
689        self.n, self.datum = unpacker.unpack("xx2x4x4xIi12x")
690        self.data = xcffib.List(unpacker, "i", self.n)
691        self.bufsize = unpacker.offset - base
692class GetTexGenivCookie(xcffib.Cookie):
693    reply_type = GetTexGenivReply
694class GetTexImageReply(xcffib.Reply):
695    def __init__(self, unpacker):
696        if isinstance(unpacker, xcffib.Protobj):
697            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
698        xcffib.Reply.__init__(self, unpacker)
699        base = unpacker.offset
700        self.width, self.height, self.depth = unpacker.unpack("xx2x4x8xiii4x")
701        self.data = xcffib.List(unpacker, "B", self.length * 4)
702        self.bufsize = unpacker.offset - base
703class GetTexImageCookie(xcffib.Cookie):
704    reply_type = GetTexImageReply
705class GetTexParameterfvReply(xcffib.Reply):
706    def __init__(self, unpacker):
707        if isinstance(unpacker, xcffib.Protobj):
708            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
709        xcffib.Reply.__init__(self, unpacker)
710        base = unpacker.offset
711        self.n, self.datum = unpacker.unpack("xx2x4x4xIf12x")
712        self.data = xcffib.List(unpacker, "f", self.n)
713        self.bufsize = unpacker.offset - base
714class GetTexParameterfvCookie(xcffib.Cookie):
715    reply_type = GetTexParameterfvReply
716class GetTexParameterivReply(xcffib.Reply):
717    def __init__(self, unpacker):
718        if isinstance(unpacker, xcffib.Protobj):
719            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
720        xcffib.Reply.__init__(self, unpacker)
721        base = unpacker.offset
722        self.n, self.datum = unpacker.unpack("xx2x4x4xIi12x")
723        self.data = xcffib.List(unpacker, "i", self.n)
724        self.bufsize = unpacker.offset - base
725class GetTexParameterivCookie(xcffib.Cookie):
726    reply_type = GetTexParameterivReply
727class GetTexLevelParameterfvReply(xcffib.Reply):
728    def __init__(self, unpacker):
729        if isinstance(unpacker, xcffib.Protobj):
730            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
731        xcffib.Reply.__init__(self, unpacker)
732        base = unpacker.offset
733        self.n, self.datum = unpacker.unpack("xx2x4x4xIf12x")
734        self.data = xcffib.List(unpacker, "f", self.n)
735        self.bufsize = unpacker.offset - base
736class GetTexLevelParameterfvCookie(xcffib.Cookie):
737    reply_type = GetTexLevelParameterfvReply
738class GetTexLevelParameterivReply(xcffib.Reply):
739    def __init__(self, unpacker):
740        if isinstance(unpacker, xcffib.Protobj):
741            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
742        xcffib.Reply.__init__(self, unpacker)
743        base = unpacker.offset
744        self.n, self.datum = unpacker.unpack("xx2x4x4xIi12x")
745        self.data = xcffib.List(unpacker, "i", self.n)
746        self.bufsize = unpacker.offset - base
747class GetTexLevelParameterivCookie(xcffib.Cookie):
748    reply_type = GetTexLevelParameterivReply
749class IsEnabledReply(xcffib.Reply):
750    def __init__(self, unpacker):
751        if isinstance(unpacker, xcffib.Protobj):
752            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
753        xcffib.Reply.__init__(self, unpacker)
754        base = unpacker.offset
755        self.ret_val, = unpacker.unpack("xx2x4xI")
756        self.bufsize = unpacker.offset - base
757class IsEnabledCookie(xcffib.Cookie):
758    reply_type = IsEnabledReply
759class IsListReply(xcffib.Reply):
760    def __init__(self, unpacker):
761        if isinstance(unpacker, xcffib.Protobj):
762            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
763        xcffib.Reply.__init__(self, unpacker)
764        base = unpacker.offset
765        self.ret_val, = unpacker.unpack("xx2x4xI")
766        self.bufsize = unpacker.offset - base
767class IsListCookie(xcffib.Cookie):
768    reply_type = IsListReply
769class AreTexturesResidentReply(xcffib.Reply):
770    def __init__(self, unpacker):
771        if isinstance(unpacker, xcffib.Protobj):
772            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
773        xcffib.Reply.__init__(self, unpacker)
774        base = unpacker.offset
775        self.ret_val, = unpacker.unpack("xx2x4xI20x")
776        self.data = xcffib.List(unpacker, "B", self.length * 4)
777        self.bufsize = unpacker.offset - base
778class AreTexturesResidentCookie(xcffib.Cookie):
779    reply_type = AreTexturesResidentReply
780class GenTexturesReply(xcffib.Reply):
781    def __init__(self, unpacker):
782        if isinstance(unpacker, xcffib.Protobj):
783            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
784        xcffib.Reply.__init__(self, unpacker)
785        base = unpacker.offset
786        unpacker.unpack("xx2x4x24x")
787        self.data = xcffib.List(unpacker, "I", self.length)
788        self.bufsize = unpacker.offset - base
789class GenTexturesCookie(xcffib.Cookie):
790    reply_type = GenTexturesReply
791class IsTextureReply(xcffib.Reply):
792    def __init__(self, unpacker):
793        if isinstance(unpacker, xcffib.Protobj):
794            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
795        xcffib.Reply.__init__(self, unpacker)
796        base = unpacker.offset
797        self.ret_val, = unpacker.unpack("xx2x4xI")
798        self.bufsize = unpacker.offset - base
799class IsTextureCookie(xcffib.Cookie):
800    reply_type = IsTextureReply
801class GetColorTableReply(xcffib.Reply):
802    def __init__(self, unpacker):
803        if isinstance(unpacker, xcffib.Protobj):
804            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
805        xcffib.Reply.__init__(self, unpacker)
806        base = unpacker.offset
807        self.width, = unpacker.unpack("xx2x4x8xi12x")
808        self.data = xcffib.List(unpacker, "B", self.length * 4)
809        self.bufsize = unpacker.offset - base
810class GetColorTableCookie(xcffib.Cookie):
811    reply_type = GetColorTableReply
812class GetColorTableParameterfvReply(xcffib.Reply):
813    def __init__(self, unpacker):
814        if isinstance(unpacker, xcffib.Protobj):
815            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
816        xcffib.Reply.__init__(self, unpacker)
817        base = unpacker.offset
818        self.n, self.datum = unpacker.unpack("xx2x4x4xIf12x")
819        self.data = xcffib.List(unpacker, "f", self.n)
820        self.bufsize = unpacker.offset - base
821class GetColorTableParameterfvCookie(xcffib.Cookie):
822    reply_type = GetColorTableParameterfvReply
823class GetColorTableParameterivReply(xcffib.Reply):
824    def __init__(self, unpacker):
825        if isinstance(unpacker, xcffib.Protobj):
826            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
827        xcffib.Reply.__init__(self, unpacker)
828        base = unpacker.offset
829        self.n, self.datum = unpacker.unpack("xx2x4x4xIi12x")
830        self.data = xcffib.List(unpacker, "i", self.n)
831        self.bufsize = unpacker.offset - base
832class GetColorTableParameterivCookie(xcffib.Cookie):
833    reply_type = GetColorTableParameterivReply
834class GetConvolutionFilterReply(xcffib.Reply):
835    def __init__(self, unpacker):
836        if isinstance(unpacker, xcffib.Protobj):
837            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
838        xcffib.Reply.__init__(self, unpacker)
839        base = unpacker.offset
840        self.width, self.height = unpacker.unpack("xx2x4x8xii8x")
841        self.data = xcffib.List(unpacker, "B", self.length * 4)
842        self.bufsize = unpacker.offset - base
843class GetConvolutionFilterCookie(xcffib.Cookie):
844    reply_type = GetConvolutionFilterReply
845class GetConvolutionParameterfvReply(xcffib.Reply):
846    def __init__(self, unpacker):
847        if isinstance(unpacker, xcffib.Protobj):
848            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
849        xcffib.Reply.__init__(self, unpacker)
850        base = unpacker.offset
851        self.n, self.datum = unpacker.unpack("xx2x4x4xIf12x")
852        self.data = xcffib.List(unpacker, "f", self.n)
853        self.bufsize = unpacker.offset - base
854class GetConvolutionParameterfvCookie(xcffib.Cookie):
855    reply_type = GetConvolutionParameterfvReply
856class GetConvolutionParameterivReply(xcffib.Reply):
857    def __init__(self, unpacker):
858        if isinstance(unpacker, xcffib.Protobj):
859            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
860        xcffib.Reply.__init__(self, unpacker)
861        base = unpacker.offset
862        self.n, self.datum = unpacker.unpack("xx2x4x4xIi12x")
863        self.data = xcffib.List(unpacker, "i", self.n)
864        self.bufsize = unpacker.offset - base
865class GetConvolutionParameterivCookie(xcffib.Cookie):
866    reply_type = GetConvolutionParameterivReply
867class GetSeparableFilterReply(xcffib.Reply):
868    def __init__(self, unpacker):
869        if isinstance(unpacker, xcffib.Protobj):
870            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
871        xcffib.Reply.__init__(self, unpacker)
872        base = unpacker.offset
873        self.row_w, self.col_h = unpacker.unpack("xx2x4x8xii8x")
874        self.rows_and_cols = xcffib.List(unpacker, "B", self.length * 4)
875        self.bufsize = unpacker.offset - base
876class GetSeparableFilterCookie(xcffib.Cookie):
877    reply_type = GetSeparableFilterReply
878class GetHistogramReply(xcffib.Reply):
879    def __init__(self, unpacker):
880        if isinstance(unpacker, xcffib.Protobj):
881            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
882        xcffib.Reply.__init__(self, unpacker)
883        base = unpacker.offset
884        self.width, = unpacker.unpack("xx2x4x8xi12x")
885        self.data = xcffib.List(unpacker, "B", self.length * 4)
886        self.bufsize = unpacker.offset - base
887class GetHistogramCookie(xcffib.Cookie):
888    reply_type = GetHistogramReply
889class GetHistogramParameterfvReply(xcffib.Reply):
890    def __init__(self, unpacker):
891        if isinstance(unpacker, xcffib.Protobj):
892            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
893        xcffib.Reply.__init__(self, unpacker)
894        base = unpacker.offset
895        self.n, self.datum = unpacker.unpack("xx2x4x4xIf12x")
896        self.data = xcffib.List(unpacker, "f", self.n)
897        self.bufsize = unpacker.offset - base
898class GetHistogramParameterfvCookie(xcffib.Cookie):
899    reply_type = GetHistogramParameterfvReply
900class GetHistogramParameterivReply(xcffib.Reply):
901    def __init__(self, unpacker):
902        if isinstance(unpacker, xcffib.Protobj):
903            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
904        xcffib.Reply.__init__(self, unpacker)
905        base = unpacker.offset
906        self.n, self.datum = unpacker.unpack("xx2x4x4xIi12x")
907        self.data = xcffib.List(unpacker, "i", self.n)
908        self.bufsize = unpacker.offset - base
909class GetHistogramParameterivCookie(xcffib.Cookie):
910    reply_type = GetHistogramParameterivReply
911class GetMinmaxReply(xcffib.Reply):
912    def __init__(self, unpacker):
913        if isinstance(unpacker, xcffib.Protobj):
914            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
915        xcffib.Reply.__init__(self, unpacker)
916        base = unpacker.offset
917        unpacker.unpack("xx2x4x24x")
918        self.data = xcffib.List(unpacker, "B", self.length * 4)
919        self.bufsize = unpacker.offset - base
920class GetMinmaxCookie(xcffib.Cookie):
921    reply_type = GetMinmaxReply
922class GetMinmaxParameterfvReply(xcffib.Reply):
923    def __init__(self, unpacker):
924        if isinstance(unpacker, xcffib.Protobj):
925            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
926        xcffib.Reply.__init__(self, unpacker)
927        base = unpacker.offset
928        self.n, self.datum = unpacker.unpack("xx2x4x4xIf12x")
929        self.data = xcffib.List(unpacker, "f", self.n)
930        self.bufsize = unpacker.offset - base
931class GetMinmaxParameterfvCookie(xcffib.Cookie):
932    reply_type = GetMinmaxParameterfvReply
933class GetMinmaxParameterivReply(xcffib.Reply):
934    def __init__(self, unpacker):
935        if isinstance(unpacker, xcffib.Protobj):
936            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
937        xcffib.Reply.__init__(self, unpacker)
938        base = unpacker.offset
939        self.n, self.datum = unpacker.unpack("xx2x4x4xIi12x")
940        self.data = xcffib.List(unpacker, "i", self.n)
941        self.bufsize = unpacker.offset - base
942class GetMinmaxParameterivCookie(xcffib.Cookie):
943    reply_type = GetMinmaxParameterivReply
944class GetCompressedTexImageARBReply(xcffib.Reply):
945    def __init__(self, unpacker):
946        if isinstance(unpacker, xcffib.Protobj):
947            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
948        xcffib.Reply.__init__(self, unpacker)
949        base = unpacker.offset
950        self.size, = unpacker.unpack("xx2x4x8xi12x")
951        self.data = xcffib.List(unpacker, "B", self.length * 4)
952        self.bufsize = unpacker.offset - base
953class GetCompressedTexImageARBCookie(xcffib.Cookie):
954    reply_type = GetCompressedTexImageARBReply
955class GenQueriesARBReply(xcffib.Reply):
956    def __init__(self, unpacker):
957        if isinstance(unpacker, xcffib.Protobj):
958            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
959        xcffib.Reply.__init__(self, unpacker)
960        base = unpacker.offset
961        unpacker.unpack("xx2x4x24x")
962        self.data = xcffib.List(unpacker, "I", self.length)
963        self.bufsize = unpacker.offset - base
964class GenQueriesARBCookie(xcffib.Cookie):
965    reply_type = GenQueriesARBReply
966class IsQueryARBReply(xcffib.Reply):
967    def __init__(self, unpacker):
968        if isinstance(unpacker, xcffib.Protobj):
969            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
970        xcffib.Reply.__init__(self, unpacker)
971        base = unpacker.offset
972        self.ret_val, = unpacker.unpack("xx2x4xI")
973        self.bufsize = unpacker.offset - base
974class IsQueryARBCookie(xcffib.Cookie):
975    reply_type = IsQueryARBReply
976class GetQueryivARBReply(xcffib.Reply):
977    def __init__(self, unpacker):
978        if isinstance(unpacker, xcffib.Protobj):
979            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
980        xcffib.Reply.__init__(self, unpacker)
981        base = unpacker.offset
982        self.n, self.datum = unpacker.unpack("xx2x4x4xIi12x")
983        self.data = xcffib.List(unpacker, "i", self.n)
984        self.bufsize = unpacker.offset - base
985class GetQueryivARBCookie(xcffib.Cookie):
986    reply_type = GetQueryivARBReply
987class GetQueryObjectivARBReply(xcffib.Reply):
988    def __init__(self, unpacker):
989        if isinstance(unpacker, xcffib.Protobj):
990            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
991        xcffib.Reply.__init__(self, unpacker)
992        base = unpacker.offset
993        self.n, self.datum = unpacker.unpack("xx2x4x4xIi12x")
994        self.data = xcffib.List(unpacker, "i", self.n)
995        self.bufsize = unpacker.offset - base
996class GetQueryObjectivARBCookie(xcffib.Cookie):
997    reply_type = GetQueryObjectivARBReply
998class GetQueryObjectuivARBReply(xcffib.Reply):
999    def __init__(self, unpacker):
1000        if isinstance(unpacker, xcffib.Protobj):
1001            unpacker = xcffib.MemoryUnpacker(unpacker.pack())
1002        xcffib.Reply.__init__(self, unpacker)
1003        base = unpacker.offset
1004        self.n, self.datum = unpacker.unpack("xx2x4x4xII12x")
1005        self.data = xcffib.List(unpacker, "I", self.n)
1006        self.bufsize = unpacker.offset - base
1007class GetQueryObjectuivARBCookie(xcffib.Cookie):
1008    reply_type = GetQueryObjectuivARBReply
1009class glxExtension(xcffib.Extension):
1010    def Render(self, context_tag, data_len, data, is_checked=False):
1011        buf = six.BytesIO()
1012        buf.write(struct.pack("=xx2xI", context_tag))
1013        buf.write(xcffib.pack_list(data, "B"))
1014        return self.send_request(1, buf, is_checked=is_checked)
1015    def RenderLarge(self, context_tag, request_num, request_total, data_len, data, is_checked=False):
1016        buf = six.BytesIO()
1017        buf.write(struct.pack("=xx2xIHHI", context_tag, request_num, request_total, data_len))
1018        buf.write(xcffib.pack_list(data, "B"))
1019        return self.send_request(2, buf, is_checked=is_checked)
1020    def CreateContext(self, context, visual, screen, share_list, is_direct, is_checked=False):
1021        buf = six.BytesIO()
1022        buf.write(struct.pack("=xx2xIIIIB3x", context, visual, screen, share_list, is_direct))
1023        return self.send_request(3, buf, is_checked=is_checked)
1024    def DestroyContext(self, context, is_checked=False):
1025        buf = six.BytesIO()
1026        buf.write(struct.pack("=xx2xI", context))
1027        return self.send_request(4, buf, is_checked=is_checked)
1028    def MakeCurrent(self, drawable, context, old_context_tag, is_checked=True):
1029        buf = six.BytesIO()
1030        buf.write(struct.pack("=xx2xIII", drawable, context, old_context_tag))
1031        return self.send_request(5, buf, MakeCurrentCookie, is_checked=is_checked)
1032    def IsDirect(self, context, is_checked=True):
1033        buf = six.BytesIO()
1034        buf.write(struct.pack("=xx2xI", context))
1035        return self.send_request(6, buf, IsDirectCookie, is_checked=is_checked)
1036    def QueryVersion(self, major_version, minor_version, is_checked=True):
1037        buf = six.BytesIO()
1038        buf.write(struct.pack("=xx2xII", major_version, minor_version))
1039        return self.send_request(7, buf, QueryVersionCookie, is_checked=is_checked)
1040    def WaitGL(self, context_tag, is_checked=False):
1041        buf = six.BytesIO()
1042        buf.write(struct.pack("=xx2xI", context_tag))
1043        return self.send_request(8, buf, is_checked=is_checked)
1044    def WaitX(self, context_tag, is_checked=False):
1045        buf = six.BytesIO()
1046        buf.write(struct.pack("=xx2xI", context_tag))
1047        return self.send_request(9, buf, is_checked=is_checked)
1048    def CopyContext(self, src, dest, mask, src_context_tag, is_checked=False):
1049        buf = six.BytesIO()
1050        buf.write(struct.pack("=xx2xIIII", src, dest, mask, src_context_tag))
1051        return self.send_request(10, buf, is_checked=is_checked)
1052    def SwapBuffers(self, context_tag, drawable, is_checked=False):
1053        buf = six.BytesIO()
1054        buf.write(struct.pack("=xx2xII", context_tag, drawable))
1055        return self.send_request(11, buf, is_checked=is_checked)
1056    def UseXFont(self, context_tag, font, first, count, list_base, is_checked=False):
1057        buf = six.BytesIO()
1058        buf.write(struct.pack("=xx2xIIIII", context_tag, font, first, count, list_base))
1059        return self.send_request(12, buf, is_checked=is_checked)
1060    def CreateGLXPixmap(self, screen, visual, pixmap, glx_pixmap, is_checked=False):
1061        buf = six.BytesIO()
1062        buf.write(struct.pack("=xx2xIIII", screen, visual, pixmap, glx_pixmap))
1063        return self.send_request(13, buf, is_checked=is_checked)
1064    def GetVisualConfigs(self, screen, is_checked=True):
1065        buf = six.BytesIO()
1066        buf.write(struct.pack("=xx2xI", screen))
1067        return self.send_request(14, buf, GetVisualConfigsCookie, is_checked=is_checked)
1068    def DestroyGLXPixmap(self, glx_pixmap, is_checked=False):
1069        buf = six.BytesIO()
1070        buf.write(struct.pack("=xx2xI", glx_pixmap))
1071        return self.send_request(15, buf, is_checked=is_checked)
1072    def VendorPrivate(self, vendor_code, context_tag, data_len, data, is_checked=False):
1073        buf = six.BytesIO()
1074        buf.write(struct.pack("=xx2xII", vendor_code, context_tag))
1075        buf.write(xcffib.pack_list(data, "B"))
1076        return self.send_request(16, buf, is_checked=is_checked)
1077    def VendorPrivateWithReply(self, vendor_code, context_tag, data_len, data, is_checked=True):
1078        buf = six.BytesIO()
1079        buf.write(struct.pack("=xx2xII", vendor_code, context_tag))
1080        buf.write(xcffib.pack_list(data, "B"))
1081        return self.send_request(17, buf, VendorPrivateWithReplyCookie, is_checked=is_checked)
1082    def QueryExtensionsString(self, screen, is_checked=True):
1083        buf = six.BytesIO()
1084        buf.write(struct.pack("=xx2xI", screen))
1085        return self.send_request(18, buf, QueryExtensionsStringCookie, is_checked=is_checked)
1086    def QueryServerString(self, screen, name, is_checked=True):
1087        buf = six.BytesIO()
1088        buf.write(struct.pack("=xx2xII", screen, name))
1089        return self.send_request(19, buf, QueryServerStringCookie, is_checked=is_checked)
1090    def ClientInfo(self, major_version, minor_version, str_len, string, is_checked=False):
1091        buf = six.BytesIO()
1092        buf.write(struct.pack("=xx2xIII", major_version, minor_version, str_len))
1093        buf.write(xcffib.pack_list(string, "c"))
1094        return self.send_request(20, buf, is_checked=is_checked)
1095    def GetFBConfigs(self, screen, is_checked=True):
1096        buf = six.BytesIO()
1097        buf.write(struct.pack("=xx2xI", screen))
1098        return self.send_request(21, buf, GetFBConfigsCookie, is_checked=is_checked)
1099    def CreatePixmap(self, screen, fbconfig, pixmap, glx_pixmap, num_attribs, attribs, is_checked=False):
1100        buf = six.BytesIO()
1101        buf.write(struct.pack("=xx2xIIIII", screen, fbconfig, pixmap, glx_pixmap, num_attribs))
1102        buf.write(xcffib.pack_list(attribs, "I"))
1103        return self.send_request(22, buf, is_checked=is_checked)
1104    def DestroyPixmap(self, glx_pixmap, is_checked=False):
1105        buf = six.BytesIO()
1106        buf.write(struct.pack("=xx2xI", glx_pixmap))
1107        return self.send_request(23, buf, is_checked=is_checked)
1108    def CreateNewContext(self, context, fbconfig, screen, render_type, share_list, is_direct, is_checked=False):
1109        buf = six.BytesIO()
1110        buf.write(struct.pack("=xx2xIIIIIB3x", context, fbconfig, screen, render_type, share_list, is_direct))
1111        return self.send_request(24, buf, is_checked=is_checked)
1112    def QueryContext(self, context, is_checked=True):
1113        buf = six.BytesIO()
1114        buf.write(struct.pack("=xx2xI", context))
1115        return self.send_request(25, buf, QueryContextCookie, is_checked=is_checked)
1116    def MakeContextCurrent(self, old_context_tag, drawable, read_drawable, context, is_checked=True):
1117        buf = six.BytesIO()
1118        buf.write(struct.pack("=xx2xIIII", old_context_tag, drawable, read_drawable, context))
1119        return self.send_request(26, buf, MakeContextCurrentCookie, is_checked=is_checked)
1120    def CreatePbuffer(self, screen, fbconfig, pbuffer, num_attribs, attribs, is_checked=False):
1121        buf = six.BytesIO()
1122        buf.write(struct.pack("=xx2xIIII", screen, fbconfig, pbuffer, num_attribs))
1123        buf.write(xcffib.pack_list(attribs, "I"))
1124        return self.send_request(27, buf, is_checked=is_checked)
1125    def DestroyPbuffer(self, pbuffer, is_checked=False):
1126        buf = six.BytesIO()
1127        buf.write(struct.pack("=xx2xI", pbuffer))
1128        return self.send_request(28, buf, is_checked=is_checked)
1129    def GetDrawableAttributes(self, drawable, is_checked=True):
1130        buf = six.BytesIO()
1131        buf.write(struct.pack("=xx2xI", drawable))
1132        return self.send_request(29, buf, GetDrawableAttributesCookie, is_checked=is_checked)
1133    def ChangeDrawableAttributes(self, drawable, num_attribs, attribs, is_checked=False):
1134        buf = six.BytesIO()
1135        buf.write(struct.pack("=xx2xII", drawable, num_attribs))
1136        buf.write(xcffib.pack_list(attribs, "I"))
1137        return self.send_request(30, buf, is_checked=is_checked)
1138    def CreateWindow(self, screen, fbconfig, window, glx_window, num_attribs, attribs, is_checked=False):
1139        buf = six.BytesIO()
1140        buf.write(struct.pack("=xx2xIIIII", screen, fbconfig, window, glx_window, num_attribs))
1141        buf.write(xcffib.pack_list(attribs, "I"))
1142        return self.send_request(31, buf, is_checked=is_checked)
1143    def DeleteWindow(self, glxwindow, is_checked=False):
1144        buf = six.BytesIO()
1145        buf.write(struct.pack("=xx2xI", glxwindow))
1146        return self.send_request(32, buf, is_checked=is_checked)
1147    def SetClientInfoARB(self, major_version, minor_version, num_versions, gl_str_len, glx_str_len, gl_versions, gl_extension_string, glx_extension_string, is_checked=False):
1148        buf = six.BytesIO()
1149        buf.write(struct.pack("=xx2xIIIII", major_version, minor_version, num_versions, gl_str_len, glx_str_len))
1150        buf.write(xcffib.pack_list(gl_versions, "I"))
1151        buf.write(xcffib.pack_list(gl_extension_string, "c"))
1152        buf.write(xcffib.pack_list(glx_extension_string, "c"))
1153        return self.send_request(33, buf, is_checked=is_checked)
1154    def CreateContextAttribsARB(self, context, fbconfig, screen, share_list, is_direct, num_attribs, attribs, is_checked=False):
1155        buf = six.BytesIO()
1156        buf.write(struct.pack("=xx2xIIIIB3xI", context, fbconfig, screen, share_list, is_direct, num_attribs))
1157        buf.write(xcffib.pack_list(attribs, "I"))
1158        return self.send_request(34, buf, is_checked=is_checked)
1159    def SetClientInfo2ARB(self, major_version, minor_version, num_versions, gl_str_len, glx_str_len, gl_versions, gl_extension_string, glx_extension_string, is_checked=False):
1160        buf = six.BytesIO()
1161        buf.write(struct.pack("=xx2xIIIII", major_version, minor_version, num_versions, gl_str_len, glx_str_len))
1162        buf.write(xcffib.pack_list(gl_versions, "I"))
1163        buf.write(xcffib.pack_list(gl_extension_string, "c"))
1164        buf.write(xcffib.pack_list(glx_extension_string, "c"))
1165        return self.send_request(35, buf, is_checked=is_checked)
1166    def NewList(self, context_tag, list, mode, is_checked=False):
1167        buf = six.BytesIO()
1168        buf.write(struct.pack("=xx2xIII", context_tag, list, mode))
1169        return self.send_request(101, buf, is_checked=is_checked)
1170    def EndList(self, context_tag, is_checked=False):
1171        buf = six.BytesIO()
1172        buf.write(struct.pack("=xx2xI", context_tag))
1173        return self.send_request(102, buf, is_checked=is_checked)
1174    def DeleteLists(self, context_tag, list, range, is_checked=False):
1175        buf = six.BytesIO()
1176        buf.write(struct.pack("=xx2xIIi", context_tag, list, range))
1177        return self.send_request(103, buf, is_checked=is_checked)
1178    def GenLists(self, context_tag, range, is_checked=True):
1179        buf = six.BytesIO()
1180        buf.write(struct.pack("=xx2xIi", context_tag, range))
1181        return self.send_request(104, buf, GenListsCookie, is_checked=is_checked)
1182    def FeedbackBuffer(self, context_tag, size, type, is_checked=False):
1183        buf = six.BytesIO()
1184        buf.write(struct.pack("=xx2xIii", context_tag, size, type))
1185        return self.send_request(105, buf, is_checked=is_checked)
1186    def SelectBuffer(self, context_tag, size, is_checked=False):
1187        buf = six.BytesIO()
1188        buf.write(struct.pack("=xx2xIi", context_tag, size))
1189        return self.send_request(106, buf, is_checked=is_checked)
1190    def RenderMode(self, context_tag, mode, is_checked=True):
1191        buf = six.BytesIO()
1192        buf.write(struct.pack("=xx2xII", context_tag, mode))
1193        return self.send_request(107, buf, RenderModeCookie, is_checked=is_checked)
1194    def Finish(self, context_tag, is_checked=True):
1195        buf = six.BytesIO()
1196        buf.write(struct.pack("=xx2xI", context_tag))
1197        return self.send_request(108, buf, FinishCookie, is_checked=is_checked)
1198    def PixelStoref(self, context_tag, pname, datum, is_checked=False):
1199        buf = six.BytesIO()
1200        buf.write(struct.pack("=xx2xIIf", context_tag, pname, datum))
1201        return self.send_request(109, buf, is_checked=is_checked)
1202    def PixelStorei(self, context_tag, pname, datum, is_checked=False):
1203        buf = six.BytesIO()
1204        buf.write(struct.pack("=xx2xIIi", context_tag, pname, datum))
1205        return self.send_request(110, buf, is_checked=is_checked)
1206    def ReadPixels(self, context_tag, x, y, width, height, format, type, swap_bytes, lsb_first, is_checked=True):
1207        buf = six.BytesIO()
1208        buf.write(struct.pack("=xx2xIiiiiIIBB", context_tag, x, y, width, height, format, type, swap_bytes, lsb_first))
1209        return self.send_request(111, buf, ReadPixelsCookie, is_checked=is_checked)
1210    def GetBooleanv(self, context_tag, pname, is_checked=True):
1211        buf = six.BytesIO()
1212        buf.write(struct.pack("=xx2xIi", context_tag, pname))
1213        return self.send_request(112, buf, GetBooleanvCookie, is_checked=is_checked)
1214    def GetClipPlane(self, context_tag, plane, is_checked=False):
1215        buf = six.BytesIO()
1216        buf.write(struct.pack("=xx2xIi", context_tag, plane))
1217        return self.send_request(113, buf, is_checked=is_checked)
1218    def GetDoublev(self, context_tag, pname, is_checked=False):
1219        buf = six.BytesIO()
1220        buf.write(struct.pack("=xx2xII", context_tag, pname))
1221        return self.send_request(114, buf, is_checked=is_checked)
1222    def GetError(self, context_tag, is_checked=True):
1223        buf = six.BytesIO()
1224        buf.write(struct.pack("=xx2xI", context_tag))
1225        return self.send_request(115, buf, GetErrorCookie, is_checked=is_checked)
1226    def GetFloatv(self, context_tag, pname, is_checked=True):
1227        buf = six.BytesIO()
1228        buf.write(struct.pack("=xx2xII", context_tag, pname))
1229        return self.send_request(116, buf, GetFloatvCookie, is_checked=is_checked)
1230    def GetIntegerv(self, context_tag, pname, is_checked=True):
1231        buf = six.BytesIO()
1232        buf.write(struct.pack("=xx2xII", context_tag, pname))
1233        return self.send_request(117, buf, GetIntegervCookie, is_checked=is_checked)
1234    def GetLightfv(self, context_tag, light, pname, is_checked=True):
1235        buf = six.BytesIO()
1236        buf.write(struct.pack("=xx2xIII", context_tag, light, pname))
1237        return self.send_request(118, buf, GetLightfvCookie, is_checked=is_checked)
1238    def GetLightiv(self, context_tag, light, pname, is_checked=True):
1239        buf = six.BytesIO()
1240        buf.write(struct.pack("=xx2xIII", context_tag, light, pname))
1241        return self.send_request(119, buf, GetLightivCookie, is_checked=is_checked)
1242    def GetMapdv(self, context_tag, target, query, is_checked=False):
1243        buf = six.BytesIO()
1244        buf.write(struct.pack("=xx2xIII", context_tag, target, query))
1245        return self.send_request(120, buf, is_checked=is_checked)
1246    def GetMapfv(self, context_tag, target, query, is_checked=True):
1247        buf = six.BytesIO()
1248        buf.write(struct.pack("=xx2xIII", context_tag, target, query))
1249        return self.send_request(121, buf, GetMapfvCookie, is_checked=is_checked)
1250    def GetMapiv(self, context_tag, target, query, is_checked=True):
1251        buf = six.BytesIO()
1252        buf.write(struct.pack("=xx2xIII", context_tag, target, query))
1253        return self.send_request(122, buf, GetMapivCookie, is_checked=is_checked)
1254    def GetMaterialfv(self, context_tag, face, pname, is_checked=True):
1255        buf = six.BytesIO()
1256        buf.write(struct.pack("=xx2xIII", context_tag, face, pname))
1257        return self.send_request(123, buf, GetMaterialfvCookie, is_checked=is_checked)
1258    def GetMaterialiv(self, context_tag, face, pname, is_checked=True):
1259        buf = six.BytesIO()
1260        buf.write(struct.pack("=xx2xIII", context_tag, face, pname))
1261        return self.send_request(124, buf, GetMaterialivCookie, is_checked=is_checked)
1262    def GetPixelMapfv(self, context_tag, map, is_checked=True):
1263        buf = six.BytesIO()
1264        buf.write(struct.pack("=xx2xII", context_tag, map))
1265        return self.send_request(125, buf, GetPixelMapfvCookie, is_checked=is_checked)
1266    def GetPixelMapuiv(self, context_tag, map, is_checked=True):
1267        buf = six.BytesIO()
1268        buf.write(struct.pack("=xx2xII", context_tag, map))
1269        return self.send_request(126, buf, GetPixelMapuivCookie, is_checked=is_checked)
1270    def GetPixelMapusv(self, context_tag, map, is_checked=True):
1271        buf = six.BytesIO()
1272        buf.write(struct.pack("=xx2xII", context_tag, map))
1273        return self.send_request(127, buf, GetPixelMapusvCookie, is_checked=is_checked)
1274    def GetPolygonStipple(self, context_tag, lsb_first, is_checked=True):
1275        buf = six.BytesIO()
1276        buf.write(struct.pack("=xx2xIB", context_tag, lsb_first))
1277        return self.send_request(128, buf, GetPolygonStippleCookie, is_checked=is_checked)
1278    def GetString(self, context_tag, name, is_checked=True):
1279        buf = six.BytesIO()
1280        buf.write(struct.pack("=xx2xII", context_tag, name))
1281        return self.send_request(129, buf, GetStringCookie, is_checked=is_checked)
1282    def GetTexEnvfv(self, context_tag, target, pname, is_checked=True):
1283        buf = six.BytesIO()
1284        buf.write(struct.pack("=xx2xIII", context_tag, target, pname))
1285        return self.send_request(130, buf, GetTexEnvfvCookie, is_checked=is_checked)
1286    def GetTexEnviv(self, context_tag, target, pname, is_checked=True):
1287        buf = six.BytesIO()
1288        buf.write(struct.pack("=xx2xIII", context_tag, target, pname))
1289        return self.send_request(131, buf, GetTexEnvivCookie, is_checked=is_checked)
1290    def GetTexGendv(self, context_tag, coord, pname, is_checked=False):
1291        buf = six.BytesIO()
1292        buf.write(struct.pack("=xx2xIII", context_tag, coord, pname))
1293        return self.send_request(132, buf, is_checked=is_checked)
1294    def GetTexGenfv(self, context_tag, coord, pname, is_checked=True):
1295        buf = six.BytesIO()
1296        buf.write(struct.pack("=xx2xIII", context_tag, coord, pname))
1297        return self.send_request(133, buf, GetTexGenfvCookie, is_checked=is_checked)
1298    def GetTexGeniv(self, context_tag, coord, pname, is_checked=True):
1299        buf = six.BytesIO()
1300        buf.write(struct.pack("=xx2xIII", context_tag, coord, pname))
1301        return self.send_request(134, buf, GetTexGenivCookie, is_checked=is_checked)
1302    def GetTexImage(self, context_tag, target, level, format, type, swap_bytes, is_checked=True):
1303        buf = six.BytesIO()
1304        buf.write(struct.pack("=xx2xIIiIIB", context_tag, target, level, format, type, swap_bytes))
1305        return self.send_request(135, buf, GetTexImageCookie, is_checked=is_checked)
1306    def GetTexParameterfv(self, context_tag, target, pname, is_checked=True):
1307        buf = six.BytesIO()
1308        buf.write(struct.pack("=xx2xIII", context_tag, target, pname))
1309        return self.send_request(136, buf, GetTexParameterfvCookie, is_checked=is_checked)
1310    def GetTexParameteriv(self, context_tag, target, pname, is_checked=True):
1311        buf = six.BytesIO()
1312        buf.write(struct.pack("=xx2xIII", context_tag, target, pname))
1313        return self.send_request(137, buf, GetTexParameterivCookie, is_checked=is_checked)
1314    def GetTexLevelParameterfv(self, context_tag, target, level, pname, is_checked=True):
1315        buf = six.BytesIO()
1316        buf.write(struct.pack("=xx2xIIiI", context_tag, target, level, pname))
1317        return self.send_request(138, buf, GetTexLevelParameterfvCookie, is_checked=is_checked)
1318    def GetTexLevelParameteriv(self, context_tag, target, level, pname, is_checked=True):
1319        buf = six.BytesIO()
1320        buf.write(struct.pack("=xx2xIIiI", context_tag, target, level, pname))
1321        return self.send_request(139, buf, GetTexLevelParameterivCookie, is_checked=is_checked)
1322    def IsEnabled(self, context_tag, capability, is_checked=True):
1323        buf = six.BytesIO()
1324        buf.write(struct.pack("=xx2xII", context_tag, capability))
1325        return self.send_request(140, buf, IsEnabledCookie, is_checked=is_checked)
1326    def IsList(self, context_tag, list, is_checked=True):
1327        buf = six.BytesIO()
1328        buf.write(struct.pack("=xx2xII", context_tag, list))
1329        return self.send_request(141, buf, IsListCookie, is_checked=is_checked)
1330    def Flush(self, context_tag, is_checked=False):
1331        buf = six.BytesIO()
1332        buf.write(struct.pack("=xx2xI", context_tag))
1333        return self.send_request(142, buf, is_checked=is_checked)
1334    def AreTexturesResident(self, context_tag, n, textures, is_checked=True):
1335        buf = six.BytesIO()
1336        buf.write(struct.pack("=xx2xIi", context_tag, n))
1337        buf.write(xcffib.pack_list(textures, "I"))
1338        return self.send_request(143, buf, AreTexturesResidentCookie, is_checked=is_checked)
1339    def DeleteTextures(self, context_tag, n, textures, is_checked=False):
1340        buf = six.BytesIO()
1341        buf.write(struct.pack("=xx2xIi", context_tag, n))
1342        buf.write(xcffib.pack_list(textures, "I"))
1343        return self.send_request(144, buf, is_checked=is_checked)
1344    def GenTextures(self, context_tag, n, is_checked=True):
1345        buf = six.BytesIO()
1346        buf.write(struct.pack("=xx2xIi", context_tag, n))
1347        return self.send_request(145, buf, GenTexturesCookie, is_checked=is_checked)
1348    def IsTexture(self, context_tag, texture, is_checked=True):
1349        buf = six.BytesIO()
1350        buf.write(struct.pack("=xx2xII", context_tag, texture))
1351        return self.send_request(146, buf, IsTextureCookie, is_checked=is_checked)
1352    def GetColorTable(self, context_tag, target, format, type, swap_bytes, is_checked=True):
1353        buf = six.BytesIO()
1354        buf.write(struct.pack("=xx2xIIIIB", context_tag, target, format, type, swap_bytes))
1355        return self.send_request(147, buf, GetColorTableCookie, is_checked=is_checked)
1356    def GetColorTableParameterfv(self, context_tag, target, pname, is_checked=True):
1357        buf = six.BytesIO()
1358        buf.write(struct.pack("=xx2xIII", context_tag, target, pname))
1359        return self.send_request(148, buf, GetColorTableParameterfvCookie, is_checked=is_checked)
1360    def GetColorTableParameteriv(self, context_tag, target, pname, is_checked=True):
1361        buf = six.BytesIO()
1362        buf.write(struct.pack("=xx2xIII", context_tag, target, pname))
1363        return self.send_request(149, buf, GetColorTableParameterivCookie, is_checked=is_checked)
1364    def GetConvolutionFilter(self, context_tag, target, format, type, swap_bytes, is_checked=True):
1365        buf = six.BytesIO()
1366        buf.write(struct.pack("=xx2xIIIIB", context_tag, target, format, type, swap_bytes))
1367        return self.send_request(150, buf, GetConvolutionFilterCookie, is_checked=is_checked)
1368    def GetConvolutionParameterfv(self, context_tag, target, pname, is_checked=True):
1369        buf = six.BytesIO()
1370        buf.write(struct.pack("=xx2xIII", context_tag, target, pname))
1371        return self.send_request(151, buf, GetConvolutionParameterfvCookie, is_checked=is_checked)
1372    def GetConvolutionParameteriv(self, context_tag, target, pname, is_checked=True):
1373        buf = six.BytesIO()
1374        buf.write(struct.pack("=xx2xIII", context_tag, target, pname))
1375        return self.send_request(152, buf, GetConvolutionParameterivCookie, is_checked=is_checked)
1376    def GetSeparableFilter(self, context_tag, target, format, type, swap_bytes, is_checked=True):
1377        buf = six.BytesIO()
1378        buf.write(struct.pack("=xx2xIIIIB", context_tag, target, format, type, swap_bytes))
1379        return self.send_request(153, buf, GetSeparableFilterCookie, is_checked=is_checked)
1380    def GetHistogram(self, context_tag, target, format, type, swap_bytes, reset, is_checked=True):
1381        buf = six.BytesIO()
1382        buf.write(struct.pack("=xx2xIIIIBB", context_tag, target, format, type, swap_bytes, reset))
1383        return self.send_request(154, buf, GetHistogramCookie, is_checked=is_checked)
1384    def GetHistogramParameterfv(self, context_tag, target, pname, is_checked=True):
1385        buf = six.BytesIO()
1386        buf.write(struct.pack("=xx2xIII", context_tag, target, pname))
1387        return self.send_request(155, buf, GetHistogramParameterfvCookie, is_checked=is_checked)
1388    def GetHistogramParameteriv(self, context_tag, target, pname, is_checked=True):
1389        buf = six.BytesIO()
1390        buf.write(struct.pack("=xx2xIII", context_tag, target, pname))
1391        return self.send_request(156, buf, GetHistogramParameterivCookie, is_checked=is_checked)
1392    def GetMinmax(self, context_tag, target, format, type, swap_bytes, reset, is_checked=True):
1393        buf = six.BytesIO()
1394        buf.write(struct.pack("=xx2xIIIIBB", context_tag, target, format, type, swap_bytes, reset))
1395        return self.send_request(157, buf, GetMinmaxCookie, is_checked=is_checked)
1396    def GetMinmaxParameterfv(self, context_tag, target, pname, is_checked=True):
1397        buf = six.BytesIO()
1398        buf.write(struct.pack("=xx2xIII", context_tag, target, pname))
1399        return self.send_request(158, buf, GetMinmaxParameterfvCookie, is_checked=is_checked)
1400    def GetMinmaxParameteriv(self, context_tag, target, pname, is_checked=True):
1401        buf = six.BytesIO()
1402        buf.write(struct.pack("=xx2xIII", context_tag, target, pname))
1403        return self.send_request(159, buf, GetMinmaxParameterivCookie, is_checked=is_checked)
1404    def GetCompressedTexImageARB(self, context_tag, target, level, is_checked=True):
1405        buf = six.BytesIO()
1406        buf.write(struct.pack("=xx2xIIi", context_tag, target, level))
1407        return self.send_request(160, buf, GetCompressedTexImageARBCookie, is_checked=is_checked)
1408    def DeleteQueriesARB(self, context_tag, n, ids, is_checked=False):
1409        buf = six.BytesIO()
1410        buf.write(struct.pack("=xx2xIi", context_tag, n))
1411        buf.write(xcffib.pack_list(ids, "I"))
1412        return self.send_request(161, buf, is_checked=is_checked)
1413    def GenQueriesARB(self, context_tag, n, is_checked=True):
1414        buf = six.BytesIO()
1415        buf.write(struct.pack("=xx2xIi", context_tag, n))
1416        return self.send_request(162, buf, GenQueriesARBCookie, is_checked=is_checked)
1417    def IsQueryARB(self, context_tag, id, is_checked=True):
1418        buf = six.BytesIO()
1419        buf.write(struct.pack("=xx2xII", context_tag, id))
1420        return self.send_request(163, buf, IsQueryARBCookie, is_checked=is_checked)
1421    def GetQueryivARB(self, context_tag, target, pname, is_checked=True):
1422        buf = six.BytesIO()
1423        buf.write(struct.pack("=xx2xIII", context_tag, target, pname))
1424        return self.send_request(164, buf, GetQueryivARBCookie, is_checked=is_checked)
1425    def GetQueryObjectivARB(self, context_tag, id, pname, is_checked=True):
1426        buf = six.BytesIO()
1427        buf.write(struct.pack("=xx2xIII", context_tag, id, pname))
1428        return self.send_request(165, buf, GetQueryObjectivARBCookie, is_checked=is_checked)
1429    def GetQueryObjectuivARB(self, context_tag, id, pname, is_checked=True):
1430        buf = six.BytesIO()
1431        buf.write(struct.pack("=xx2xIII", context_tag, id, pname))
1432        return self.send_request(166, buf, GetQueryObjectuivARBCookie, is_checked=is_checked)
1433xcffib._add_ext(key, glxExtension, _events, _errors)
1434