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

itkTensorFractionalAnisotropyImageFilter.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Insight Segmentation & Registration Toolkit
00004   Module:    $RCSfile: itkTensorFractionalAnisotropyImageFilter.h,v $
00005   Language:  C++
00006   Date:      $Date: 2005/05/07 17:39:13 $
00007   Version:   $Revision: 1.3 $
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 __itkTensorFractionalAnisotropyImageFilter_h
00018 #define __itkTensorFractionalAnisotropyImageFilter_h
00019 
00020 #include "itkUnaryFunctorImageFilter.h"
00021 
00022 namespace itk
00023 {
00024 
00025 // This functor class invokes the computation of fractional anisotropy from
00026 // every pixel.
00027 namespace Functor {  
00028  
00029 template< typename TInput >
00030 class TensorFractionalAnisotropyFunction
00031 {
00032 public:
00033   typedef typename TInput::RealValueType  RealValueType;
00034   TensorFractionalAnisotropyFunction() {}
00035   ~TensorFractionalAnisotropyFunction() {}
00036   inline RealValueType operator()( const TInput & x )
00037     {
00038     return x.GetFractionalAnisotropy();
00039     }
00040 }; 
00041 
00042 }  // end namespace functor
00043 
00044 
00059 template <typename  TInputImage, typename  TOutputImage=TInputImage>
00060 class ITK_EXPORT TensorFractionalAnisotropyImageFilter :
00061     public
00062 UnaryFunctorImageFilter<TInputImage,TOutputImage, 
00063                         Functor::TensorFractionalAnisotropyFunction< 
00064                                         typename TInputImage::PixelType> > 
00065 {
00066 public:
00068   typedef TensorFractionalAnisotropyImageFilter  Self;
00069   typedef UnaryFunctorImageFilter<TInputImage,TOutputImage, 
00070                                   Functor::TensorFractionalAnisotropyFunction< 
00071                                     typename TInputImage::PixelType> >  Superclass;
00072 
00073   typedef SmartPointer<Self>   Pointer;
00074   typedef SmartPointer<const Self>  ConstPointer;
00075 
00076   typedef typename Superclass::OutputImageType    OutputImageType;
00077   typedef typename TOutputImage::PixelType        OutputPixelType;
00078   typedef typename TInputImage::PixelType         InputPixelType;
00079   typedef typename InputPixelType::ValueType      InputValueType;
00080 
00081 
00083   itkNewMacro(Self);
00084   
00086   void PrintSelf(std::ostream& os, Indent indent) const
00087     { this->Superclass::PrintSelf( os, indent ); }
00088   
00089 
00090 protected:
00091   TensorFractionalAnisotropyImageFilter() {};
00092   virtual ~TensorFractionalAnisotropyImageFilter() {};
00093 
00094 private:
00095   TensorFractionalAnisotropyImageFilter(const Self&); //purposely not implemented
00096   void operator=(const Self&); //purposely not implemented
00097 
00098 };
00099 
00100 
00101   
00102 } // end namespace itk
00103   
00104 #endif

Generated at Thu May 25 00:07:58 2006 for ITK by doxygen 1.3.5 written by Dimitri van Heesch, © 1997-2000