125 const char *filename,
132 int verbose=0;
if(status!=NULL) verbose=status->
verbose;
133 if(filename==NULL ||
strnlen(filename, 10)<1 || ift==NULL) {
137 if(verbose>1) printf(
"%s('%s', ...)\n", __func__, filename);
140 unsigned short int fileNr=0;
143 if(verbose>2) printf(
"%s is a directory\n", filename);
157 fileNr=ift->
keyNr;
if(verbose>3) printf(
"fileNr := %d\n", fileNr);
169 for(i=1; i<ift->
keyNr; i++) {
173 statusSet(status, __func__, __FILE__, __LINE__, ret);
186 if(verbose>2) printf(
"%s is a file\n", filename);
192 if(verbose>2) {printf(
"... and DICOM\n"); fflush(stdout);}
203 printf(
"Per-frame Functional Groups Sequence is available: assuming single-file.\n");
205 iftPut(ift,
"", filename, 0, NULL);
213 if(verbose>3) printf(
"%s is its path\n", pathname);
216 if(verbose>3) printf(
"fileNr := %d\n", fileNr);
228 fileNr=ift->
keyNr;
if(verbose>3) printf(
"fileNr := %d\n", fileNr);
240 if(verbose>5) {printf(
" not same, removing from list\n"); fflush(stdout);}
247 fileNr=ift->
keyNr;
if(verbose>3) printf(
"fileNr := %d\n", fileNr);
272 const char *filename,
276 int verbose=0;
if(status!=NULL) verbose=status->
verbose;
277 if(filename==NULL ||
strnlen(filename, 10)<1) {
281 if(verbose>1) printf(
"%s('%s', ...)\n", __func__, filename);
289 for(
int i=0; i<ift.
keyNr; i++) {
int dcmFileList(const char *filename, IFT *ift, TPCSTATUS *status)
List DICOM files belonging to one image.
int iftPut(IFT *ift, const char *key, const char *value, char comment, TPCSTATUS *status)