]> Creatis software - gdcm.git/commitdiff
Typo
authorjpr <jpr>
Wed, 15 Jun 2005 09:54:13 +0000 (09:54 +0000)
committerjpr <jpr>
Wed, 15 Jun 2005 09:54:13 +0000 (09:54 +0000)
Example/MakeDicomDir.cxx
Example/TestWrite.cxx

index a479143a2145b1b9841fae008a00b71abb16b5b3..4a14581f8d4175f4f76a65869aea7a2402b2ca98 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: MakeDicomDir.cxx,v $
   Language:  C++
-  Date:      $Date: 2005/06/14 09:08:46 $
-  Version:   $Revision: 1.5 $
+  Date:      $Date: 2005/06/15 09:54:49 $
+  Version:   $Revision: 1.6 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -38,7 +38,6 @@ void EndMethod(void *toto) {
 // ---
 
 /**
-  * \ingroup Test
   * \brief   Explores recursively the given directory
   *          orders the gdcm-readable found Files
   *          according their Patient/Study/Serie/Image characteristics
index a5c0267f2affb74513fb53caec290aa4ac0b39ac..213042091ec09b83e88540c30e6c3834723fe3ac 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: TestWrite.cxx,v $
   Language:  C++
-  Date:      $Date: 2005/03/02 17:22:11 $
-  Version:   $Revision: 1.19 $
+  Date:      $Date: 2005/06/15 09:54:13 $
+  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
@@ -65,7 +65,13 @@ int main(int argc, char *argv[])
    std::string fileName = argv[1]; 
    std::string mode = argv[2];
 
-   e1 = new gdcm::File( fileName.c_str() );
+   //e1 = new gdcm::File( fileName.c_str() );
+
+   // new style :
+   e1 = new gdcm::File( );
+   e1->SetLoadMode(0);
+   e1->Load( fileName.c_str() );
+
    if (!e1->IsReadable())
    {
        std::cerr << "Sorry, not a Readable DICOM / ACR File"  <<std::endl;
@@ -74,9 +80,12 @@ int main(int argc, char *argv[])
   // e1->Print(); 
    
    f1 = new gdcm::FileHelper(e1);
+   dataSize = f1->GetImageDataSize();
+   imageData= f1->GetImageData();
+
+
 // ---     
 
-   dataSize = f1->GetImageDataSize();
    std::cout <<std::endl <<" dataSize " << dataSize << std::endl;
    int nX,nY,nZ,sPP,planarConfig;
    std::string pixelType, transferSyntaxName;
@@ -100,8 +109,9 @@ int main(int argc, char *argv[])
    std::cout << "NumberOfScalarComponents " << numberOfScalarComponents <<std::endl;
    transferSyntaxName = e1->GetTransferSyntaxName();
    std::cout << " TransferSyntaxName= [" << transferSyntaxName << "]" << std::endl;
-   
-/*   if (  transferSyntaxName != "Implicit VR - Little Endian"
+
+/*   
+  if (  transferSyntaxName != "Implicit VR - Little Endian"
       && transferSyntaxName != "Explicit VR - Little Endian"     
       && transferSyntaxName != "Deflated Explicit VR - Little Endian"      
       && transferSyntaxName != "Explicit VR - Big Endian"
@@ -111,9 +121,8 @@ int main(int argc, char *argv[])
       f1->GetPixelReadConverter()->Print();
       std::cout << std::endl << "==========================================="
                 << std::endl; 
-   }*/
-   imageData= f1->GetImageData();
-
+   }
+*/
    switch (mode[0])
    {
    case 'a' :