]> Creatis software - clitk.git/blob - tools/clitkWarpImageGenericFilter.h
Initial revision
[clitk.git] / tools / clitkWarpImageGenericFilter.h
1 #ifndef clitkWarpImageGenericFilter_h
2 #define clitkWarpImageGenericFilter_h
3
4 /* =================================================
5  * @file   clitkWarpImageGenericFilter.h
6  * @author 
7  * @date   
8  * 
9  * @brief 
10  * 
11  ===================================================*/
12
13
14 // clitk include
15 #include "clitkIO.h"
16 #include "clitkCommon.h"
17 #include "clitkWarpImage_ggo.h"
18 #include "clitkForwardWarpImageFilter.h"
19 #include "clitkGenericInterpolator.h"
20 #include "clitkGenericVectorInterpolator.h"
21
22 //itk include
23 #include "itkLightObject.h"
24 #include "itkWarpImageFilter.h"
25 #include "itkVectorResampleImageFilter.h"
26
27 namespace clitk 
28 {
29
30
31   class ITK_EXPORT WarpImageGenericFilter : public itk::LightObject
32   {
33   public:
34     //----------------------------------------
35     // ITK
36     //----------------------------------------
37     typedef WarpImageGenericFilter                   Self;
38     typedef itk::LightObject                   Superclass;
39     typedef itk::SmartPointer<Self>            Pointer;
40     typedef itk::SmartPointer<const Self>      ConstPointer;
41    
42     // Method for creation through the object factory
43     itkNewMacro(Self);  
44
45     // Run-time type information (and related methods)
46     itkTypeMacro( WarpImageGenericFilter, LightObject );
47
48
49     //----------------------------------------
50     // Typedefs
51     //----------------------------------------
52
53
54     //----------------------------------------
55     // Set & Get
56     //----------------------------------------    
57     void SetArgsInfo(const gengetopt_args_info_clitkWarpImage & a)
58     {
59       m_ArgsInfo=a;
60       m_Verbose=m_ArgsInfo.verbose_flag;
61       m_InputFileName=m_ArgsInfo.input_arg;
62     }
63     
64     
65     //----------------------------------------  
66     // Update
67     //----------------------------------------  
68     void Update();
69
70   protected:
71
72     //----------------------------------------  
73     // Constructor & Destructor
74     //----------------------------------------  
75     WarpImageGenericFilter();
76     ~WarpImageGenericFilter() {};
77
78     
79     //----------------------------------------  
80     // Templated members
81     //----------------------------------------  
82     template <unsigned int Dimension>  void UpdateWithDim(std::string PixelType);
83     template <unsigned int Dimension, class PixelType>  void UpdateWithDimAndPixelType();
84
85
86     //----------------------------------------  
87     // Data members
88     //----------------------------------------
89     gengetopt_args_info_clitkWarpImage m_ArgsInfo;
90     bool m_Verbose;
91     std::string m_InputFileName;
92
93   };
94
95
96 } // end namespace clitk
97
98 #ifndef ITK_MANUAL_INSTANTIATION
99 #include "clitkWarpImageGenericFilter.txx"
100 #endif
101
102 #endif // #define clitkWarpImageGenericFilter_h