]> Creatis software - clitk.git/blob - registration/clitkMultiResolutionPyramidRegionFilter.h
Debug RTStruct conversion with empty struc
[clitk.git] / registration / clitkMultiResolutionPyramidRegionFilter.h
1 /*=========================================================================
2   Program:   vv                     http://www.creatis.insa-lyon.fr/rio/vv
3
4   Authors belong to: 
5   - University of LYON              http://www.universite-lyon.fr/
6   - Léon Bérard cancer center       http://www.centreleonberard.fr
7   - CREATIS CNRS laboratory         http://www.creatis.insa-lyon.fr
8
9   This software is distributed WITHOUT ANY WARRANTY; without even
10   the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
11   PURPOSE.  See the copyright notices for more information.
12
13   It is distributed under dual licence
14
15   - BSD        See included LICENSE.txt file
16   - CeCILL-B   http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html
17 ===========================================================================**/
18 #ifndef clitkMultiResolutionPyramidRegionFilter_h
19 #define clitkMultiResolutionPyramidRegionFilter_h
20
21 /* =================================================
22  * @file   clitkMultiResolutionPyramidRegionFilter.h
23  * @author 
24  * @date   
25  * 
26  * @brief 
27  * 
28  ===================================================*/
29
30
31 // clitk include
32 #include "clitkIO.h"
33 #include "clitkCommon.h"
34
35 //itk include
36 #include "itkLightObject.h"
37
38 namespace clitk 
39 {
40
41   template <class InputImageType>
42   class ITK_EXPORT MultiResolutionPyramidRegionFilter :
43     public itk::LightObject
44   {
45   public:
46     //----------------------------------------
47     // ITK
48     //----------------------------------------
49     typedef MultiResolutionPyramidRegionFilter                                                 Self;
50     typedef itk::LightObject                                          Superclass;
51     typedef itk::SmartPointer<Self>                                   Pointer;
52     typedef itk::SmartPointer<const Self>                             ConstPointer;
53    
54     // Method for creation through the object factory
55     itkNewMacro(Self);  
56
57     // Run-time type information (and related methods)
58     itkTypeMacro( MultiResolutionPyramidRegionFilter, LightObject );
59
60     /** Dimension of the domain space. */
61     itkStaticConstMacro(InputImageDimension, unsigned int, InputImageType::ImageDimension);
62
63
64     //----------------------------------------
65     // Typedefs
66     //----------------------------------------
67     typedef itk::ImageRegion<InputImageDimension> RegionType;
68     typedef itk::Array2D<unsigned int>  ScheduleType;
69     typedef typename InputImageType::SizeType SizeType;
70     typedef typename InputImageType::IndexType IndexType;
71
72     //----------------------------------------
73     // Set & Get
74     //----------------------------------------    
75     void SetRegion(RegionType r){m_Region=r;}
76     void SetSchedule(ScheduleType r){m_Schedule=r;}
77
78     //----------------------------------------  
79     // Update
80     //----------------------------------------  
81     void Update(void);
82     RegionType GetOutput(unsigned int i)
83     {
84       this->Update();
85       return m_RegionPyramid[i];
86     }
87       
88
89   protected:
90
91     //----------------------------------------  
92     // Constructor & Destructor
93     //----------------------------------------  
94     MultiResolutionPyramidRegionFilter();
95     ~MultiResolutionPyramidRegionFilter() {};
96
97     //----------------------------------------  
98     // Data members
99     //----------------------------------------
100     RegionType m_Region;
101     std::vector<RegionType>  m_RegionPyramid;
102     ScheduleType m_Schedule;
103
104   };
105
106
107 } // end namespace clitk
108
109 #ifndef ITK_MANUAL_INSTANTIATION
110 #include "clitkMultiResolutionPyramidRegionFilter.txx"
111 #endif
112
113 #endif // #define clitkMultiResolutionPyramidRegionFilter_h
114
115