go home Home | Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Data Structures | File List | Namespace Members | Data Fields | Globals | Related Pages
elxRegistrationBase.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright UMC Utrecht and contributors
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 #ifndef __elxRegistrationBase_h
19 #define __elxRegistrationBase_h
20 
22 #include "elxMacro.h"
23 
24 #include "elxBaseComponentSE.h"
26 
30 
31 namespace elastix
32 {
33 
74 template< class TElastix >
75 class RegistrationBase : public BaseComponentSE< TElastix >
76 {
77 public:
78 
82 
85 
87  typedef typename Superclass::ElastixType ElastixType;
93 
95  typedef typename ElastixType::FixedImageType FixedImageType;
96  typedef typename ElastixType::MovingImageType MovingImageType;
97 
99  itkStaticConstMacro( FixedImageDimension, unsigned int, FixedImageType::ImageDimension );
101  itkStaticConstMacro( MovingImageDimension, unsigned int, MovingImageType::ImageDimension );
102 
105  FixedImageType, MovingImageType > ITKBaseType;
106 
108  typedef std::vector< bool > UseMaskErosionArrayType;
109 
111  virtual ITKBaseType * GetAsITKBaseType( void )
112  {
113  return dynamic_cast< ITKBaseType * >( this );
114  }
115 
116 
118  virtual const ITKBaseType * GetAsITKBaseType( void ) const
119  {
120  return dynamic_cast< const ITKBaseType * >( this );
121  }
122 
123 
144  virtual bool ReadMaskParameters(
145  UseMaskErosionArrayType & useMaskErosionArray,
146  const unsigned int nrOfMasks,
147  const std::string & whichMask,
148  const unsigned int level ) const;
149 
150 protected:
151 
155  virtual ~RegistrationBase() {}
156 
158  typedef typename ElastixType::MaskPixelType MaskPixelType;
159  typedef typename ElastixType::FixedMaskType FixedMaskImageType;
160  typedef typename ElastixType::MovingMaskType MovingMaskImageType;
161  typedef typename FixedMaskImageType::Pointer FixedMaskImagePointer;
162  typedef typename MovingMaskImageType::Pointer MovingMaskImagePointer;
164  itkGetStaticConstMacro( FixedImageDimension ) > FixedMaskSpatialObjectType;
166  itkGetStaticConstMacro( MovingImageDimension ) > MovingMaskSpatialObjectType;
167  typedef typename
169  typedef typename
171 
174 
180 
193  FixedMaskSpatialObjectPointer GenerateFixedMaskSpatialObject(
194  const FixedMaskImageType * maskImage, bool useMaskErosion,
195  const FixedImagePyramidType * pyramid, unsigned int level ) const;
196 
209  MovingMaskSpatialObjectPointer GenerateMovingMaskSpatialObject(
210  const MovingMaskImageType * maskImage, bool useMaskErosion,
211  const MovingImagePyramidType * pyramid, unsigned int level ) const;
212 
213 private:
214 
216  RegistrationBase( const Self & ); // purposely not implemented
218  void operator=( const Self & ); // purposely not implemented
219 
220 };
221 
222 } // end namespace elastix
223 
224 #ifndef ITK_MANUAL_INSTANTIATION
225 #include "elxRegistrationBase.hxx"
226 #endif
227 
228 #endif // end #ifndef __elxRegistrationBase_h
ElastixType::FixedMaskType FixedMaskImageType
The BaseComponentSE class is a base class for elastix components that provides some basic functionali...
Superclass::RegistrationType RegistrationType
Base class for multi-resolution image registration methods.
ElastixType::MaskPixelType MaskPixelType
ElastixType::RegistrationBaseType RegistrationType
ElastixType::ConfigurationPointer ConfigurationPointer
ElastixType::Pointer ElastixPointer
ElastixType::ConfigurationType ConfigurationType
ITKBaseType::MovingImagePyramidType MovingImagePyramidType
Implementation of an image mask as spatial object.
FixedMaskImageType::Pointer FixedMaskImagePointer
MovingMaskImageType::Pointer MovingMaskImagePointer
Superclass::ConfigurationType ConfigurationType
This class is the elastix base class for all Registration schemes.
virtual ITKBaseType * GetAsITKBaseType(void)
void operator=(const Self &)
Superclass::ConfigurationPointer ConfigurationPointer
RegistrationType * RegistrationPointer
MovingMaskErodeFilterType::Pointer MovingMaskErodeFilterPointer
FixedMaskErodeFilterType::Pointer FixedMaskErodeFilterPointer
ElastixType::FixedImageType FixedImageType
ITKBaseType::FixedImagePyramidType FixedImagePyramidType
itk::ErodeMaskImageFilter< FixedMaskImageType > FixedMaskErodeFilterType
itkStaticConstMacro(FixedImageDimension, unsigned int, FixedImageType::ImageDimension)
itk::ErodeMaskImageFilter< MovingMaskImageType > MovingMaskErodeFilterType
itk::MultiResolutionImageRegistrationMethod2< FixedImageType, MovingImageType > ITKBaseType
ElastixType::MovingImageType MovingImageType
itk::ImageMaskSpatialObject2< itkGetStaticConstMacro(MovingImageDimension) > MovingMaskSpatialObjectType
MovingMaskSpatialObjectPointer GenerateMovingMaskSpatialObject(const MovingMaskImageType *maskImage, bool useMaskErosion, const MovingImagePyramidType *pyramid, unsigned int level) const
BaseComponentSE< TElastix > Superclass
MultiResolutionPyramidImageFilter< FixedImageType, FixedImageType > FixedImagePyramidType
Superclass::RegistrationPointer RegistrationPointer
FixedMaskSpatialObjectType::Pointer FixedMaskSpatialObjectPointer
MovingMaskSpatialObjectType::Pointer MovingMaskSpatialObjectPointer
itk::ImageMaskSpatialObject2< itkGetStaticConstMacro(FixedImageDimension) > FixedMaskSpatialObjectType
MultiResolutionPyramidImageFilter< MovingImageType, MovingImageType > MovingImagePyramidType
Superclass::ElastixType ElastixType
virtual const ITKBaseType * GetAsITKBaseType(void) const
ElastixType::MovingMaskType MovingMaskImageType
std::vector< bool > UseMaskErosionArrayType
Superclass::ElastixPointer ElastixPointer
FixedMaskSpatialObjectPointer GenerateFixedMaskSpatialObject(const FixedMaskImageType *maskImage, bool useMaskErosion, const FixedImagePyramidType *pyramid, unsigned int level) const
virtual bool ReadMaskParameters(UseMaskErosionArrayType &useMaskErosionArray, const unsigned int nrOfMasks, const std::string &whichMask, const unsigned int level) const


Generated on 04-09-2015 for elastix by doxygen 1.8.9.1 elastix logo