// ========================================================================= // @author Leonardo Florez Valencia // @email florez-l@javeriana.edu.co // ========================================================================= #ifndef __CTBronchi__MoriLabelling__h__ #define __CTBronchi__MoriLabelling__h__ #include #include #include #include #include #include /* TODO #include #include #include #include #include #include */ namespace CTBronchi { /** */ template< class _TInputImage, class _TLabelImage > class MoriLabellingTraits : public fpa::Filters::Image::DefaultTraits< _TInputImage, _TLabelImage, typename _TLabelImage::PixelType > { public: typedef _TInputImage TInputImage; typedef _TLabelImage TLabelImage; typedef fpa::Filters::Image::DefaultTraits< TInputImage, TLabelImage, typename TLabelImage::PixelType > Superclass; typedef typename Superclass::TInternalTraits TInternalTraits; typedef typename Superclass::TFilter TFilter; typedef fpa::Filters::MarksInterface< TInternalTraits > TMarksInterface; typedef fpa::Filters::Image::LabelsSeedInterface< TInternalTraits > TSeedsInterface; }; /** */ template< class _TInputImage, class _TLabelImage > class MoriLabelling : public fpa::Filters::Image::LabelsSeedFilter< fpa::Filters::Image::Algorithm< fpa::Filters::RegionGrow< CTBronchi::MoriLabellingTraits< _TInputImage, _TLabelImage > > >, _TLabelImage > { public: typedef _TInputImage TInputImage; typedef _TLabelImage TLabelImage; typedef CTBronchi::MoriLabellingTraits< TInputImage, TLabelImage > TTraits; fpaTraitsMacro( typename, TTraits ); typedef fpa::Filters::Image::Algorithm< fpa::Filters::RegionGrow< TTraits > > TAlgorithm; typedef fpa::Filters::Image::LabelsSeedFilter< TAlgorithm, _TLabelImage > Superclass; typedef MoriLabelling Self; typedef itk::SmartPointer< Self > Pointer; typedef itk::SmartPointer< const Self > ConstPointer; typedef fpa::Functors::RegionGrow::BinaryThreshold< TInputValue > TLabelFunctor; public: itkNewMacro( Self ); itkTypeMacro( CTBronchi::MoriLabelling, fpa::Filters::Image::RegionGrow ); public: TInputValue GetUpperThreshold( ) const; void SetUpperThreshold( TInputValue t ); protected: MoriLabelling( ); virtual ~MoriLabelling( ); virtual void _UpdateOutputValue( TNode& n ) override; private: // Purposely not implemented. MoriLabelling( const Self& other ); Self& operator=( const Self& other ); protected: typename TLabelFunctor::Pointer m_LabelFunctor; }; } // ecapseman #ifndef ITK_MANUAL_INSTANTIATION # include #endif // ITK_MANUAL_INSTANTIATION #endif // __CTBronchi__MoriLabelling__h__ // eof - $RCSfile$