]> Creatis software - clitk.git/blob - registration/clitkMatrixTransformToVFGenericFilter.h
Merge branch 'master' of git.creatis.insa-lyon.fr:clitk
[clitk.git] / registration / clitkMatrixTransformToVFGenericFilter.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 clitkMatrixTransformToVFGenericFilter_h
19 #define clitkMatrixTransformToVFGenericFilter_h
20
21 /* =================================================
22  * @file   clitkMatrixTransformToVFGenericFilter.h
23  * @author 
24  * @date   
25  * 
26  * @brief 
27  * 
28  ===================================================*/
29
30
31 // clitk include
32 #include "clitkIO.h"
33 #include "clitkCommon.h"
34 #include "clitkTransformUtilities.h"
35 #include "clitkMatrixTransformToVF_ggo.h"
36
37 //itk include
38 #include "itkLightObject.h"
39 #if ITK_VERSION_MAJOR >= 4
40 #  if ITK_VERSION_MINOR < 6
41 #    include "itkTransformToDisplacementFieldSource.h"
42 #  else
43 #    include "itkTransformToDisplacementFieldFilter.h"
44 #  endif
45 #else
46 #  include "itkTransformToDeformationFieldSource.h"
47 #endif
48 #include "itkAffineTransform.h"
49
50 namespace clitk 
51 {
52
53
54   class ITK_EXPORT MatrixTransformToVFGenericFilter : public itk::LightObject
55   {
56   public:
57     //----------------------------------------
58     // ITK
59     //----------------------------------------
60     typedef MatrixTransformToVFGenericFilter                   Self;
61     typedef itk::LightObject                   Superclass;
62     typedef itk::SmartPointer<Self>            Pointer;
63     typedef itk::SmartPointer<const Self>      ConstPointer;
64    
65     // Method for creation through the object factory
66     itkNewMacro(Self);  
67
68     // Run-time type information (and related methods)
69     itkTypeMacro( MatrixTransformToVFGenericFilter, LightObject );
70
71
72     //----------------------------------------
73     // Typedefs
74     //----------------------------------------
75
76
77     //----------------------------------------
78     // Set & Get
79     //----------------------------------------    
80     void SetArgsInfo(const args_info_clitkMatrixTransformToVF & a)
81     {
82       m_ArgsInfo=a;
83       m_Verbose=m_ArgsInfo.verbose_flag;
84     }
85     
86     
87     //----------------------------------------  
88     // Update
89     //----------------------------------------  
90     void Update();
91
92   protected:
93
94     //----------------------------------------  
95     // Constructor & Destructor
96     //----------------------------------------  
97     MatrixTransformToVFGenericFilter();
98     ~MatrixTransformToVFGenericFilter() {};
99
100     
101     //----------------------------------------  
102     // Templated members
103     //----------------------------------------  
104     template <unsigned int Dimension>  void UpdateWithDim();
105     //template <unsigned int Dimension, class PixelType>  void UpdateWithDimAndPixelType();
106
107
108     //----------------------------------------  
109     // Data members
110     //----------------------------------------
111     args_info_clitkMatrixTransformToVF m_ArgsInfo;
112     bool m_Verbose;
113
114   };
115
116
117 } // end namespace clitk
118
119 #ifndef ITK_MANUAL_INSTANTIATION
120 #include "clitkMatrixTransformToVFGenericFilter.txx"
121 #endif
122
123 #endif // #define clitkMatrixTransformToVFGenericFilter_h