]> Creatis software - bbtk.git/commitdiff
mhb
authorEduardo DAVILA <eduardo.davila@creatis.insa-lyon.fr>
Tue, 24 Nov 2020 09:26:08 +0000 (10:26 +0100)
committerEduardo DAVILA <eduardo.davila@creatis.insa-lyon.fr>
Tue, 24 Nov 2020 09:26:08 +0000 (10:26 +0100)
packages/vtk/src/bbvtkMetaImageWriter.cxx

index ee36755520ce11670fa6acf0a97fc3095d9a9b0e..f17001ef72b3135a56044875f53de0fb55e75fde 100644 (file)
@@ -85,15 +85,16 @@ void MetaImageWriter::Save_mhdb( std::string filename  , vtkImageData* img ,int
                                w->Write();
                                w->Delete();
                                
+/* Borrame
                                filenameBlockVti=filenameBlock+"-ZLib.vti";
                                vtkXMLImageDataWriter *writer = vtkXMLImageDataWriter::New();
                                writer->SetDataModeToBinary();
-                               writer->SetCompressionLevel(5);
+//                             writer->SetCompressionLevel(5);
                                writer->SetCompressorTypeToZLib();
                                writer->SetFileName( filenameBlockVti.c_str() );
                                writer->SetInputData( bbGetInputIn() );
                                writer->Write();
-
+*/
                                
                                extract->Delete();
                        } // for k
@@ -136,10 +137,10 @@ printf("EED vtkMetaImageWriter::Process  START\n");
                { 
                        Save_mhdb( userGivenName , bbGetInputIn() , bbGetInputSizeBlock() );
                } else {
-                               if (userGivenName.substr(userGivenName.size()-4) != ".mhd")  //JPR
+                               if (!((userGivenName.substr(userGivenName.size()-4) == ".mhd") || (userGivenName.substr(userGivenName.size()-4) == ".mha")))  //JPR
                                { 
                                        userGivenName += ".mhd";
-                               }
+                               } 
                           vtkMetaImageWriter* w = vtkMetaImageWriter::New();
        //EED 2017-01-01 Migration VTK7
        #if VTK_MAJOR_VERSION <= 5