]> Creatis software - clitk.git/commitdiff
clitkVectorImageToImage bug correction
authorBenoît Presles <benoit.presles@creatis.insa-lyon.fr>
Fri, 14 Jun 2013 17:01:00 +0000 (19:01 +0200)
committerBenoît Presles <benoit.presles@creatis.insa-lyon.fr>
Fri, 14 Jun 2013 17:01:00 +0000 (19:01 +0200)
tools/clitkVectorImageToImageGenericFilter.txx

index cb5effe22a5949ead40c8cb5613fda31bc41357e..b1cf3f973be3b6fda50b0eabb0939c5b9dab9abd 100644 (file)
@@ -42,8 +42,13 @@ namespace clitk
 
     if (Components==3)
       {
-         if (m_Verbose) std::cout  << "Launching filter in "<< Dimension <<"D and 3D float..." << std::endl;
-         UpdateWithDimAndPixelType<Dimension, itk::Vector<float, 3> >();
+        if (PixelType == "unsigned_char")
+            UpdateWithDimAndPixelType<Dimension, itk::Vector<unsigned char, 3> >();
+        else
+        {
+            if (m_Verbose) std::cout  << "Launching filter in "<< Dimension <<"D and 3D float..." << std::endl;
+            UpdateWithDimAndPixelType<Dimension, itk::Vector<float, 3> >();
+        }
       }
     else std::cerr<<"Number of components is "<<Components<<", not supported!"<<std::endl;
   }