diff options
Diffstat (limited to 'mesalib/src/mapi/glapi/gen/glX_proto_recv.py')
-rw-r--r-- | mesalib/src/mapi/glapi/gen/glX_proto_recv.py | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/mesalib/src/mapi/glapi/gen/glX_proto_recv.py b/mesalib/src/mapi/glapi/gen/glX_proto_recv.py index b577bb6bd..65674dab7 100644 --- a/mesalib/src/mapi/glapi/gen/glX_proto_recv.py +++ b/mesalib/src/mapi/glapi/gen/glX_proto_recv.py @@ -78,6 +78,14 @@ class PrintGlxDispatchFunctions(glX_proto_common.glx_print_proto): def printRealHeader(self): + print '#ifdef HAVE_DIX_CONFIG_H' + print '#include <dix-config.h>' + print '#else' + print '' + print '#include "glheader.h"' + print '' + print '#endif' + print '' print '#include <X11/Xmd.h>' print '#include <GL/gl.h>' print '#include <GL/glxproto.h>' @@ -278,7 +286,10 @@ class PrintGlxDispatchFunctions(glX_proto_common.glx_print_proto): if param.is_image(): offset = f.offset_of( param.name ) - print '%s %s const %s = (%s) (%s(pc + %s));' % (indent, type_string, param.name, type_string, cond, offset) + if cond: + print '%s %s const %s = (%s) (%s(pc + %s));' % (indent, type_string, param.name, type_string, cond, offset) + else: + print '%s %s const %s = (%s) (pc + %s);' % (indent, type_string, param.name, type_string, offset) if param.depth: print '%s __GLXpixel3DHeader * const hdr = (__GLXpixel3DHeader *)(pc);' % (indent) @@ -365,8 +376,9 @@ class PrintGlxDispatchFunctions(glX_proto_common.glx_print_proto): else: for param in f.parameterIterateGlxSend(): if param.count_parameter_list: - print '%s %s = (%s) (pc + %s);' % (indent, param.name, param.type_string(), param.offset) - need_blank = 1 + if param.size() != 1 or self.do_swap: + print '%s %s = (%s) (pc + %s);' % (indent, param.name, param.type_string(), param.offset) + need_blank = 1 if need_blank: |