]> Creatis software - gdcm.git/blobdiff - src/gdcmFileHelper.cxx
RLEFrame RLEFramesInfo declare File as friend.
[gdcm.git] / src / gdcmFileHelper.cxx
index 49a6e9e315257d0ada7e5c8aae54c3aa4c5c9f6a..4da69db53f718787e65e02417626998a89e7d833 100644 (file)
@@ -4,8 +4,8 @@
   Module:    $RCSfile: gdcmFileHelper.cxx,v $
   Language:  C++
 
-  Date:      $Date: 2005/11/07 09:50:52 $
-  Version:   $Revision: 1.79 $
+  Date:      $Date: 2005/11/18 11:42:48 $
+  Version:   $Revision: 1.82 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -114,6 +114,7 @@ fh1->Write(newFileName);
 
 namespace gdcm 
 {
+typedef std::map<uint16_t, int> GroupHT;    //  Hash Table
 //-------------------------------------------------------------------------
 // Constructor / Destructor
 /**
@@ -1525,8 +1526,9 @@ void FileHelper::CheckMandatoryElements()
    
    // Patient Orientation
    // Can be computed from (0020|0037) :  Image Orientation (Patient)
-   gdcm::Orientation o;
-   std::string ori = o.GetOrientation ( FileInternal );
+   gdcm::Orientation *o = gdcm::Orientation::New();
+   std::string ori = o->GetOrientation ( FileInternal );
+   o->Delete();
    if (ori != "\\" )
       CheckMandatoryEntry(0x0020,0x0020,ori);
    else   
@@ -1566,15 +1568,16 @@ void FileHelper::CheckMandatoryElements()
    {
       Archive->Push(0x0020, 0x0052);
    }
-   
    // Deal with element 0x0000 (group length) of each group.
    // First stage : get all the different Groups
+ /*
   GroupHT grHT;
-  DocEntry *d=input->GetFirstEntry();
+  DocEntry *d = FileInternal->GetFirstEntry();
   while(d)
   {
     grHT[d->GetGroup()] = 0;
-    d=input->GetNextEntry();
+    d=FileInternal->GetNextEntry();
   }
   // Second stage : add the missing ones (if any)
   for (GroupHT::iterator it = grHT.begin(); it != grHT.end(); ++it)  
@@ -1582,7 +1585,7 @@ void FileHelper::CheckMandatoryElements()
       CheckMandatoryEntry(it->first, 0x0000, "0"); 
   }    
   // Third stage : update all 'zero level' groups length
-   
+*/   
 } 
 
 void FileHelper::CheckMandatoryEntry(uint16_t group,uint16_t elem,std::string value)