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

itkImageKernelOperator.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Insight Segmentation & Registration Toolkit
00004   Module:    $RCSfile: itkImageKernelOperator.h,v $
00005   Language:  C++
00006   Date:      $Date: 2009-02-17 19:18:23 $
00007   Version:   $Revision: 1.1 $
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 __itkImageKernelOperator_h
00018 #define __itkImageKernelOperator_h
00019 
00020 #include "itkNeighborhoodOperator.h"
00021 
00022 #include "itkImage.h"
00023 
00024 namespace itk {
00025 
00036 template<class TPixel, unsigned int VDimension=2,
00037   class TAllocator = NeighborhoodAllocator<TPixel> >
00038 class ITK_EXPORT ImageKernelOperator
00039   : public NeighborhoodOperator<TPixel, VDimension, TAllocator>
00040 {
00041 public:
00042 
00044   typedef ImageKernelOperator                                   Self;
00045   typedef NeighborhoodOperator<TPixel, VDimension, TAllocator>  Superclass;
00046 
00047   typedef Image<TPixel, VDimension>               ImageType;
00048   typedef typename Superclass::CoefficientVector  CoefficientVector;  
00049 
00051   ImageKernelOperator() {}
00052 
00054   ImageKernelOperator(const Self &orig)
00055     : Neighborhood<TPixel, VDimension, TAllocator>(orig) 
00056     {}
00057 
00059   Self &operator=( const Self &orig )
00060     {
00061     Superclass::operator=(orig);
00062     return *this;
00063     }
00065 
00066   void SetImageKernel( ImageType *kernel )
00067     {
00068     this->m_ImageKernel = kernel;
00069     } 
00070 
00072   virtual void PrintSelf(std::ostream &os, Indent i) const
00073     {
00074     os << i << "ImageKernelOperator { this=" << this
00075        << "} "  << std::endl;
00076     Superclass::PrintSelf( os, i.GetNextIndent() );
00077     }
00079 
00080 protected:
00081  
00083   CoefficientVector GenerateCoefficients();
00084 
00086   void Fill( const CoefficientVector& coeff );
00087 
00088 private:
00089 
00090   typename ImageType::Pointer m_ImageKernel;
00091 
00093   const char *GetNameOfClass()
00094     { return "itkImageKernelOperator"; }
00095 
00096 };
00097 
00098 } // namespace itk
00099 
00100 
00101 #ifndef ITK_MANUAL_INSTANTIATION
00102 #include "itkImageKernelOperator.txx"
00103 #endif
00104 
00105 #endif
00106 

Generated at Sat Feb 28 12:40:20 2009 for ITK by doxygen 1.5.6 written by Dimitri van Heesch, © 1997-2000