1 /*=========================================================================
2 Program: vv http://www.creatis.insa-lyon.fr/rio/vv
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
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.
13 It is distributed under dual licence
15 - BSD See included LICENSE.txt file
16 - CeCILL-B http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html
17 ===========================================================================**/
18 #ifndef clitkAffineTransformGenericFilter_h
19 #define clitkAffineTransformGenericFilter_h
21 /* =================================================
22 * @file clitkAffineTransformGenericFilter.h
23 * @author jefvdmb@gmail.com
28 ===================================================*/
33 #include "clitkCommon.h"
34 #include "clitkAffineTransform_ggo.h"
35 #include "clitkTransformUtilities.h"
36 #include "clitkGenericInterpolator.h"
37 #include "clitkGenericVectorInterpolator.h"
40 #include "itkLightObject.h"
41 #include "itkAffineTransform.h"
42 #include "itkResampleImageFilter.h"
43 #include "itkVectorResampleImageFilter.h"
50 template<class args_info_type>
51 class ITK_EXPORT AffineTransformGenericFilter : public itk::LightObject
54 //----------------------------------------
56 //----------------------------------------
57 typedef AffineTransformGenericFilter Self;
58 typedef itk::LightObject Superclass;
59 typedef itk::SmartPointer<Self> Pointer;
60 typedef itk::SmartPointer<const Self> ConstPointer;
62 // Method for creation through the object factory
65 // Run-time type information (and related methods)
66 itkTypeMacro( AffineTransformGenericFilter, LightObject );
69 //----------------------------------------
71 //----------------------------------------
74 //----------------------------------------
76 //----------------------------------------
77 void SetArgsInfo(const args_info_type & a)
80 m_Verbose=m_ArgsInfo.verbose_flag;
81 m_InputFileName=m_ArgsInfo.input_arg;
85 //----------------------------------------
87 //----------------------------------------
91 //----------------------------------------
92 // Compute bounding box
93 //----------------------------------------
94 vnl_vector<double> ComputeSize(vnl_vector<double> inputSize, vnl_matrix<double> transformationMatrix, bool returnMin);
98 //----------------------------------------
99 // Constructor & Destructor
100 //----------------------------------------
101 AffineTransformGenericFilter();
102 ~AffineTransformGenericFilter() {};
105 //----------------------------------------
107 //----------------------------------------
108 template <unsigned int Dimension> void UpdateWithDim(std::string PixelType, int Components);
109 template <unsigned int Dimension, class PixelType> void UpdateWithDimAndPixelType();
110 template <unsigned int Dimension, class PixelType> void UpdateWithDimAndVectorType();
112 //----------------------------------------
114 //----------------------------------------
115 args_info_type m_ArgsInfo;
117 std::string m_InputFileName;
122 } // end namespace clitk
124 #ifndef ITK_MANUAL_INSTANTIATION
125 #include "clitkAffineTransformGenericFilter.txx"
128 #endif // #define clitkAffineTransformGenericFilter_h