Main Page   Groups   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Concepts

itkLinearInterpolateImageFunction.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Insight Segmentation & Registration Toolkit
00004   Module:    $RCSfile: itkLinearInterpolateImageFunction.h,v $
00005   Language:  C++
00006   Date:      $Date: 2009-07-29 07:38:01 $
00007   Version:   $Revision: 1.37 $
00008 
00009   Copyright (c) Insight Software Consortium. All rights reserved.
00010   See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details.
00011 
00012      This software is distributed WITHOUT ANY WARRANTY; without even 
00013      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 
00014      PURPOSE.  See the above copyright notices for more information.
00015 
00016 =========================================================================*/
00017 #ifndef __itkLinearInterpolateImageFunction_h
00018 #define __itkLinearInterpolateImageFunction_h
00019 
00020 // First make sure that the configuration is available.
00021 // This line can be removed once the optimized versions
00022 // gets integrated into the main directories.
00023 #include "itkConfigure.h"
00024 
00025 #ifdef ITK_USE_OPTIMIZED_REGISTRATION_METHODS
00026 #include "itkOptLinearInterpolateImageFunction.h"
00027 #else
00028 
00029 #include "itkInterpolateImageFunction.h"
00030 
00031 namespace itk
00032 {
00033 
00051 template <class TInputImage, class TCoordRep = double>
00052 class ITK_EXPORT LinearInterpolateImageFunction : 
00053   public InterpolateImageFunction<TInputImage,TCoordRep> 
00054 {
00055 public:
00057   typedef LinearInterpolateImageFunction                  Self;
00058   typedef InterpolateImageFunction<TInputImage,TCoordRep> Superclass;
00059   typedef SmartPointer<Self>                              Pointer;
00060   typedef SmartPointer<const Self>                        ConstPointer;
00061 
00063   itkTypeMacro(LinearInterpolateImageFunction, InterpolateImageFunction);
00064 
00066   itkNewMacro(Self);  
00067 
00069   typedef typename Superclass::OutputType OutputType;
00070 
00072   typedef typename Superclass::InputImageType InputImageType;
00073 
00075   typedef typename Superclass::InputPixelType InputPixelType;
00076 
00078   typedef typename Superclass::RealType RealType;
00079 
00081   itkStaticConstMacro(ImageDimension, unsigned int,Superclass::ImageDimension);
00082 
00084   typedef typename Superclass::IndexType IndexType;
00085 
00087   typedef typename Superclass::ContinuousIndexType ContinuousIndexType;
00088 
00097   virtual OutputType EvaluateAtContinuousIndex( 
00098     const ContinuousIndexType & index ) const;
00099 
00100 protected:
00101   LinearInterpolateImageFunction();
00102   ~LinearInterpolateImageFunction(){};
00103   void PrintSelf(std::ostream& os, Indent indent) const;
00104 
00105 private:
00106   LinearInterpolateImageFunction( const Self& ); //purposely not implemented
00107   void operator=( const Self& ); //purposely not implemented
00108 
00110   static const unsigned long  m_Neighbors;  
00111 
00112 };
00113 
00114 } // end namespace itk
00115 
00116 // Define instantiation macro for this template.
00117 #define ITK_TEMPLATE_LinearInterpolateImageFunction(_, EXPORT, x, y) namespace itk { \
00118   _(2(class EXPORT LinearInterpolateImageFunction< ITK_TEMPLATE_2 x >)) \
00119   namespace Templates { typedef LinearInterpolateImageFunction< ITK_TEMPLATE_2 x > \
00120                                                   LinearInterpolateImageFunction##y; } \
00121   }
00122 
00123 #if ITK_TEMPLATE_EXPLICIT
00124 # include "Templates/itkLinearInterpolateImageFunction+-.h"
00125 #endif
00126 
00127 #if ITK_TEMPLATE_TXX
00128 # include "itkLinearInterpolateImageFunction.txx"
00129 #endif
00130 
00131 #endif
00132 
00133 #endif
00134 

Generated at Tue Sep 15 03:51:42 2009 for ITK by doxygen 1.5.8 written by Dimitri van Heesch, © 1997-2000