]> Creatis software - gdcm.git/commitdiff
According to Mathieu's suggestion, Print now display FL BinEntries in a human
authorjpr <jpr>
Thu, 25 Aug 2005 13:45:40 +0000 (13:45 +0000)
committerjpr <jpr>
Thu, 25 Aug 2005 13:45:40 +0000 (13:45 +0000)
readable form

src/gdcmBinEntry.cxx

index 25748140d092289c461e169b2856c6ca1ab6dcd6..3f2325e39bdac0d58f0ce7759df9b88394b1c41b 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: gdcmBinEntry.cxx,v $
   Language:  C++
-  Date:      $Date: 2005/03/02 17:15:52 $
-  Version:   $Revision: 1.72 $
+  Date:      $Date: 2005/08/25 13:45:40 $
+  Version:   $Revision: 1.73 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -143,8 +143,24 @@ void BinEntry::Print(std::ostream &os, std::string const & )
    void* binArea = GetBinArea();
    if (binArea)
    {
-      s << " [" << GetValue()
-        << "; length = " << GetLength() << "]";
+      if ( GetVR() == "FL" )
+      {
+         int l = GetReadLength()/4 - 1;
+         float *beg = (float *)GetBinArea();
+         s << " [" << *beg;
+         if ( l!= 0)
+            for (int i=0;i<l;i++)
+            {
+               beg++;
+               s << "\\" << *beg;
+            }
+            s << "]";
+      }
+      else
+      {
+         s << " [" << GetValue()
+           << "; length = " << GetLength() << "]";
+      }
    }
    else
    {