]> Creatis software - gdcm.git/blobdiff - Example/PrintDicomDir.cxx
Add exOverlayACR
[gdcm.git] / Example / PrintDicomDir.cxx
index 5eda61450c910441ceec9151250e1add063c4dc6..329e47c8bca4501860343603d5af46cdffcbe268 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: PrintDicomDir.cxx,v $
   Language:  C++
-  Date:      $Date: 2005/01/24 16:10:49 $
-  Version:   $Revision: 1.18 $
+  Date:      $Date: 2005/04/14 15:13:39 $
+  Version:   $Revision: 1.20 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -48,16 +48,16 @@ int main(int argc, char* argv[])
    }
 
    if (argc > 3)
-      gdcm::Debug::SetDebugOn();
+      gdcm::Debug::DebugOn();
 
    e1 = new gdcm::DicomDir( fileName );
 
-   e1->SetPrintLevel(2);
-   int detailLevel;
-   if (argc > 2)
-      detailLevel = atoi(argv[2]);   
-   else
-      detailLevel = 3;
+   // new style id useless, since it has no effect fore *reading* a DICOMDIR
+   // (only meaningfull when *creating* a DICOMDIR)
+
+   //e1 = new gdcm::DicomDir();
+   //e1->SetParseDir(false);
+   //e1->Load(  fileName );
 
    // Test if the DicomDir is readable
    if( !e1->IsReadable() )
@@ -70,6 +70,13 @@ int main(int argc, char* argv[])
       return 1;
    }
 
+   e1->SetPrintLevel(2);
+   int detailLevel;
+   if (argc > 2)
+      detailLevel = atoi(argv[2]);   
+   else
+      detailLevel = 3;
+
    // Test if the DicomDir contains any Patient
    pa = e1->GetFirstPatient();
    if ( pa  == 0)