+ if (verbose) {
+ std::cout << "0x0021, 0x1020 : strChSliceIndex " << strChSliceIndex << std::endl;
+ std::cout << "0x0021, 0x1040 : chFrameIndex " << chFrameIndex << std::endl;
+ std::cout << "0x0020, 0x0012 : chSessionIndex " << chSessionIndex << std::endl;
+ }
+
+ std::string strImagePositionPatient = currentFile->GetEntryString(0x0020, 0x0032 );
+ if (strImagePositionPatient == GDCM_NAME_SPACE::GDCM_UNFOUND)
+ {
+ if (verbose)
+ std::cout << "Duplicate ImagePosition into ImagePositionPatient" << std::endl;
+ currentFile->InsertEntryString(currentFile->GetEntryString(0x0020, 0x0030), 0x0020, 0x0032, "DS" );
+ }
+
+ std::string strImageOrientationPatient = f->GetEntryString(0x0020, 0x0037 );
+ if (strImageOrientationPatient == GDCM_NAME_SPACE::GDCM_UNFOUND)
+ {
+ if (verbose)
+ std::cout << "Duplicate ImageOrientation into ImageOrientationPatient" << std::endl;
+ currentFile->InsertEntryString(currentFile->GetEntryString(0x0020, 0x0035), 0x0020, 0x0037, "DS" );
+ }
+
+ if (taggrid || strcmp(input, "IDO")==0 || strcmp(input, "ido")==0 )