1 // =========================================================================
2 // @author Leonardo Florez Valencia
3 // @email florez-l@javeriana.edu.co
4 // =========================================================================
6 #ifndef __fpa__Base__Algorithm__h__
7 #define __fpa__Base__Algorithm__h__
17 template< class _TFilter, class _TMarksInterface, class _TSeedsInterface >
20 public _TMarksInterface,
21 public _TSeedsInterface
24 typedef Algorithm Self;
25 typedef _TFilter Superclass;
26 typedef _TMarksInterface TMarksInterface;
27 typedef _TSeedsInterface TSeedsInterface;
28 typedef itk::SmartPointer< Self > Pointer;
29 typedef itk::SmartPointer< const Self > ConstPointer;
31 typedef typename _TMarksInterface::TNode TNode;
32 typedef typename _TMarksInterface::TOutputValue TOutputValue;
33 typedef typename _TSeedsInterface::TSeeds TSeeds;
35 typedef std::vector< TNode > TNeighborhood;
38 itkTypeMacro( Algorithm, TFilter );
40 itkGetConstMacro( InitValue, TOutputValue );
41 itkSetMacro( InitValue, TOutputValue );
45 virtual ~Algorithm( );
47 virtual void GenerateData( ) override;
49 virtual void _ConfigureOutput( const TOutputValue& v ) = 0;
50 virtual void _QueueInit( ) = 0;
51 virtual void _QueuePush( const TNode& node ) = 0;
52 virtual unsigned long _QueueSize( ) const = 0;
53 virtual TNode _QueuePop( ) = 0;
56 // Purposely not implemented
57 Algorithm( const Self& other );
58 Self& operator=( const Self& other );
61 TOutputValue m_InitValue;
68 #ifndef ITK_MANUAL_INSTANTIATION
69 # include <fpa/Base/Algorithm.hxx>
70 #endif // ITK_MANUAL_INSTANTIATION
72 #endif // __fpa__Base__Algorithm__h__