ITK  5.0.0
Insight Segmentation and Registration Toolkit
itkVariationalRegistrationFastNCCFunction.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 itkVariationalRegistrationFastNCCFunction_h
19 #define itkVariationalRegistrationFastNCCFunction_h
20 
22 #include "itkCovariantVector.h"
26 
27 namespace itk {
28 
63 template< typename TFixedImage, typename TMovingImage, typename TDisplacementField >
65  public VariationalRegistrationNCCFunction< TFixedImage, TMovingImage, TDisplacementField >
66 {
67 public:
68  ITK_DISALLOW_COPY_AND_ASSIGN(VariationalRegistrationFastNCCFunction);
69 
73 
76 
78  itkNewMacro(Self);
79 
82 
84  static constexpr unsigned int ImageDimension = Superclass::ImageDimension;
85 
89 
93 
97 
100  using SpacingType = typename FixedImageType::SpacingType;
101 
106 
112 
115  using GradientCalculatorPointer = typename GradientCalculatorType::Pointer;
116 
119  PixelType ComputeUpdate( const NeighborhoodType &neighborhood,
120  void *globalData,
121  const FloatOffsetType &offset = FloatOffsetType(0.0) ) override;
122 
125  void *GetGlobalDataPointer() const override;
126 
128  void ReleaseGlobalDataPointer(void *GlobalData) const override;
129 
130 protected:
133 
135  void PrintSelf(std::ostream& os, Indent indent) const override;
136 
138 
142  {
148  unsigned int lastSliceIndex;
149  std::vector<double> sfSliceValueList;
150  std::vector<double> smSliceValueList;
151  std::vector<double> sffSliceValueList;
152  std::vector<double> smmSliceValueList;
153  std::vector<double> sfmSliceValueList;
154  double sfLastValue;
155  double smLastValue;
156  double sffLastValue;
157  double smmLastValue;
158  double sfmLastValue;
159  };
160 };
161 
162 
163 } // end namespace itk
164 
165 #ifndef ITK_MANUAL_INSTANTIATION
166 #include "itkVariationalRegistrationFastNCCFunction.hxx"
167 #endif
168 
169 #endif
This class computes NCC forces in the variational registration framework.
Light weight base class for most itk classes.
This class computes NCC forces in the variational registration framework.
typename Superclass::MaskImagePointer MaskImagePointer
unsigned long SizeValueType
Definition: itkIntTypes.h:83
typename Superclass::FixedImagePointer FixedImagePointer
void PrintSelf(std::ostream &os, Indent indent) const override
void ReleaseGlobalDataPointer(void *GlobalData) const override
typename Superclass::DisplacementFieldType DisplacementFieldType
typename Superclass::GradientCalculatorType GradientCalculatorType
void * GetGlobalDataPointer() const override
CentralDifferenceImageFunction< FixedImageType > GradientCalculatorType
Superclass::DisplacementFieldTypePointer DisplacementFieldTypePointer
Control indentation during Print() invocation.
Definition: itkIndent.h:49
typename Superclass::MovingImagePointer MovingImagePointer
typename GradientCalculatorType::Pointer GradientCalculatorPointer
typename Superclass::DisplacementFieldType DisplacementFieldType
typename Superclass::DisplacementFieldTypePointer DisplacementFieldTypePointer
PixelType ComputeUpdate(const NeighborhoodType &neighborhood, void *globalData, const FloatOffsetType &offset=FloatOffsetType(0.0)) override