X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=Testing%2FTestMakeDicomDir.cxx;h=695e230786805ea4be8b201a9d031a1497742eaf;hb=d66701140e07d8e6fa7a529a8d2ae99d685026c5;hp=586e8692be6f8363a1f4af32e088d7efc189bb61;hpb=9689c0978578896cab99394a3cbe4fdcb3583ff5;p=gdcm.git diff --git a/Testing/TestMakeDicomDir.cxx b/Testing/TestMakeDicomDir.cxx index 586e8692..695e2307 100644 --- a/Testing/TestMakeDicomDir.cxx +++ b/Testing/TestMakeDicomDir.cxx @@ -3,8 +3,8 @@ Program: gdcm Module: $RCSfile: TestMakeDicomDir.cxx,v $ Language: C++ - Date: $Date: 2005/07/08 10:15:08 $ - Version: $Revision: 1.4 $ + Date: $Date: 2005/08/30 15:13:07 $ + Version: $Revision: 1.8 $ Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de l'Image). All rights reserved. See Doc/License.txt or @@ -64,13 +64,13 @@ int TestMakeDicomDir(int argc, char *argv[]) // new style (user is allowed no to load Sequences an/or Shadow Groups) dcmdir = new gdcm::DicomDir( ); - // dcmdir->SetLoadMode(NO_SEQ | NO_SHADOW); + // dcmdir->SetLoadMode(gdcm::LD_NOSEQ | gdcm::LD_NOSHADOW); // some images have a wrong length for element 0x0000 of private groups - dcmdir->SetLoadMode(NO_SEQ); + dcmdir->SetLoadMode(gdcm::LD_NOSEQ); dcmdir->SetDirectoryName(dirName); dcmdir->Load( ); - dcmdir->SetStartMethod(StartMethod, (void *) NULL); + dcmdir->SetStartMethod(StartMethod); dcmdir->SetEndMethod(EndMethod); if ( !dcmdir->GetFirstPatient() ) @@ -87,7 +87,10 @@ int TestMakeDicomDir(int argc, char *argv[]) delete dcmdir; // Read from disc the just written DicomDir - gdcm::DicomDir *newDicomDir = new gdcm::DicomDir("NewDICOMDIR"); + gdcm::DicomDir *newDicomDir = new gdcm::DicomDir(); + newDicomDir->SetFileName("NewDICOMDIR"); + newDicomDir->Load(); + if( !newDicomDir->IsReadable() ) { std::cout<<" Written DicomDir 'NewDICOMDIR'"