itkMovingHistogramImageFilter.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef __itkMovingHistogramImageFilter_h
00018 #define __itkMovingHistogramImageFilter_h
00019
00020 #include "itkMovingHistogramImageFilterBase.h"
00021
00022
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
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&);
00169 void operator=(const Self&);
00170
00171 };
00172
00173 }
00174
00175 #ifndef ITK_MANUAL_INSTANTIATION
00176 #include "itkMovingHistogramImageFilter.txx"
00177 #endif
00178
00179 #endif
00180