ITK  4.6.0
Insight Segmentation and Registration Toolkit
itkIterativeInverseDisplacementFieldImageFilter.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright Insight Software Consortium
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 __itkIterativeInverseDisplacementFieldImageFilter_h
19 #define __itkIterativeInverseDisplacementFieldImageFilter_h
20 
21 
23 #include "itkImageRegionIterator.h"
24 #include "itkTimeProbe.h"
25 
26 namespace itk
27 {
51 template< typename TInputImage, typename TOutputImage >
53  public ImageToImageFilter< TInputImage, TOutputImage >
54 {
55 public:
61 
63  itkNewMacro(Self);
64 
67 
69  typedef TInputImage InputImageType;
70  typedef typename InputImageType::ConstPointer InputImageConstPointer;
71  typedef typename InputImageType::Pointer InputImagePointer;
72  typedef typename InputImageType::PointType InputImagePointType;
73  typedef typename InputImageType::RegionType InputImageRegionType;
74  typedef typename InputImageType::SpacingType InputImageSpacingType;
75  typedef TOutputImage OutputImageType;
76  typedef typename OutputImageType::Pointer OutputImagePointer;
77  typedef typename OutputImageType::PixelType OutputImagePixelType;
78  typedef typename OutputImageType::PointType OutputImagePointType;
79  typedef typename OutputImageType::IndexType OutputImageIndexType;
80  typedef typename OutputImagePixelType::ValueType OutputImageValueType;
81 
83 
87 
89 
93 
94  itkSetMacro(NumberOfIterations, unsigned int);
95  itkGetConstMacro(NumberOfIterations, unsigned int);
96 
97  // If the error (in mm) between forward and backward mapping is smaller than
98  // the StopValue,
99  // the algorithm stops.
100  // This value can be used to speed up the calculation.
101  itkSetMacro(StopValue, double);
102  itkGetConstMacro(StopValue, double);
103 
104 #ifdef ITK_USE_CONCEPT_CHECKING
105  // Begin concept checking
106  itkConceptMacro( OutputHasNumericTraitsCheck,
108 
109  itkConceptMacro( SameDimensionCheck,
111  // End concept checking
112 #endif
113 
114 protected:
117 
118  void PrintSelf(std::ostream & os, Indent indent) const;
119 
120  void GenerateData();
121 
122  unsigned int m_NumberOfIterations;
123 
124  double m_StopValue;
125  double m_Time;
126 
127 private:
128  IterativeInverseDisplacementFieldImageFilter(const Self &); //purposely not implemented
129  void operator=(const Self &); //purposely not implemented
130 };
131 } // end namespace itk
132 
133 #ifndef ITK_MANUAL_INSTANTIATION
134 #include "itkIterativeInverseDisplacementFieldImageFilter.hxx"
135 #endif
136 
137 #endif
Computes the time passed between two points in code.
Definition: itkTimeProbe.h:44
Base class for all process objects that output image data.
Warps an image using an input displacement field.
A multi-dimensional iterator templated over image type that walks a region of pixels.
WarpVectorImageFilter< TOutputImage, TInputImage, TOutputImage > VectorWarperType
Base class for filters that take an image as input and produce an image as output.
Control indentation during Print() invocation.
Definition: itkIndent.h:49
void PrintSelf(std::ostream &os, Indent indent) const
#define itkConceptMacro(name, concept)
VectorLinearInterpolateImageFunction< TInputImage, double > FieldInterpolatorType
A multi-dimensional iterator templated over image type that walks a region of pixels.
Linearly interpolate a vector image at specified positions.