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://oncora1.lyon.fnclcc.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 ======================================================================-====*/
19 #ifndef CLITKIMAGERESAMPLEGENERICFILTER_H
20 #define CLITKIMAGERESAMPLEGENERICFILTER_H
23 #include "clitkImageToImageGenericFilter.h"
27 //--------------------------------------------------------------------
28 class ImageResampleGenericFilter:
29 public ImageToImageGenericFilter<ImageResampleGenericFilter> {
33 ImageResampleGenericFilter();
36 typedef ImageResampleGenericFilter Self;
37 typedef itk::SmartPointer<Self> Pointer;
38 typedef itk::SmartPointer<const Self> ConstPointer;
43 void SetOutputSize(const std::vector<int> & size);
44 void SetOutputSpacing(const std::vector<double> & spacing);
45 void SetGaussianSigma(const std::vector<double> & sigma);
46 void SetInterpolationName(const std::string & inter);
47 void SetDefaultPixelValue(double dpv) { mDefaultPixelValue = dpv;}
48 void SetBSplineOrder(int o) { mBSplineOrder = o; }
49 void SetBLUTSampling(int b) { mSamplingFactors.resize(1); mSamplingFactors[0] = b; }
51 //--------------------------------------------------------------------
52 template<class InputImageType> void UpdateWithInputImageType();
55 //--------------------------------------------------------------------
56 std::string mInterpolatorName;
57 std::vector<int> mOutputSize;
58 std::vector<double> mOutputSpacing;
59 std::vector<double> mOutputOrigin;
60 double mDefaultPixelValue;
61 bool mApplyGaussianFilterBefore;
62 std::vector<double> mSigma;
64 std::vector<int> mSamplingFactors;
66 //--------------------------------------------------------------------
67 template<unsigned int Dim> void InitializeImageTypeWithDim();
69 }; // end class ImageResampleGenericFilter
70 //--------------------------------------------------------------------
72 //#include "clitkImageResampleGenericFilter.txx"
75 //--------------------------------------------------------------------
77 #endif /* end #define CLITKIMAGERESAMPLEGENERICFILTER_H */