go home Home | Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Data Structures | File List | Namespace Members | Data Fields | Globals | Related Pages
elxImageSamplerBase.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 __elxImageSamplerBase_h
00016 #define __elxImageSamplerBase_h
00017 
00019 #include "elxMacro.h"
00020 
00021 #include "elxBaseComponentSE.h"
00022 
00023 #include "itkImageSamplerBase.h"
00024 
00025 
00026 namespace elastix
00027 {
00028 //using namespace itk; not here because itk::ImageSamplerBase exists also.
00029 
00040   template <class TElastix>
00041     class ImageSamplerBase : public BaseComponentSE<TElastix>
00042   {
00043   public:
00044 
00046     typedef ImageSamplerBase            Self;
00047     typedef BaseComponentSE<TElastix>   Superclass;
00048 
00050     itkTypeMacro( ImageSamplerBase, BaseComponentSE );
00051 
00053     typedef typename Superclass::ElastixType            ElastixType;
00054     typedef typename Superclass::ElastixPointer         ElastixPointer;
00055     typedef typename Superclass::ConfigurationType      ConfigurationType;
00056     typedef typename Superclass::ConfigurationPointer   ConfigurationPointer;
00057     typedef typename Superclass::RegistrationType       RegistrationType;
00058     typedef typename Superclass::RegistrationPointer    RegistrationPointer;
00059 
00061     typedef typename ElastixType::FixedImageType        InputImageType;
00062 
00064     typedef itk::ImageSamplerBase< InputImageType >     ITKBaseType;
00065 
00067     virtual ITKBaseType * GetAsITKBaseType(void)
00068     {
00069       return dynamic_cast<ITKBaseType *>(this);
00070     }
00071 
00073     virtual const ITKBaseType * GetAsITKBaseType(void) const
00074     {
00075       return dynamic_cast<const ITKBaseType *>(this);
00076     }
00077 
00082     virtual void BeforeEachResolutionBase(void);
00083 
00084   protected:
00085 
00087     ImageSamplerBase() {}
00089     virtual ~ImageSamplerBase() {}
00090 
00091   private:
00092 
00094     ImageSamplerBase( const Self& );  // purposely not implemented
00096     void operator=( const Self& );    // purposely not implemented
00097 
00098   }; // end class ImageSamplerBase
00099 
00100 
00101 } // end namespace elastix
00102 
00103 
00104 
00105 #ifndef ITK_MANUAL_INSTANTIATION
00106 #include "elxImageSamplerBase.hxx"
00107 #endif
00108 
00109 #endif // end #ifndef __elxImageSamplerBase_h
00110 


Generated on 24-05-2012 for elastix by doxygen 1.7.6.1 elastix logo