SimpleITK  
sitkWarpImageFilter.h
Go to the documentation of this file.
1 /*=========================================================================
2 *
3 * Copyright NumFOCUS
4 *
5 * Licensed under the Apache License, Version 2.0 (the "License");
6 * you may not use this file except in compliance with the License.
7 * You may obtain a copy of the License at
8 *
9 * http://www.apache.org/licenses/LICENSE-2.0.txt
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
16 *
17 *=========================================================================*/
18 #ifndef sitkWarpImageFilter_h
19 #define sitkWarpImageFilter_h
20 
21 /*
22  * WARNING: DO NOT EDIT THIS FILE!
23  * THIS FILE IS AUTOMATICALLY GENERATED BY THE SIMPLEITK BUILD PROCESS.
24  * Please look at sitkDualImageFilterTemplate.h.in to make changes.
25  */
26 
27 #include <memory>
28 
29 #include "sitkImageFilter.h"
31 #include "sitkBasicFilters.h"
32 
33 namespace itk::simple {
34 
65  public:
67 
69  virtual ~WarpImageFilter();
70 
74 
77 
78 \
79 
83  SITK_RETURN_SELF_TYPE_HEADER SetInterpolator ( InterpolatorEnum Interpolator ) { this->m_Interpolator = Interpolator; return *this; }
84 
88  InterpolatorEnum GetInterpolator() const { return this->m_Interpolator; }\
89 
93  SITK_RETURN_SELF_TYPE_HEADER SetOutputSize ( std::vector<uint32_t> OutputSize ) { this->m_OutputSize = std::move(OutputSize); return *this; }
94 
98  std::vector<uint32_t> GetOutputSize() const { return this->m_OutputSize; }\
99 
103  SITK_RETURN_SELF_TYPE_HEADER SetOutputOrigin ( std::vector<double> OutputOrigin ) { this->m_OutputOrigin = std::move(OutputOrigin); return *this; }
104 
108  std::vector<double> GetOutputOrigin() const { return this->m_OutputOrigin; }\
109 
113  SITK_RETURN_SELF_TYPE_HEADER SetOutputSpacing ( std::vector<double> OutputSpacing ) { this->m_OutputSpacing = std::move(OutputSpacing); return *this; }
114 
118  std::vector<double> GetOutputSpacing() const { return this->m_OutputSpacing; }\
119 
123  SITK_RETURN_SELF_TYPE_HEADER SetOutputDirection ( std::vector<double> OutputDirection ) { this->m_OutputDirection = OutputDirection; return *this; }
124 
128  std::vector<double> GetOutputDirection() const { return this->m_OutputDirection; }\
129 
133  SITK_RETURN_SELF_TYPE_HEADER SetEdgePaddingValue ( double EdgePaddingValue ) { this->m_EdgePaddingValue = EdgePaddingValue; return *this; }
134 
138  double GetEdgePaddingValue() const { return this->m_EdgePaddingValue; }
139 
141  std::string GetName() const { return std::string ("WarpImageFilter"); }
142 
144  std::string ToString() const;
145 
146 
149  Image Execute ( const Image & image, const Image & displacementField );
150 
151 
153  void SetOutputParameteresFromImage(const Image & refImage );
154 
155 
156  private:
158  using MemberFunctionType = Image (Self::*)( const Image * image, const Image * displacementField );
159 
161  template <class TImageType1, class TImageType2> Image DualExecuteInternal ( const Image * image, const Image * displacementField );
163  template <class TImageType1, class TImageType2> Image DualExecuteInternalVector ( const Image * image, const Image * displacementField );
164 
165  std::unique_ptr<detail::DualMemberFunctionFactory<MemberFunctionType> > m_DualMemberFactory;
166 
167 
168 
169  /* */
171 
172  /* */
173  std::vector<uint32_t> m_OutputSize{std::vector<uint32_t>(3, 0)};
174 
175  /* */
176  std::vector<double> m_OutputOrigin{std::vector<double>(3, 0.0)};
177 
178  /* */
179  std::vector<double> m_OutputSpacing{std::vector<double>(3, 1.0)};
180 
181  /* Passing a zero sized array, defaults to identiy matrix. The size of the array must exactly match the direction matrix for the dimension of the image. */
182  std::vector<double> m_OutputDirection{std::vector<double>()};
183 
184  double m_EdgePaddingValue{0.0};
185 
186 
187  };
188 
199  SITKBasicFilters_EXPORT Image Warp ( const Image & image, const Image & displacementField, InterpolatorEnum interpolator = itk::simple::sitkLinear, std::vector<uint32_t> outputSize = std::vector<uint32_t>(3, 0), std::vector<double> outputOrigin = std::vector<double>(3, 0.0), std::vector<double> outputSpacing = std::vector<double>(3, 1.0), std::vector<double> outputDirection = std::vector<double>(), double edgePaddingValue = 0.0 );
200 
202 }
203 #endif
itk::simple::Image
The Image class for SimpleITK.
Definition: sitkImage.h:76
sitkBasicFilters.h
itk::simple::sitkLinear
@ sitkLinear
N-D linear interpolation.
Definition: sitkInterpolator.h:38
itk::simple::WarpImageFilter::SetOutputDirection
Self & SetOutputDirection(std::vector< double > OutputDirection)
Definition: sitkWarpImageFilter.h:123
itk::simple::InterpolatorEnum
InterpolatorEnum
Definition: sitkInterpolator.h:28
itk::simple::WarpImageFilter::SetOutputSpacing
Self & SetOutputSpacing(std::vector< double > OutputSpacing)
Definition: sitkWarpImageFilter.h:113
itk::simple::WarpImageFilter::GetEdgePaddingValue
double GetEdgePaddingValue() const
Definition: sitkWarpImageFilter.h:138
itk::simple::WarpImageFilter
Warps an image using an input displacement field.
Definition: sitkWarpImageFilter.h:64
itk::simple::WarpImageFilter::GetName
std::string GetName() const
Definition: sitkWarpImageFilter.h:141
itk::simple::BasicPixelIDTypeList
typelist2::typelist< BasicPixelID< int8_t >, BasicPixelID< uint8_t >, BasicPixelID< int16_t >, BasicPixelID< uint16_t >, BasicPixelID< int32_t >, BasicPixelID< uint32_t >, BasicPixelID< float >, BasicPixelID< double > > BasicPixelIDTypeList
Definition: sitkPixelIDTypeLists.h:51
itk::simple::WarpImageFilter::PixelIDTypeList
BasicPixelIDTypeList PixelIDTypeList
Definition: sitkWarpImageFilter.h:76
itk::simple::WarpImageFilter::SetOutputSize
Self & SetOutputSize(std::vector< uint32_t > OutputSize)
Definition: sitkWarpImageFilter.h:93
itk::simple::WarpImageFilter::SetInterpolator
Self & SetInterpolator(InterpolatorEnum Interpolator)
Definition: sitkWarpImageFilter.h:83
itk::simple::WarpImageFilter::GetOutputDirection
std::vector< double > GetOutputDirection() const
Definition: sitkWarpImageFilter.h:128
sitkImageFilter.h
itk::simple::WarpImageFilter::SetEdgePaddingValue
Self & SetEdgePaddingValue(double EdgePaddingValue)
Definition: sitkWarpImageFilter.h:133
itk::simple::Warp
Image Warp(const Image &image, const Image &displacementField, InterpolatorEnum interpolator=itk::simple::sitkLinear, std::vector< uint32_t > outputSize=std::vector< uint32_t >(3, 0), std::vector< double > outputOrigin=std::vector< double >(3, 0.0), std::vector< double > outputSpacing=std::vector< double >(3, 1.0), std::vector< double > outputDirection=std::vector< double >(), double edgePaddingValue=0.0)
Warps an image using an input displacement field.
itk::simple::WarpImageFilter::GetOutputSize
std::vector< uint32_t > GetOutputSize() const
Definition: sitkWarpImageFilter.h:98
itk::simple::detail::DualExecuteInternalVectorAddressor
Definition: sitkDetail.h:83
itk::simple::WarpImageFilter::GetOutputSpacing
std::vector< double > GetOutputSpacing() const
Definition: sitkWarpImageFilter.h:118
sitkDualMemberFunctionFactory.h
itk::simple::WarpImageFilter::MemberFunctionType
Image(Self::*)(const Image *image, const Image *displacementField) MemberFunctionType
Definition: sitkWarpImageFilter.h:158
SITKBasicFilters_EXPORT
#define SITKBasicFilters_EXPORT
Definition: sitkBasicFilters.h:52
itk::simple::detail::DualExecuteInternalAddressor
Definition: sitkDetail.h:42
itk::simple::WarpImageFilter::SetOutputOrigin
Self & SetOutputOrigin(std::vector< double > OutputOrigin)
Definition: sitkWarpImageFilter.h:103
itk::simple::ImageFilter
The base interface for SimpleITK filters that take one input image.
Definition: sitkImageFilter.h:35
itk::simple::WarpImageFilter::GetInterpolator
InterpolatorEnum GetInterpolator() const
Definition: sitkWarpImageFilter.h:88
itk::Image
Definition: sitkPixelIDTypes.h:28
itk::simple::WarpImageFilter::m_DualMemberFactory
std::unique_ptr< detail::DualMemberFunctionFactory< MemberFunctionType > > m_DualMemberFactory
Definition: sitkWarpImageFilter.h:165
itk::simple
Definition: sitkAdditionalProcedures.h:28
itk::simple::WarpImageFilter::GetOutputOrigin
std::vector< double > GetOutputOrigin() const
Definition: sitkWarpImageFilter.h:108