buzztrax/buzztrax-misleading-indentation.patch

140 lines
8.4 KiB
Diff
Raw Normal View History

Index: tests/lib/bml/bmltest_info.h
===================================================================
--- tests/lib/bml/bmltest_info.h.orig
+++ tests/lib/bml/bmltest_info.h
@@ -40,9 +40,15 @@ int bml(test_info(char *libpath)) {
ts2=_get_timestamp();
printf(" machine initialized in %lf sec\n",ts2-ts1);
- if(bml(get_machine_info(bmh,BM_PROP_SHORT_NAME,(void *)&str))) printf(" Short Name: \"%s\"\n",str);
- if(bml(get_machine_info(bmh,BM_PROP_NAME,(void *)&str))) printf(" Name: \"%s\"\n",str);
- if(bml(get_machine_info(bmh,BM_PROP_AUTHOR,(void *)&str))) printf(" Author: \"%s\"\n",str);
+ if(bml(get_machine_info(bmh,BM_PROP_SHORT_NAME,(void *)&str))) {
+ printf(" Short Name: \"%s\"\n",str);
+ }
+ if(bml(get_machine_info(bmh,BM_PROP_NAME,(void *)&str))) {
+ printf(" Name: \"%s\"\n",str);
+ }
+ if(bml(get_machine_info(bmh,BM_PROP_AUTHOR,(void *)&str))) {
+ printf(" Author: \"%s\"\n",str);
+ }
if(bml(get_machine_info(bmh,BM_PROP_COMMANDS,(void *)&str))) {
if(str) {
char *t=strdup(str), *p=t;
@@ -54,9 +60,14 @@ int bml(test_info(char *libpath)) {
free(t);
}
}
- if(bml(get_machine_info(bmh,BM_PROP_TYPE,(void *)&val))) printf(" Type: %i -> \"%s\"\n",val,((val<3)?machine_types[val]:"unknown"));
- if(bml(get_machine_info(bmh,BM_PROP_VERSION,(void *)&val))) printf(" Version: %3.1f\n",(float)val/10.0);
- if(bml(get_machine_info(bmh,BM_PROP_FLAGS,(void *)&val))) { printf(" Flags: 0x%x\n",val);
+ if(bml(get_machine_info(bmh,BM_PROP_TYPE,(void *)&val))) {
+ printf(" Type: %i -> \"%s\"\n",val,((val<3)?machine_types[val]:"unknown"));
+ }
+ if(bml(get_machine_info(bmh,BM_PROP_VERSION,(void *)&val))) {
+ printf(" Version: %3.1f\n",(float)val/10.0);
+ }
+ if(bml(get_machine_info(bmh,BM_PROP_FLAGS,(void *)&val))) {
+ printf(" Flags: 0x%x\n",val);
if(val&(1<<0)) puts(" MIF_MONO_TO_STEREO");
if(val&(1<<1)) puts(" MIF_PLAYS_WAVES");
if(val&(1<<2)) puts(" MIF_USES_LIB_INTERFACE");
@@ -67,12 +78,21 @@ int bml(test_info(char *libpath)) {
if(val&(1<<7)) puts(" MIF_INTERNAL_AUX");
//if(val&) puts(" ");
}
- if(bml(get_machine_info(bmh,BM_PROP_MIN_TRACKS,(void *)&val))) printf(" MinTracks: %i\n",val);
+ if(bml(get_machine_info(bmh,BM_PROP_MIN_TRACKS,(void *)&val))) {
+ printf(" MinTracks: %i\n",val);
+ }
tracks=val;
- if(bml(get_machine_info(bmh,BM_PROP_MAX_TRACKS,(void *)&val))) printf(" MaxTracks: %i\n",val);
- if(bml(get_machine_info(bmh,BM_PROP_NUM_INPUT_CHANNELS,(void *)&val))) printf(" InputChannels: %d\n",val);
- if(bml(get_machine_info(bmh,BM_PROP_NUM_OUTPUT_CHANNELS,(void *)&val))) printf(" OutputChannels: %d\n",val);fflush(stdout);
- if(bml(get_machine_info(bmh,BM_PROP_NUM_GLOBAL_PARAMS,(void *)&val))) { printf(" NumGlobalParams: %i\n",val);fflush(stdout);
+ if(bml(get_machine_info(bmh,BM_PROP_MAX_TRACKS,(void *)&val))) {
+ printf(" MaxTracks: %i\n",val);
+ }
+ if(bml(get_machine_info(bmh,BM_PROP_NUM_INPUT_CHANNELS,(void *)&val))) {
+ printf(" InputChannels: %d\n",val);
+ }
+ if(bml(get_machine_info(bmh,BM_PROP_NUM_OUTPUT_CHANNELS,(void *)&val))) {
+ printf(" OutputChannels: %d\n",val);fflush(stdout);
+ }
+ if(bml(get_machine_info(bmh,BM_PROP_NUM_GLOBAL_PARAMS,(void *)&val))) {
+ printf(" NumGlobalParams: %i\n",val);fflush(stdout);
num=val;numtrig=0;
for(i=0;i<num;i++)
if(bml(get_global_parameter_info(bmh,i,BM_PARA_FLAGS,(void *)&val)))
@@ -80,10 +100,17 @@ int bml(test_info(char *libpath)) {
printf(" NumGlobalTriggerParams: %i\n",numtrig);fflush(stdout);
for(i=0;i<num;i++) {
printf(" GlobalParam=%02i\n",i);
- if(bml(get_global_parameter_info(bmh,i,BM_PARA_TYPE,(void *)&type))) printf(" Type: %i -> \"%s\"\n",type,((type<4)?parameter_types[type]:"unknown"));
- if(bml(get_global_parameter_info(bmh,i,BM_PARA_NAME,(void *)&str))) printf(" Name: \"%s\"\n",str);
- if(bml(get_global_parameter_info(bmh,i,BM_PARA_DESCRIPTION,(void *)&str))) printf(" Description: \"%s\"\n",str);
- if(bml(get_global_parameter_info(bmh,i,BM_PARA_FLAGS,(void *)&val))) { printf(" Flags: 0x%x\n",val);
+ if(bml(get_global_parameter_info(bmh,i,BM_PARA_TYPE,(void *)&type))) {
+ printf(" Type: %i -> \"%s\"\n",type,((type<4)?parameter_types[type]:"unknown"));
+ }
+ if(bml(get_global_parameter_info(bmh,i,BM_PARA_NAME,(void *)&str))) {
+ printf(" Name: \"%s\"\n",str);
+ }
+ if(bml(get_global_parameter_info(bmh,i,BM_PARA_DESCRIPTION,(void *)&str))) {
+ printf(" Description: \"%s\"\n",str);
+ }
+ if(bml(get_global_parameter_info(bmh,i,BM_PARA_FLAGS,(void *)&val))) {
+ printf(" Flags: 0x%x\n",val);
if(val&(1<<0)) puts(" MPF_WAVE");
if(val&(1<<1)) puts(" MPF_STATE");
if(val&(1<<2)) puts(" MPF_TICK_ON_EDIT");
@@ -104,7 +131,8 @@ int bml(test_info(char *libpath)) {
puts(" NumGlobalTriggerParams: 0");
}
fflush(stdout);
- if(bml(get_machine_info(bmh,BM_PROP_NUM_TRACK_PARAMS,(void *)&val))) { printf(" NumTrackParams: %i\n",val);fflush(stdout);
+ if(bml(get_machine_info(bmh,BM_PROP_NUM_TRACK_PARAMS,(void *)&val))) {
+ printf(" NumTrackParams: %i\n",val);fflush(stdout);
num=val;numtrig=0;
for(i=0;i<num;i++)
if(bml(get_track_parameter_info(bmh,i,BM_PARA_FLAGS,(void *)&val)))
@@ -113,10 +141,17 @@ int bml(test_info(char *libpath)) {
if(num && tracks) {
for(i=0;i<num;i++) {
printf(" TrackParam=%02i\n",i);
- if(bml(get_track_parameter_info(bmh,i,BM_PARA_TYPE,(void *)&type))) printf(" Type: %i -> \"%s\"\n",type,((type<4)?parameter_types[type]:"unknown"));
- if(bml(get_track_parameter_info(bmh,i,BM_PARA_NAME,(void *)&str))) printf(" Name: \"%s\"\n",str);
- if(bml(get_track_parameter_info(bmh,i,BM_PARA_DESCRIPTION,(void *)&str))) printf(" Description: \"%s\"\n",str);
- if(bml(get_track_parameter_info(bmh,i,BM_PARA_FLAGS,(void *)&val))) { printf(" Flags: 0x%x\n",val);
+ if(bml(get_track_parameter_info(bmh,i,BM_PARA_TYPE,(void *)&type))) {
+ printf(" Type: %i -> \"%s\"\n",type,((type<4)?parameter_types[type]:"unknown"));
+ }
+ if(bml(get_track_parameter_info(bmh,i,BM_PARA_NAME,(void *)&str))) {
+ printf(" Name: \"%s\"\n",str);
+ }
+ if(bml(get_track_parameter_info(bmh,i,BM_PARA_DESCRIPTION,(void *)&str))) {
+ printf(" Description: \"%s\"\n",str);
+ }
+ if(bml(get_track_parameter_info(bmh,i,BM_PARA_FLAGS,(void *)&val))) {
+ printf(" Flags: 0x%x\n",val);
if(val&(1<<0)) puts(" MPF_WAVE");
if(val&(1<<1)) puts(" MPF_STATE");
if(val&(1<<2)) puts(" MPF_TICK_ON_EDIT");
@@ -143,11 +178,14 @@ int bml(test_info(char *libpath)) {
puts(" NumTrackTriggerParams: 0");
}
fflush(stdout);
- if(bml(get_machine_info(bmh,BM_PROP_NUM_ATTRIBUTES,(void *)&val))) { printf(" NumAttributes: %i\n",val);fflush(stdout);
+ if(bml(get_machine_info(bmh,BM_PROP_NUM_ATTRIBUTES,(void *)&val))) {
+ printf(" NumAttributes: %i\n",val);fflush(stdout);
num=val;
for(i=0;i<num;i++) {
printf(" Attribute=%02i\n",i);
- if(bml(get_attribute_info(bmh,i,BM_ATTR_NAME,(void *)&str))) printf(" Name: \"%s\"\n",str);
+ if(bml(get_attribute_info(bmh,i,BM_ATTR_NAME,(void *)&str))) {
+ printf(" Name: \"%s\"\n",str);
+ }
if(bml(get_attribute_info(bmh,i,BM_ATTR_MIN_VALUE,(void *)&mival)) &&
bml(get_attribute_info(bmh,i,BM_ATTR_MAX_VALUE,(void *)&maval)) &&
bml(get_attribute_info(bmh,i,BM_ATTR_DEF_VALUE,(void *)&val))) {