X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=segmentation%2FclitkMotionMaskGenericFilter.txx;h=56fadac84f5e977f016677a0cd68bce42470e62c;hb=5c5fc58e0cbdcec1c9fdd19ec786912cb38d1722;hp=0edf047f368778f2e62a5002ce5ed5c020f3e44b;hpb=66bd2423675397defe90b79586d04cbe30dfd282;p=clitk.git diff --git a/segmentation/clitkMotionMaskGenericFilter.txx b/segmentation/clitkMotionMaskGenericFilter.txx old mode 100755 new mode 100644 index 0edf047..56fadac --- a/segmentation/clitkMotionMaskGenericFilter.txx +++ b/segmentation/clitkMotionMaskGenericFilter.txx @@ -3,7 +3,7 @@ Authors belong to: - University of LYON http://www.universite-lyon.fr/ - - Léon Bérard cancer center http://oncora1.lyon.fnclcc.fr + - Léon Bérard cancer center http://www.centreleonberard.fr - CREATIS CNRS laboratory http://www.creatis.insa-lyon.fr This software is distributed WITHOUT ANY WARRANTY; without even @@ -14,7 +14,7 @@ - BSD See included LICENSE.txt file - CeCILL-B http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html -======================================================================-====*/ +===========================================================================**/ #ifndef clitkMotionMaskGenericFilter_txx #define clitkMotionMaskGenericFilter_txx @@ -377,6 +377,8 @@ MotionMaskGenericFilter::GetLungsImage(typename itk::Image connectFilter->SetBackgroundValue(0); connectFilter->SetFullyConnected(true); if (m_Verbose) std::cout<<"Labeling the connected components..."<Update(); + if (m_Verbose) std::cout<<"found "<< connectFilter->GetObjectCount() << std::endl; //--------------------------------- // Sort the labels according to size @@ -384,7 +386,7 @@ MotionMaskGenericFilter::GetLungsImage(typename itk::Image typename RelabelFilterType::Pointer relabelFilter=RelabelFilterType::New(); relabelFilter->SetInput(connectFilter->GetOutput()); if (m_Verbose) std::cout<<"Sorting the labels..."< (relabelFilter->GetOutput(), "/home/jef/tmp/labels.mhd"); + // writeImage (relabelFilter->GetOutput(), "/home/vdelmon/tmp/labels.mhd"); //--------------------------------- // Keep the label @@ -944,6 +946,10 @@ MotionMaskGenericFilter::UpdateWithDimAndPixelType() distanceMapImageFilter->SetInsideIsPositive(false); if (m_Verbose) std::cout<<"Calculating the distance map..."<Update(); + if (m_ArgsInfo.writeDistMap_given) { + writeImage(distanceMapImageFilter->GetOutput(), m_ArgsInfo.writeDistMap_arg, m_Verbose); + + } //--------------------------------- // Grow while monitoring detection point