00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
#ifndef __itkCenteredTransformInitializer_h
00019
#define __itkCenteredTransformInitializer_h
00020
00021
#include <itkObject.h>
00022
00023
#include <iostream>
00024
00025
namespace itk
00026 {
00027
00057
template <
class TTransform,
00058
class TFixedImage,
00059
class TMovingImage >
00060 class ITK_EXPORT CenteredTransformInitializer :
00061
public Object
00062 {
00063
public:
00065 typedef CenteredTransformInitializer
Self;
00066 typedef Object Superclass;
00067 typedef SmartPointer<Self> Pointer;
00068 typedef SmartPointer<const Self> ConstPointer;
00069
00071
itkNewMacro(
Self );
00072
00074
itkTypeMacro( CenteredTransformInitializer,
Object );
00075
00077 typedef TTransform
TransformType;
00078 typedef typename TransformType::Pointer
TransformPointer;
00079
00081
itkStaticConstMacro(SpaceDimension,
unsigned int, TransformType::SpaceDimension);
00082
itkStaticConstMacro(InputSpaceDimension,
unsigned int, TransformType::InputSpaceDimension);
00083
itkStaticConstMacro(OutputSpaceDimension,
unsigned int, TransformType::OutputSpaceDimension);
00084
00085
00087
typedef TFixedImage
FixedImageType;
00088 typedef TMovingImage
MovingImageType;
00089
00090
typedef typename FixedImageType::ConstPointer
FixedImagePointer;
00091 typedef typename MovingImageType::ConstPointer
MovingImagePointer;
00092
00093
00094
00096
typedef typename TransformType::OffsetType
OffsetType;
00097
00099
typedef typename TransformType::InputPointType
InputPointType;
00100
00102
typedef typename TransformType::OutputVectorType
OutputVectorType;
00103
00105
itkSetObjectMacro(
Transform,
TransformType );
00106
00108
itkSetConstObjectMacro( FixedImage,
FixedImageType );
00109
00111
itkSetConstObjectMacro( MovingImage,
MovingImageType );
00112
00113
00115
void InitializeTransform() const;
00116
00119
void GeometryOn() { m_UseMoments =
false; }
00120 void MomentsOn() { m_UseMoments =
true; }
00121
00122
00123
protected:
00124 CenteredTransformInitializer() {};
00125 ~CenteredTransformInitializer(){};
00126
00127 void PrintSelf(std::ostream &os,
Indent indent)
const;
00128
00129
private:
00130 CenteredTransformInitializer(
const Self&);
00131
void operator=(
const Self&);
00132
00133
TransformPointer m_Transform;
00134
00135
FixedImagePointer m_FixedImage;
00136
00137
MovingImagePointer m_MovingImage;
00138
00139
bool m_UseMoments;
00140
00141 };
00142
00143
00144 }
00145
00146
00147
#ifndef ITK_MANUAL_INSTANTIATION
00148
#include "itkCenteredTransformInitializer.txx"
00149
#endif
00150
00151
#endif