Changeset 63942 in vbox for trunk/src/VBox/Additions/common/crOpenGL/pack
- Timestamp:
- Sep 22, 2016 11:01:17 AM (8 years ago)
- Location:
- trunk/src/VBox/Additions/common/crOpenGL/pack
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Additions/common/crOpenGL/pack/pack.py
r63939 r63942 29 29 30 30 print(""" 31 static void __fillin( int offset, char *name, SPUGenericFunction func)31 static void __fillin(int offset, char *name, SPUGenericFunction func) 32 32 { 33 _cr_pack_table[offset].name = crStrdup( name);33 _cr_pack_table[offset].name = crStrdup(name); 34 34 _cr_pack_table[offset].fn = func; 35 35 }""") … … 51 51 continue 52 52 if func_name in pack_specials: 53 print('\t__fillin( %3d, "%s", (SPUGenericFunction) packspu_%s);' % (index, func_name, func_name ))53 print('\t__fillin(%3d, "%s", (SPUGenericFunction) packspu_%s);' % (index, func_name, func_name )) 54 54 else: 55 print('\t__fillin( %3d, "%s", (SPUGenericFunction) (pack_spu.swap ? crPack%sSWAP : crPack%s));' % (index, func_name, func_name, func_name ))56 print('\t__fillin( %3d, NULL, NULL);' % num_funcs)55 print('\t__fillin(%3d, "%s", (SPUGenericFunction) (pack_spu.swap ? crPack%sSWAP : crPack%s));' % (index, func_name, func_name, func_name )) 56 print('\t__fillin(%3d, NULL, NULL);' % num_funcs) 57 57 print('}') -
trunk/src/VBox/Additions/common/crOpenGL/pack/packspu_beginend.py
r63939 r63942 164 164 for func_name in apiutil.AllSpecials( "packspu_vertex" ): 165 165 params = apiutil.Parameters(func_name) 166 print('void PACKSPU_APIENTRY packspu_%s( %s)' % ( func_name, apiutil.MakeDeclarationString(params) ))166 print('void PACKSPU_APIENTRY packspu_%s(%s)' % ( func_name, apiutil.MakeDeclarationString(params) )) 167 167 print('{') 168 168 print('\tif (pack_spu.swap)') 169 169 print('\t{') 170 print('\t\tcrPack%sSWAP( %s);' % ( func_name, apiutil.MakeCallString( params ) ))170 print('\t\tcrPack%sSWAP(%s);' % ( func_name, apiutil.MakeCallString( params ) )) 171 171 print('\t}') 172 172 print('\telse') 173 173 print('\t{') 174 print('\t\tcrPack%s( %s);' % ( func_name, apiutil.MakeCallString( params ) ))174 print('\t\tcrPack%s(%s);' % ( func_name, apiutil.MakeCallString( params ) )) 175 175 print('\t}') 176 176 print('\tRunState();') -
trunk/src/VBox/Additions/common/crOpenGL/pack/packspu_flush.py
r63939 r63942 28 28 for func_name in apiutil.AllSpecials( "packspu_flush" ): 29 29 params = apiutil.Parameters(func_name) 30 print('void PACKSPU_APIENTRY packspu_%s( %s)' % ( func_name, apiutil.MakeDeclarationString(params)))30 print('void PACKSPU_APIENTRY packspu_%s(%s)' % ( func_name, apiutil.MakeDeclarationString(params))) 31 31 print('{') 32 32 print('\tGET_THREAD(thread);') 33 33 print('\tif (pack_spu.swap)') 34 34 print('\t{') 35 print('\t\tcrPack%sSWAP( %s);' % ( func_name, apiutil.MakeCallString( params ) ))35 print('\t\tcrPack%sSWAP(%s);' % ( func_name, apiutil.MakeCallString( params ) )) 36 36 print('\t}') 37 37 print('\telse') 38 38 print('\t{') 39 print('\t\tcrPack%s( %s);' % ( func_name, apiutil.MakeCallString( params ) ))39 print('\t\tcrPack%s(%s);' % ( func_name, apiutil.MakeCallString( params ) )) 40 40 print('\t}') 41 41 print('\tpackspuFlush( (void *) thread );') -
trunk/src/VBox/Additions/common/crOpenGL/pack/packspu_get.py
r63939 r63942 86 86 87 87 if "get" in apiutil.Properties(func_name): 88 print('%s PACKSPU_APIENTRY packspu_%s( %s)' % ( return_type, func_name, apiutil.MakeDeclarationString( params ) ))88 print('%s PACKSPU_APIENTRY packspu_%s(%s)' % ( return_type, func_name, apiutil.MakeDeclarationString( params ) )) 89 89 print('{') 90 90 print('\tGET_THREAD(thread);') … … 195 195 print('\tif (pack_spu.swap)') 196 196 print('\t{') 197 print('\t\tcrPack%sSWAP( %s);' % (func_name, apiutil.MakeCallString( params ) ))197 print('\t\tcrPack%sSWAP(%s);' % (func_name, apiutil.MakeCallString( params ) )) 198 198 print('\t}') 199 199 print('\telse') 200 200 print('\t{') 201 print('\t\tcrPack%s( %s);' % (func_name, apiutil.MakeCallString( params ) ))201 print('\t\tcrPack%s(%s);' % (func_name, apiutil.MakeCallString( params ) )) 202 202 print('\t}') 203 203 print('\tpackspuFlush( (void *) thread );') … … 217 217 print('\tif (pack_spu.swap)') 218 218 print('\t{') 219 print('\t\tfor (i = 0 ; i < %s; i++)' % limit)219 print('\t\tfor (i = 0; i < %s; i++)' % limit) 220 220 print('\t\t{') 221 221 if params[-2][1].find( "double" ) > -1: … … 229 229 print('\tif (pack_spu.swap)') 230 230 print('\t{') 231 print('\t\tfor (i = 0 ; i < __numValues( pname ); i++)')231 print('\t\tfor (i = 0; i < __numValues(pname); i++)') 232 232 print('\t\t{') 233 233 if simple_swaps[index] == 'SWAPDOUBLE': … … 240 240 print('\tif (pack_spu.swap)') 241 241 print('\t{') 242 print('\t\tfor (i = 0 ; i < crStateHlpComponentsCount(pname); i++)')242 print('\t\tfor (i = 0; i < crStateHlpComponentsCount(pname); i++)') 243 243 print('\t\t{') 244 244 if hard_funcs[func_name] == 'SWAPDOUBLE': -
trunk/src/VBox/Additions/common/crOpenGL/pack/packspu_proto.py
r63939 r63942 43 43 return_type = apiutil.ReturnType(func_name) 44 44 params = apiutil.Parameters(func_name) 45 print('extern %s PACKSPU_APIENTRY packspu_%s( %s);' % ( return_type, func_name, apiutil.MakeDeclarationString(params) ))45 print('extern %s PACKSPU_APIENTRY packspu_%s(%s);' % ( return_type, func_name, apiutil.MakeDeclarationString(params) )) 46 46 47 47
Note:
See TracChangeset
for help on using the changeset viewer.