Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef __itkSpatialFunction_h
00018 #define __itkSpatialFunction_h
00019
00020 #include "itkFunctionBase.h"
00021 #include "itkPoint.h"
00022
00023 namespace itk
00024 {
00025
00043 template <typename TOutput,
00044 unsigned int VImageDimension=3,
00045 typename TInput=Point<double, VImageDimension> >
00046 class ITK_EXPORT SpatialFunction : public FunctionBase<TInput, TOutput>
00047 {
00048 public:
00050 typedef SpatialFunction Self;
00051 typedef FunctionBase< TInput, TOutput> Superclass;
00052 typedef SmartPointer<Self> Pointer;
00053 typedef SmartPointer<const Self> ConstPointer;
00054
00056 itkTypeMacro(SpatialFunction, FunctionBase);
00057
00059 typedef typename Superclass::InputType InputType;
00060
00062 typedef typename Superclass::OutputType OutputType;
00063
00065 itkStaticConstMacro(ImageDimension, unsigned int, VImageDimension);
00066
00069 virtual OutputType Evaluate( const InputType& input ) const = 0;
00070
00071 protected:
00072 SpatialFunction();
00073 virtual ~SpatialFunction();
00074 void PrintSelf(std::ostream& os, Indent indent) const;
00075
00076 private:
00077 SpatialFunction(const Self&);
00078 void operator=(const Self&);
00079
00080 };
00081
00082 }
00083
00084
00085 #define ITK_TEMPLATE_SpatialFunction(_, EXPORT, x, y) namespace itk { \
00086 _(3(class EXPORT SpatialFunction< ITK_TEMPLATE_3 x >)) \
00087 namespace Templates { typedef SpatialFunction< ITK_TEMPLATE_3 x > \
00088 SpatialFunction##y; } \
00089 }
00090
00091 #if ITK_TEMPLATE_EXPLICIT
00092 # include "Templates/itkSpatialFunction+-.h"
00093 #endif
00094
00095 #if ITK_TEMPLATE_TXX
00096 # include "itkSpatialFunction.txx"
00097 #endif
00098
00099
00100 #endif
00101