- // we ask for Directory parsing
- gdcm::DicomDir *dcmdir = new gdcm::DicomDir(dirName, true);
+ // new style (user is allowed no to load Sequences an/or Shadow Groups)
+ dcmdir = new gdcm::DicomDir( );
+ dcmdir->SetParseDir(true);
+ // dcmdir->SetLoadMode(NO_SEQ | NO_SHADOW);
+ // some images have a wrong length for element 0x0000 of private groups
+ dcmdir->SetLoadMode(NO_SEQ);
+ dcmdir->Load(dirName);