00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef __itkAsinImageAdaptor_h
00018 #define __itkAsinImageAdaptor_h
00019
00020 #include <itkImageAdaptor.h>
00021 #include "vnl/vnl_math.h"
00022
00023 namespace itk
00024 {
00025
00026 namespace Accessor {
00037 template <class TInternalType, class TExternalType >
00038 class ITK_EXPORT AsinPixelAccessor
00039 {
00040 public:
00041
00044 typedef TExternalType ExternalType;
00045
00048 typedef TInternalType InternalType;
00049
00050 static inline void Set(TInternalType & output, const TExternalType & input)
00051 {output = (TInternalType)vcl_asin((double)input);}
00052
00053 static inline TExternalType Get( const TInternalType & input )
00054 {return (TExternalType)vcl_asin((double)input);}
00055 };
00056
00057
00058 }
00059
00068 template <class TImage, class TOutputPixelType>
00069 class ITK_EXPORT AsinImageAdaptor : public
00070 ImageAdaptor<TImage,
00071 Accessor::AsinPixelAccessor<
00072 typename TImage::PixelType,
00073 TOutputPixelType> >
00074 {
00075 public:
00076
00078 typedef AsinImageAdaptor Self;
00079 typedef ImageAdaptor<TImage,Accessor::AsinPixelAccessor<
00080 typename TImage::PixelType,
00081 TOutputPixelType> > Superclass;
00082 typedef SmartPointer<Self> Pointer;
00083 typedef SmartPointer<const Self> ConstPointer;
00084
00086 itkTypeMacro( AsinImageAdaptor, ImageAdaptor );
00087
00089 itkNewMacro(Self);
00090
00091 protected:
00092 AsinImageAdaptor() {}
00093 virtual ~AsinImageAdaptor() {}
00094
00095 private:
00096 AsinImageAdaptor(const Self&);
00097 void operator=(const Self&);
00098 };
00099
00100 }
00101
00102 #endif
00103