1 // =========================================================================
2 // @author Leonardo Florez Valencia
3 // @email florez-l@javeriana.edu.co
4 // =========================================================================
6 #ifndef __fpa__Image__Mori__h__
7 #define __fpa__Image__Mori__h__
9 #include <fpa/Base/Mori.h>
10 #include <fpa/Base/MarksInterface.h>
11 #include <fpa/Base/SingleSeedInterface.h>
12 #include <fpa/Image/Algorithm.h>
13 #include <fpa/Image/DefaultTraits.h>
21 template< class _TInputImage, class _TOutputImage >
23 : public fpa::Image::DefaultTraits< _TInputImage, _TOutputImage, typename _TOutputImage::PixelType >
26 typedef MoriTraits Self;
27 typedef _TInputImage TInputImage;
28 typedef _TOutputImage TOutputImage;
29 typedef typename TOutputImage::PixelType TFrontId;
30 typedef fpa::Image::DefaultTraits< TInputImage, TOutputImage, TFrontId > Superclass;
32 typedef typename Superclass::TVertex TVertex;
33 typedef typename Superclass::TInputValue TInputValue;
34 typedef typename Superclass::TPoint TPoint;
35 typedef typename Superclass::TOutputValue TOutputValue;
36 typedef typename Superclass::TCompare TCompare;
37 typedef typename Superclass::TNeighborhood TNeighborhood;
38 typedef typename Superclass::TFilter TFilter;
40 typedef fpa::Base::SingleSeedInterface< TVertex, TPoint, TInputValue, TOutputValue, TFrontId, TCompare > TSeedsInterface;
41 typedef fpa::Base::MarksInterface< TVertex > TMarksInterface;
43 typedef typename TSeedsInterface::TNode TNode;
44 typedef typename TSeedsInterface::TNodes TNodes;
45 typedef typename TSeedsInterface::TSeed TSeed;
46 typedef typename TSeedsInterface::TSeeds TSeeds;
49 // Purposely not implemented.
51 MoriTraits( const Self& other );
52 virtual ~MoriTraits( );
53 Self& operator=( const Self& other );
58 template< class _TInputImage, class _TOutputImage >
60 : public fpa::Base::Mori< fpa::Image::Algorithm< fpa::Image::MoriTraits< _TInputImage, _TOutputImage > > >
63 typedef _TInputImage TInputImage;
64 typedef _TOutputImage TOutputImage;
65 typedef fpa::Image::MoriTraits< TInputImage, TOutputImage > TTraits;
66 typedef fpa::Image::Algorithm< TTraits > TAlgorithm;
69 typedef fpa::Base::Mori< TAlgorithm > Superclass;
70 typedef itk::SmartPointer< Self > Pointer;
71 typedef itk::SmartPointer< const Self > ConstPointer;
73 typedef typename TAlgorithm::TMarks TMarks;
77 itkTypeMacro( fpa::Image::Mori, fpa::Base::Mori );
80 TOutputImage* GetThresholdedOutput( );
81 const TOutputImage* GetThresholdedOutput( ) const;
87 virtual void _AfterGenerateData( ) override;
90 // Purposely not implemented.
91 Mori( const Self& other );
92 Self& operator=( const Self& other );
95 unsigned long m_ThresholdedOutputIdx;
102 #ifndef ITK_MANUAL_INSTANTIATION
103 # include <fpa/Image/Mori.hxx>
104 #endif // ITK_MANUAL_INSTANTIATION
106 #endif // __fpa__Image__Mori__h__