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

itkMovingHistogramImageFilter.h

Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Insight Segmentation & Registration Toolkit
00004   Module:    $RCSfile: itkMovingHistogramImageFilter.h,v $
00005   Language:  C++
00006   Date:      $Date: 2009-06-03 12:48:05 $
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 __itkMovingHistogramImageFilter_h
00018 #define __itkMovingHistogramImageFilter_h
00019 
00020 #include "itkMovingHistogramImageFilterBase.h"
00021 
00022 //#define zigzag
00023 
00024 namespace itk {
00025 
00089 template<class TInputImage, class TOutputImage, class TKernel, class THistogram >
00090 class ITK_EXPORT MovingHistogramImageFilter : 
00091     public MovingHistogramImageFilterBase<TInputImage, TOutputImage, TKernel>
00092 {
00093 public:
00095   typedef MovingHistogramImageFilter Self;
00096   typedef MovingHistogramImageFilterBase<TInputImage, TOutputImage, TKernel>  Superclass;
00097   typedef SmartPointer<Self>        Pointer;
00098   typedef SmartPointer<const Self>  ConstPointer;
00099 
00101   itkNewMacro(Self);  
00102 
00104   itkTypeMacro(MovingHistogramImageFilter, 
00105                MovingHistogramImageFilter);
00106 
00108   typedef TInputImage                                 InputImageType;
00109   typedef TOutputImage                                OutputImageType;
00110   typedef typename TInputImage::RegionType            RegionType;
00111   typedef typename TInputImage::SizeType              SizeType;
00112   typedef typename TInputImage::IndexType             IndexType;
00113   typedef typename TInputImage::PixelType             PixelType;
00114   typedef typename TInputImage::OffsetType            OffsetType;
00115   typedef typename Superclass::OutputImageRegionType  OutputImageRegionType;
00116   typedef typename TOutputImage::PixelType            OutputPixelType;
00117 
00119   itkStaticConstMacro(ImageDimension, unsigned int,
00120                       TInputImage::ImageDimension);
00121 
00123   typedef TKernel                                     KernelType;
00124 
00126   typedef typename KernelType::ConstIterator          KernelIteratorType;
00127 
00129   typedef typename KernelType::SizeType               RadiusType;
00130 
00131   typedef typename std::list< OffsetType >            OffsetListType;
00132 
00133   typedef typename std::map< OffsetType, OffsetListType, typename OffsetType::LexicographicCompare >          OffsetMapType;
00134 
00135 protected:
00136   MovingHistogramImageFilter();
00137   ~MovingHistogramImageFilter() {};
00138   
00140   void  ThreadedGenerateData (const OutputImageRegionType& 
00141                               outputRegionForThread,
00142                               int threadId);
00143 
00149   virtual THistogram * NewHistogram();
00150 
00151 #ifndef zigzag
00152   // declare the type used to store the histogram
00153   typedef THistogram HistogramType;
00154 
00155   void PushHistogram(HistogramType * histogram, 
00156          const OffsetListType* addedList,
00157          const OffsetListType* removedList,
00158          const RegionType &inputRegion,
00159          const RegionType &kernRegion,
00160          const InputImageType* inputImage,
00161          const IndexType currentIdx);
00162 
00163   void PrintHistogram(const HistogramType &H);
00164 
00165 #endif
00166 
00167 private:
00168   MovingHistogramImageFilter(const Self&); //purposely not implemented
00169   void operator=(const Self&); //purposely not implemented
00170 
00171 }; // end of class
00172 
00173 } // end namespace itk
00174   
00175 #ifndef ITK_MANUAL_INSTANTIATION
00176 #include "itkMovingHistogramImageFilter.txx"
00177 #endif
00178 
00179 #endif
00180 

Generated at Mon Jul 12 2010 19:10:56 for ITK by doxygen 1.7.1 written by Dimitri van Heesch, © 1997-2000