Orfeo Toolbox  3.16
itkComplexToRealImageAdaptor.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Insight Segmentation & Registration Toolkit
4  Module: $RCSfile: itkComplexToRealImageAdaptor.h,v $
5  Language: C++
6  Date: $Date: 2009-09-19 19:56:20 $
7  Version: $Revision: 1.4 $
8 
9  Copyright (c) Insight Software Consortium. All rights reserved.
10  See ITKCopyright.txt or http://www.itk.org/HTML/Copyright.htm for details.
11 
12  This software is distributed WITHOUT ANY WARRANTY; without even
13  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
14  PURPOSE. See the above copyright notices for more information.
15 
16 =========================================================================*/
17 #ifndef __itkComplexToRealImageAdaptor_h
18 #define __itkComplexToRealImageAdaptor_h
19 
20 #include <itkImageAdaptor.h>
21 #include <complex>
22 
23 namespace itk
24 {
25 
26 namespace Accessor {
38 template <class TInternalType, class TExternalType >
40 {
41 public:
44  typedef TExternalType ExternalType;
45 
48  typedef TInternalType InternalType;
49 
50  static inline void Set(TInternalType & output, const TExternalType & input)
51  {output = (TInternalType)(input);}
52 
53  static inline TExternalType Get( const TInternalType & input )
54  {return (TExternalType)(input.real());}
55 };
56 
57 } // end namespace Accessor
58 
68 template <class TImage, class TOutputPixelType>
70  ImageAdaptor<TImage,
71  Accessor::ComplexToRealPixelAccessor<
72  typename TImage::PixelType,
73  TOutputPixelType> >
74 {
75 public:
79  typename TImage::PixelType,
80  TOutputPixelType> > Superclass;
83 
85  itkNewMacro(Self);
86 
88  itkTypeMacro( ComplexToRealImageAdaptor, ImageAdaptor );
89 
90 protected:
93 
94 private:
95  ComplexToRealImageAdaptor(const Self&); //purposely not implemented
96  void operator=(const Self&); //purposely not implemented
97 
98 };
99 
100 } // end namespace itk
101 
102 #endif

Generated at Sat Feb 2 2013 23:32:37 for Orfeo Toolbox with doxygen 1.8.1.1