X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=segmentation%2FclitkFillMaskGenericFilter.h;h=f87aeaf0be82a6cb2dcb28b118990ea5e3188379;hb=5c67d77ff8ec6c967b89c262ee4d536141e504ed;hp=8a9b479fc8103844f078e8fd54852f469ff6eaa9;hpb=e008d74b0ecdc4ca2eaae8c429901a78f9ef5c31;p=clitk.git diff --git a/segmentation/clitkFillMaskGenericFilter.h b/segmentation/clitkFillMaskGenericFilter.h index 8a9b479..f87aeaf 100644 --- a/segmentation/clitkFillMaskGenericFilter.h +++ b/segmentation/clitkFillMaskGenericFilter.h @@ -1,99 +1,63 @@ -#ifndef clitkFillMaskGenericFilter_h -#define clitkFillMaskGenericFilter_h +/*========================================================================= + Program: vv http://www.creatis.insa-lyon.fr/rio/vv -/* ================================================= - * @file clitkFillMaskGenericFilter.h - * @author - * @date - * - * @brief - * - ===================================================*/ + Authors belong to: + - University of LYON http://www.universite-lyon.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 + the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + PURPOSE. See the copyright notices for more information. -// clitk include -#include "clitkFillMask_ggo.h" -#include "clitkImageCommon.h" -#include "clitkExtractImageFilter.h" + It is distributed under dual licence -//itk include -#include "itkLightObject.h" -#include "itkJoinSeriesImageFilter.h" -#include "itkBinaryThresholdImageFilter.h" -#include "itkConnectedComponentImageFilter.h" -#include "itkRelabelComponentImageFilter.h" -#include "itkThresholdImageFilter.h" -#include "itkPermuteAxesImageFilter.h" -#include "itkExtractImageFilter.h" -#include "itkCastImageFilter.h" + - BSD See included LICENSE.txt file + - CeCILL-B http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html +===========================================================================**/ +#ifndef CLITKFILLMASKGENERICFILTER_H +#define CLITKFILLMASKGENERICFILTER_H + +// clitk +#include "clitkImageToImageGenericFilter.h" +#include "clitkFillMaskFilter.h" + +//-------------------------------------------------------------------- namespace clitk { - - class ITK_EXPORT FillMaskGenericFilter : public itk::LightObject + template + class ITK_EXPORT FillMaskGenericFilter : + public ImageToImageGenericFilter > { public: - //---------------------------------------- - // ITK - //---------------------------------------- - typedef FillMaskGenericFilter Self; - typedef itk::LightObject Superclass; - typedef itk::SmartPointer Pointer; - typedef itk::SmartPointer ConstPointer; - - // Method for creation through the object factory - itkNewMacro(Self); - - // Run-time type information (and related methods) - itkTypeMacro( FillMaskGenericFilter, LightObject ); - - - //---------------------------------------- - // Typedefs - //---------------------------------------- - - - //---------------------------------------- - // Set & Get - //---------------------------------------- - void SetArgsInfo(const args_info_clitkFillMask & a) - { - m_ArgsInfo=a; - m_Verbose=m_ArgsInfo.verbose_flag; - m_InputFileName=m_ArgsInfo.input_arg; - } - - - //---------------------------------------- - // Update - //---------------------------------------- - void Update(); - - protected: - - //---------------------------------------- - // Constructor & Destructor - //---------------------------------------- + //-------------------------------------------------------------------- FillMaskGenericFilter(); - ~FillMaskGenericFilter() {}; - - - //---------------------------------------- - // Templated members - //---------------------------------------- - template void UpdateWithPixelType(); + //-------------------------------------------------------------------- + typedef FillMaskGenericFilter Self; + typedef ImageToImageGenericFilter Superclass; + typedef itk::SmartPointer Pointer; + typedef itk::SmartPointer ConstPointer; + + //-------------------------------------------------------------------- + itkNewMacro(Self); + itkTypeMacro(FillMaskGenericFilter, LightObject); - //---------------------------------------- - // Data members - //---------------------------------------- - args_info_clitkFillMask m_ArgsInfo; - bool m_Verbose; - std::string m_InputFileName; + //-------------------------------------------------------------------- + void SetArgsInfo(const ArgsInfoType & a); - }; + //-------------------------------------------------------------------- + // Main function called each time the filter is updated + template + void UpdateWithInputImageType(); + protected: + template void InitializeImageType(); + ArgsInfoType mArgsInfo; + }; // end class + //-------------------------------------------------------------------- } // end namespace clitk @@ -101,4 +65,4 @@ namespace clitk #include "clitkFillMaskGenericFilter.txx" #endif -#endif // #define clitkFillMaskGenericFilter_h +#endif // #define CLITKFILLMASKGENERICFILTER_H