]> Creatis software - gdcm.git/commitdiff
Fix Z dimension bug
authorjpr <jpr>
Thu, 28 Apr 2005 14:32:54 +0000 (14:32 +0000)
committerjpr <jpr>
Thu, 28 Apr 2005 14:32:54 +0000 (14:32 +0000)
Thx to Benoit for reporting it

vtk/vtkGdcmReader.cxx

index db2e605d7a2938250a3fb881c0094a0f5edc2abf..bb13548d7d781aae6d3e864083e5c553019c5163 100644 (file)
@@ -3,8 +3,8 @@
   Program:   gdcm
   Module:    $RCSfile: vtkGdcmReader.cxx,v $
   Language:  C++
-  Date:      $Date: 2005/04/28 09:29:05 $
-  Version:   $Revision: 1.69 $
+  Date:      $Date: 2005/04/28 14:32:54 $
+  Version:   $Revision: 1.70 $
                                                                                 
   Copyright (c) CREATIS (Centre de Recherche et d'Applications en Traitement de
   l'Image). All rights reserved. See Doc/License.txt or
@@ -83,7 +83,7 @@
 #include <vtkPointData.h>
 #include <vtkLookupTable.h>
 
-vtkCxxRevisionMacro(vtkGdcmReader, "$Revision: 1.69 $");
+vtkCxxRevisionMacro(vtkGdcmReader, "$Revision: 1.70 $");
 vtkStandardNewMacro(vtkGdcmReader);
 
 //-----------------------------------------------------------------------------
@@ -745,7 +745,10 @@ int vtkGdcmReader::CheckFileCoherenceLight()
    }
    int NX           = GdcmFile.GetXSize();
    int NY           = GdcmFile.GetYSize();
-   int NZ           = GdcmFile.GetZSize();
+   // CheckFileCoherenceLight should be called *only* when user knows
+   // he deals with single frames files.
+   // Z size is then the number of files.
+   int NZ           = InternalFileNameList.size();
    std::string type = GdcmFile.GetPixelType();
    vtkDebugMacro(<< "The first file is taken as reference: "
                  << filename->c_str());