#include <functional>
#include <set>
+#include <vector>
#include <itkConceptChecking.h>
#include <itkProcessObject.h>
{
/**
*/
- template< class _TVertex, class _TInputValue, class _TOutputValue, class _TFrontId, class _TCompare = std::greater< _TVertex > >
+ template< class _TVertex, class _TPoint, class _TInputValue, class _TOutputValue, class _TFrontId, class _TCompare = std::greater< _TVertex > >
class SeedsInterface
{
public:
public:
typedef _TVertex TVertex;
+ typedef _TPoint TPoint;
typedef _TInputValue TInputValue;
typedef _TOutputValue TOutputValue;
typedef _TFrontId TFrontId;
typedef _TCompare TCompare;
typedef SeedsInterface Self;
+ struct TSeed
+ {
+ TVertex Vertex;
+ TPoint Point;
+ bool IsPoint;
+ bool IsUnified;
+ TSeed( ) : IsUnified( false ) { }
+ };
+ typedef std::vector< TSeed > TSeeds;
+
struct TNode
{
TVertex Vertex;
return( cmp( a.Vertex, b.Vertex ) );
}
};
- typedef std::set< TNode, TNodeCompare > TSeeds;
+ typedef std::set< TNode, TNodeCompare > TNodes;
public:
- unsigned int GetNumberOfSeeds( ) const;
const TSeeds& GetSeeds( ) const;
- typename TSeeds::const_iterator BeginSeeds( ) const;
- typename TSeeds::const_iterator EndSeeds( ) const;
virtual void AddSeed( const TVertex& seed );
- virtual void RemoveSeed( const TVertex& seed );
+ virtual void AddSeed( const TPoint& seed );
virtual void ClearSeeds( );
protected:
SeedsInterface( itk::ProcessObject* filter );
virtual ~SeedsInterface( );
+ virtual TNodes _UnifySeeds( ) = 0;
+ virtual void _PrepareSeeds( TNodes& nodes ) = 0;
+
protected:
TSeeds m_Seeds;
itk::ProcessObject* m_Filter;