]> Creatis software - FrontAlgorithms.git/blob - lib/fpa/Base/ExtractPathFromMinimumSpanningTree.h
...
[FrontAlgorithms.git] / lib / fpa / Base / ExtractPathFromMinimumSpanningTree.h
1 #ifndef __FPA__BASE__EXTRACTPATHFROMMINIMUMSPANNINGTREE__H__
2 #define __FPA__BASE__EXTRACTPATHFROMMINIMUMSPANNINGTREE__H__
3
4 #include <set>
5 #include <fpa/Base/VectorValuesContainer.h>
6 #include <itkProcessObject.h>
7 #include <itkPolyLineParametricPath.h>
8
9 namespace fpa
10 {
11   namespace Base
12   {
13     /**
14      */
15     template< class T >
16     class ExtractPathFromMinimumSpanningTree
17       : public itk::ProcessObject
18     {
19     public:
20       typedef ExtractPathFromMinimumSpanningTree Self;
21       typedef itk::ProcessObject                 Superclass;
22       typedef itk::SmartPointer< Self >          Pointer;
23       typedef itk::SmartPointer< const Self >    ConstPointer;
24
25       typedef T                                  TMinimumSpanningTree;
26       typedef typename T::TVertex                             TVertex;
27       typedef itk::PolyLineParametricPath< TVertex::Dimension > TPath;
28
29     public:
30       itkNewMacro( Self );
31       itkTypeMacro( ExtractPathFromMinimumSpanningTree, itk::ProcessObject );
32
33       itkGetConstMacro( Vertex0, TVertex );
34       itkGetConstMacro( Vertex1, TVertex );
35
36       itkSetMacro( Vertex0, TVertex );
37       itkSetMacro( Vertex1, TVertex );
38
39     public:
40       const T* GetInput( ) const;
41       void SetInput( const T* tree );
42
43       TPath* GetOutput( );
44
45     protected:
46       ExtractPathFromMinimumSpanningTree( );
47       virtual ~ExtractPathFromMinimumSpanningTree( );
48
49       virtual void GenerateData( );
50
51     private:
52       // Purposely not implemented
53       ExtractPathFromMinimumSpanningTree( const Self& other );
54       Self& operator=( const Self& other );
55
56     protected:
57       TVertex m_Vertex0;
58       TVertex m_Vertex1;
59     };
60
61   } // ecapseman
62
63 } // ecapseman
64
65 #ifndef ITK_MANUAL_INSTANTIATION
66 #include <fpa/Base/ExtractPathFromMinimumSpanningTree.hxx>
67 #endif // ITK_MANUAL_INSTANTIATION
68
69 #endif // __FPA__BASE__EXTRACTPATHFROMMINIMUMSPANNINGTREE__H__
70
71 // eof - $RCSfile$