go home Home | Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Data Structures | File List | Namespace Members | Data Fields | Globals | Related Pages
elxEulerTransform.h
Go to the documentation of this file.
00001 /*======================================================================
00002 
00003   This file is part of the elastix software.
00004 
00005   Copyright (c) University Medical Center Utrecht. All rights reserved.
00006   See src/CopyrightElastix.txt or http://elastix.isi.uu.nl/legal.php for
00007   details.
00008 
00009      This software is distributed WITHOUT ANY WARRANTY; without even
00010      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
00011      PURPOSE. See the above copyright notices for more information.
00012 
00013 ======================================================================*/
00014 
00015 #ifndef __elxEulerTransform_H__
00016 #define __elxEulerTransform_H__
00017 
00018 #include "itkAdvancedCombinationTransform.h"
00019 #include "itkEulerTransform.h"
00020 #include "itkCenteredTransformInitializer.h"
00021 #include "elxIncludes.h"
00022 
00023 namespace elastix
00024 {
00025 using namespace itk;
00026 
00067   template < class TElastix >
00068     class EulerTransformElastix:
00069       public AdvancedCombinationTransform<
00070         ITK_TYPENAME elx::TransformBase< TElastix >::CoordRepType,
00071         elx::TransformBase< TElastix >::FixedImageDimension >,
00072       public elx::TransformBase< TElastix >
00073   {
00074   public:
00075 
00077     typedef EulerTransformElastix                               Self;
00078 
00079     typedef AdvancedCombinationTransform<
00080       typename elx::TransformBase< TElastix >::CoordRepType,
00081       elx::TransformBase< TElastix >::FixedImageDimension >     Superclass1;
00082 
00083     typedef elx::TransformBase< TElastix >                      Superclass2;
00084 
00087     typedef EulerTransform<
00088       typename elx::TransformBase< TElastix >::CoordRepType,
00089       elx::TransformBase< TElastix >::FixedImageDimension >     EulerTransformType;
00090 
00091     typedef SmartPointer<Self>                                  Pointer;
00092     typedef SmartPointer<const Self>                            ConstPointer;
00093 
00095     itkNewMacro( Self );
00096 
00098     //itkTypeMacro( EulerTransformElastix, EulerTransform );
00099     itkTypeMacro( EulerTransformElastix, AdvancedCombinationTransform );
00100 
00105     elxClassNameMacro( "EulerTransform" );
00106 
00108     itkStaticConstMacro( SpaceDimension, unsigned int, Superclass2::FixedImageDimension );
00109 
00113     typedef typename Superclass1::ScalarType                  ScalarType;
00114     typedef typename Superclass1::ParametersType              ParametersType;
00115     typedef typename Superclass1::JacobianType                JacobianType;
00116 
00117     typedef typename Superclass1::InputPointType              InputPointType;
00118     typedef typename Superclass1::OutputPointType             OutputPointType;
00119     typedef typename Superclass1::InputVectorType             InputVectorType;
00120     typedef typename Superclass1::OutputVectorType            OutputVectorType;
00121     typedef typename Superclass1::InputCovariantVectorType    InputCovariantVectorType;
00122     typedef typename Superclass1::OutputCovariantVectorType   OutputCovariantVectorType;
00123     typedef typename Superclass1::InputVnlVectorType          InputVnlVectorType;
00124     typedef typename Superclass1::OutputVnlVectorType         OutputVnlVectorType;
00125 
00126     typedef typename EulerTransformType::Pointer              EulerTransformPointer;
00127     typedef typename EulerTransformType::OffsetType           OffsetType;
00128 
00130     typedef typename Superclass2::ElastixType               ElastixType;
00131     typedef typename Superclass2::ElastixPointer            ElastixPointer;
00132     typedef typename Superclass2::ConfigurationType         ConfigurationType;
00133     typedef typename Superclass2::ConfigurationPointer      ConfigurationPointer;
00134     typedef typename Superclass2::RegistrationType          RegistrationType;
00135     typedef typename Superclass2::RegistrationPointer       RegistrationPointer;
00136     typedef typename Superclass2::CoordRepType              CoordRepType;
00137     typedef typename Superclass2::FixedImageType            FixedImageType;
00138     typedef typename Superclass2::MovingImageType           MovingImageType;
00139     typedef typename Superclass2::ITKBaseType               ITKBaseType;
00140     typedef typename Superclass2::CombinationTransformType  CombinationTransformType;
00141 
00143     typedef typename FixedImageType::IndexType              IndexType;
00144     typedef typename IndexType::IndexValueType              IndexValueType;
00145     typedef typename FixedImageType::SizeType               SizeType;
00146     typedef typename FixedImageType::PointType              PointType;
00147     typedef typename FixedImageType::SpacingType            SpacingType;
00148     typedef typename FixedImageType::RegionType             RegionType;
00149     typedef typename FixedImageType::DirectionType          DirectionType;
00150 
00151     typedef CenteredTransformInitializer<
00152       EulerTransformType, FixedImageType, MovingImageType>  TransformInitializerType;
00153     typedef typename TransformInitializerType::Pointer      TransformInitializerPointer;
00154 
00156     typedef typename Superclass2::ScalesType                ScalesType;
00157 
00162     virtual void BeforeRegistration(void);
00163 
00179     virtual void InitializeTransform(void);
00180 
00188     virtual void SetScales(void);
00189 
00194     virtual void ReadFromFile(void);
00195 
00199     virtual void WriteToFile( const ParametersType & param ) const;
00200 
00201   protected:
00202 
00204     EulerTransformElastix();
00206     virtual ~EulerTransformElastix() {};
00207 
00213     virtual bool ReadCenterOfRotationIndex( InputPointType & rotationPoint ) const;
00214 
00220     virtual bool ReadCenterOfRotationPoint( InputPointType & rotationPoint ) const;
00221 
00222   private:
00223 
00225     EulerTransformElastix( const Self& ); // purposely not implemented
00227     void operator=( const Self& );        // purposely not implemented
00228 
00229     EulerTransformPointer       m_EulerTransform;
00230 
00231   }; // end class EulerTransformElastix
00232 
00233 
00234 } // end namespace elastix
00235 
00236 #ifndef ITK_MANUAL_INSTANTIATION
00237 #include "elxEulerTransform.hxx"
00238 #endif
00239 
00240 #endif // end #ifndef __elxEulerTransform_H__
00241 


Generated on 11-05-2011 for elastix by doxygen 1.7.4 elastix logo