124{
126 char* outname;
127 char cutstr[256];
128 char options[256];
129 sprintf(cutstr,"") ;
130
131 int nfiles = 0;
132
133 bool printusage=(argc<3)?true:false;
134 for (int i = 1; i < argc; i++) {
135 if (!strcmp(argv[i], "-cutv")) {
136 if (i + 1 <= argc - 1) sprintf(cutstr,argv[++i]);
137 else printusage=true;
138 }
139 else if (!strcmp(argv[i], "-nocl")) strcat(options,"NOCL") ;
140 else if (!strcmp(argv[i], "-bot")) sprintf(cutstr,"eNframesBot") ;
141 else if (!strcmp(argv[i], "-top")) sprintf(cutstr,"eNframesTop") ;
142 else {
143 sprintf(
fname[nfiles++],argv[i]);
144 }
145 }
146 if(printusage) {
147 cout << endl << " usage: edbtools <file1> <file2> .... <outfile> [options] " << endl << endl;
148 cout << " merge file1 file2 (up to 8) [if only one input file copy file1 to outfile]" << endl;
149 cout << " options: -top = extract top views" << endl;
150 cout << " -bot = extract bottom views" << endl;
151 cout << " -nocl = do not add the clusters" << endl;
152 cout << " -cutv \"cutview\" = apply the cut \"cutview\" to the views" << endl;
153 cout << " example -cutv \"eAreaID==10\" [extract the fragment 10]" << endl;
154 return 0;
155 };
156
157 outname =
fname[nfiles-1] ;
158
159 int n_input = nfiles-1 ;
160 cout << " input file(s) : " ;
161 for(
int j=0;j<n_input;j++) cout<<
fname[j] <<
" " ;
162 cout <<endl;
163 cout << " output file : " << outname << endl;
164 cout << " cut views : " << cutstr << endl;
165 cout << " options : " << options << endl;
166
167
169 strcat(options,"UPDATE") ;
171
172 return 0;
173}
const char * fname
Definition: mc2raw.cxx:41