|
ITK
6.0.0
Insight Toolkit
|
Go to the documentation of this file.
18 #ifndef itkImageRegistrationMethodImageSource_h
19 #define itkImageRegistrationMethodImageSource_h
40 template <
typename TFixedPixelType,
typename TMovingPixelType,
unsigned int VDimension>
97 center[0] = static_cast<double>(region.
GetSize()[0]) / 2.0;
98 center[1] = static_cast<double>(region.
GetSize()[1]) / 2.0;
100 const double s = static_cast<double>(region.
GetSize()[0]) / 2.0;
113 while (!ri.IsAtEnd())
115 p[0] = ri.GetIndex()[0];
116 p[1] = ri.GetIndex()[1];
119 const double x = d[0];
120 const double y = d[1];
121 const double value = 200.0 * std::exp(-(x * x + y * y) / (s * s));
122 ri.Set(static_cast<typename MovingImageType::PixelType>(value));
127 while (!ti.IsAtEnd())
129 p[0] = ti.GetIndex()[0];
130 p[1] = ti.GetIndex()[1];
132 const double x = d[0];
133 const double y = d[1];
134 const double value = 200.0 * std::exp(-(x * x + y * y) / (s * s));
135 ti.Set(static_cast<typename FixedImageType::PixelType>(value));
OptimizerParameters< double > ParametersType
ImageRegistrationMethodImageSource()
An image region represents a structured region of data.
itk::Image< TFixedPixelType, VDimension > FixedImageType
A templated class holding a n-Dimensional vector.
const SizeType & GetSize() const
MovingImageType::Pointer m_MovingImage
Light weight base class for most itk classes.
void GenerateImages(const typename MovingImageType::SizeType &size)
ObjectType * GetPointer() const noexcept
A multi-dimensional iterator templated over image type that walks pixels within a region and is speci...
const ParametersType & GetActualParameters() const
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....
Base class for most ITK classes.
const FixedImageType * GetFixedImage() const
Templated n-dimensional image class.
ParametersType m_Parameters
const MovingImageType * GetMovingImage() const
FixedImageType::Pointer m_FixedImage