summaryrefslogtreecommitdiffstats
path: root/src/mesa/glapi/glX_proto_send.py
diff options
context:
space:
mode:
authorMichel Dänzer <[email protected]>2007-10-30 17:47:17 +0100
committerMichel Dänzer <[email protected]>2007-10-30 17:58:50 +0100
commitd2f19a554a9089fddb5e978e3a732bbf71d77f93 (patch)
tree891d813900907dcf65872c9b150f74b9f461c3f7 /src/mesa/glapi/glX_proto_send.py
parenta7f64635a640f49011cf78af766f90ae6588989a (diff)
Fix some build warnings, mostly with XCB.
Diffstat (limited to 'src/mesa/glapi/glX_proto_send.py')
-rw-r--r--src/mesa/glapi/glX_proto_send.py14
1 files changed, 9 insertions, 5 deletions
diff --git a/src/mesa/glapi/glX_proto_send.py b/src/mesa/glapi/glX_proto_send.py
index 1b6a5f3890c..0fa0f7e8706 100644
--- a/src/mesa/glapi/glX_proto_send.py
+++ b/src/mesa/glapi/glX_proto_send.py
@@ -511,7 +511,7 @@ generic_%u_byte( GLint rop, const void * ptr )
return
- def common_func_print_just_start(self, f):
+ def common_func_print_just_start(self, f, name):
print ' __GLXcontext * const gc = __glXGetCurrentContext();'
# The only reason that single and vendor private commands need
@@ -529,7 +529,7 @@ generic_%u_byte( GLint rop, const void * ptr )
if not f.glx_rop:
for p in f.parameterIterateOutputs():
- if p.is_image():
+ if p.is_image() and (p.img_format != "GL_COLOR_INDEX" or p.img_type != "GL_BITMAP"):
print ' const __GLXattribute * const state = gc->client_state_private;'
break
@@ -545,7 +545,11 @@ generic_%u_byte( GLint rop, const void * ptr )
print ' %s retval = (%s) 0;' % (f.return_type, f.return_type)
+ if name != None and name not in f.glx_vendorpriv_names:
+ print '#ifndef USE_XCB'
self.emit_packet_size_calculation(f, 0)
+ if name != None and name not in f.glx_vendorpriv_names:
+ print '#endif'
condition_list = []
for p in f.parameterIterateCounters():
@@ -567,7 +571,7 @@ generic_%u_byte( GLint rop, const void * ptr )
def printSingleFunction(self, f, name):
- self.common_func_print_just_start(f)
+ self.common_func_print_just_start(f, name)
if self.debug:
print ' printf( "Enter %%s...\\n", "gl%s" );' % (f.name)
@@ -739,7 +743,7 @@ generic_%u_byte( GLint rop, const void * ptr )
return
- if self.common_func_print_just_start(f):
+ if self.common_func_print_just_start(f, None):
trailer = " }"
else:
trailer = None
@@ -791,7 +795,7 @@ generic_%u_byte( GLint rop, const void * ptr )
print ' generic_%u_byte( %s, %s );' % (cmdlen, f.opcode_real_name(), p.name)
return
- if self.common_func_print_just_start(f):
+ if self.common_func_print_just_start(f, None):
trailer = " }"
else:
trailer = None