NifTK  16.4.1 - 0798f20
CMIC's Translational Medical Imaging Platform
itkInvNormalizedCorrelationImageToImageMetric.h
Go to the documentation of this file.
1 /*=============================================================================
2 
3  NifTK: A software platform for medical image computing.
4 
5  Copyright (c) University College London (UCL). All rights reserved.
6 
7  This software is distributed WITHOUT ANY WARRANTY; without even
8  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
9  PURPOSE.
10 
11  See LICENSE.txt in the top level directory for details.
12 
13 =============================================================================*/
14 
15 #ifndef itkInvNormalizedCorrelationImageToImageMetric_h
16 #define itkInvNormalizedCorrelationImageToImageMetric_h
17 
18 #include <itkImageToImageMetric.h>
19 #include <itkCovariantVector.h>
20 #include <itkPoint.h>
21 
22 
23 namespace itk
24 {
39 template < class TFixedImage, class TMovingImage >
41  public ImageToImageMetric< TFixedImage, TMovingImage>
42 {
43 public:
44 
47  typedef ImageToImageMetric<TFixedImage, TMovingImage > Superclass;
48  typedef SmartPointer<Self> Pointer;
49  typedef SmartPointer<const Self> ConstPointer;
50 
52  itkNewMacro(Self);
53 
56 
57 
59  typedef typename Superclass::RealType RealType;
61  typedef typename Superclass::TransformPointer TransformPointer;
62  typedef typename Superclass::TransformParametersType TransformParametersType;
63  typedef typename Superclass::TransformJacobianType TransformJacobianType;
64  typedef typename Superclass::GradientPixelType GradientPixelType;
67 
68  typedef typename Superclass::MeasureType MeasureType;
69  typedef typename Superclass::DerivativeType DerivativeType;
70  typedef typename Superclass::FixedImageType FixedImageType;
71  typedef typename Superclass::MovingImageType MovingImageType;
72  typedef typename Superclass::FixedImageConstPointer FixedImageConstPointer;
73  typedef typename Superclass::MovingImageConstPointer MovingImageConstPointer;
74 
75 
77  void GetDerivative( const TransformParametersType & parameters,
78  DerivativeType & Derivative ) const;
79 
81  MeasureType GetValue( const TransformParametersType & parameters ) const;
82 
84  void GetValueAndDerivative( const TransformParametersType & parameters,
85  MeasureType& Value, DerivativeType& Derivative ) const;
86 
91  itkSetMacro( SubtractMean, bool );
92  itkGetConstReferenceMacro( SubtractMean, bool );
93  itkBooleanMacro( SubtractMean );
94 
95 protected:
98  void PrintSelf(std::ostream& os, Indent indent) const;
99 
100 private:
101  InvNormalizedCorrelationImageToImageMetric(const Self&); //purposely not implemented
102  void operator=(const Self&); //purposely not implemented
103 
104  bool m_SubtractMean;
105 
106 };
107 
108 } // end namespace itk
109 
110 #ifndef ITK_MANUAL_INSTANTIATION
111 #include "itkInvNormalizedCorrelationImageToImageMetric.txx"
112 #endif
113 
114 #endif
Superclass::MovingImageConstPointer MovingImageConstPointer
Definition: itkInvNormalizedCorrelationImageToImageMetric.h:73
SmartPointer< Self > Pointer
Definition: itkInvNormalizedCorrelationImageToImageMetric.h:48
Superclass::DerivativeType DerivativeType
Definition: itkInvNormalizedCorrelationImageToImageMetric.h:69
Superclass::FixedImageConstPointer FixedImageConstPointer
Definition: itkInvNormalizedCorrelationImageToImageMetric.h:72
Superclass::GradientPixelType GradientPixelType
Definition: itkInvNormalizedCorrelationImageToImageMetric.h:64
Definition: niftkITKAffineResampleImage.cxx:74
itk::Point< double, 2 > InputPointType
Definition: EulerAffine2DJacobianTest.cxx:34
itk::EulerAffineTransform< double, 2, 2 > TransformType
Definition: EulerAffine2DJacobianTest.cxx:27
Superclass::TransformJacobianType TransformJacobianType
Definition: itkInvNormalizedCorrelationImageToImageMetric.h:63
Superclass::MeasureType MeasureType
Definition: itkInvNormalizedCorrelationImageToImageMetric.h:68
ImageToImageMetric< TFixedImage, TMovingImage > Superclass
Definition: itkInvNormalizedCorrelationImageToImageMetric.h:47
Superclass::MovingImageType MovingImageType
Definition: itkInvNormalizedCorrelationImageToImageMetric.h:71
Superclass::RealType RealType
Definition: itkInvNormalizedCorrelationImageToImageMetric.h:55
Superclass::InputPointType InputPointType
Definition: itkInvNormalizedCorrelationImageToImageMetric.h:66
Superclass::OutputPointType OutputPointType
Definition: itkInvNormalizedCorrelationImageToImageMetric.h:65
Superclass::TransformPointer TransformPointer
Definition: itkInvNormalizedCorrelationImageToImageMetric.h:61
Superclass::TransformType TransformType
Definition: itkInvNormalizedCorrelationImageToImageMetric.h:60
virtual ~InvNormalizedCorrelationImageToImageMetric()
Definition: itkInvNormalizedCorrelationImageToImageMetric.h:97
Definition: itkInvNormalizedCorrelationImageToImageMetric.h:40
Superclass::FixedImageType FixedImageType
Definition: itkInvNormalizedCorrelationImageToImageMetric.h:70
InvNormalizedCorrelationImageToImageMetric Self
Definition: itkInvNormalizedCorrelationImageToImageMetric.h:46
itk::Point< double, 2 > OutputPointType
Definition: EulerAffine2DJacobianTest.cxx:35
Superclass::TransformParametersType TransformParametersType
Definition: itkInvNormalizedCorrelationImageToImageMetric.h:62
SmartPointer< const Self > ConstPointer
Definition: itkInvNormalizedCorrelationImageToImageMetric.h:49