Changeset 63939 in vbox for trunk/src/VBox/GuestHost/OpenGL/error
- Timestamp:
- Sep 22, 2016 7:58:05 AM (9 years ago)
- svn:sync-xref-src-repo-rev:
- 110825
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/GuestHost/OpenGL/error/error.py
r37392 r63939 5 5 6 6 7 from __future__ import print_function 7 8 import sys 8 9 … … 12 13 13 14 14 print 15 print("""#include <stdio.h> 15 16 #include "cr_error.h" 16 17 #include "cr_spu.h" … … 23 24 #endif 24 25 25 #define ERROR_UNUSED(x) ((void)x)""" 26 #define ERROR_UNUSED(x) ((void)x)""") 26 27 27 28 … … 31 32 return_type = apiutil.ReturnType(func_name) 32 33 params = apiutil.Parameters(func_name) 33 print '\nstatic %s ERROR_APIENTRY error%s( %s )' % (return_type, func_name, apiutil.MakeDeclarationString(params))34 print '{'34 print('\nstatic %s ERROR_APIENTRY error%s( %s )' % (return_type, func_name, apiutil.MakeDeclarationString(params ))) 35 print('{') 35 36 # Handle the void parameter list 36 37 for (name, type, vecSize) in params: 37 print '\tERROR_UNUSED(%s);' % name38 print '\tcrError( "ERROR SPU: Unsupported function gl%s called!" );' % func_name38 print('\tERROR_UNUSED(%s);' % name) 39 print('\tcrError( "ERROR SPU: Unsupported function gl%s called!" );' % func_name) 39 40 if return_type != "void": 40 print '\treturn (%s)0;' % return_type41 print '}'41 print('\treturn (%s)0;' % return_type) 42 print('}') 42 43 43 print 'SPUNamedFunctionTable _cr_error_table[] = {'44 print('SPUNamedFunctionTable _cr_error_table[] = {') 44 45 for index in range(len(keys)): 45 46 func_name = keys[index] 46 print '\t{ "%s", (SPUGenericFunction) error%s },' % (func_name, func_name)47 print '\t{ NULL, NULL }'48 print '};'47 print('\t{ "%s", (SPUGenericFunction) error%s },' % (func_name, func_name )) 48 print('\t{ NULL, NULL }') 49 print('};')
Note:
See TracChangeset
for help on using the changeset viewer.