ITK  4.2.0
Insight Segmentation and Registration Toolkit
itkMovingHistogramMorphologyImageFilter.h
Go to the documentation of this file.
1 /*=========================================================================
2  *
3  * Copyright Insight Software Consortium
4  *
5  * Licensed under the Apache License, Version 2.0 (the "License");
6  * you may not use this file except in compliance with the License.
7  * You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0.txt
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  *
17  *=========================================================================*/
18 #ifndef __itkMovingHistogramMorphologyImageFilter_h
19 #define __itkMovingHistogramMorphologyImageFilter_h
20 
21 #include "itkMorphologyHistogram.h"
23 #include <list>
24 #include <map>
25 
26 namespace itk
27 {
28 
41 template< class TInputImage, class TOutputImage, class TKernel, class THistogram >
43  public MovingHistogramImageFilter< TInputImage, TOutputImage, TKernel, THistogram >
44 {
45 public:
52 
54  itkNewMacro(Self);
55 
59 
61  typedef TInputImage InputImageType;
62  typedef TOutputImage OutputImageType;
63  typedef typename TInputImage::RegionType RegionType;
64  typedef typename TInputImage::SizeType SizeType;
65  typedef typename TInputImage::IndexType IndexType;
66  typedef typename TInputImage::PixelType PixelType;
67  typedef typename TInputImage::OffsetType OffsetType;
68  typedef typename Superclass::OutputImageRegionType OutputImageRegionType;
69  typedef typename TOutputImage::PixelType OutputPixelType;
70 
72  itkStaticConstMacro(ImageDimension, unsigned int,
73  TInputImage::ImageDimension);
74 
76  typedef TKernel KernelType;
77 
79  typedef typename KernelType::ConstIterator KernelIteratorType;
80 
82  typedef typename KernelType::SizeType RadiusType;
83 
84  typedef typename std::list< OffsetType > OffsetListType;
85 
86  typedef typename std::map< OffsetType, OffsetListType, typename OffsetType::LexicographicCompare > OffsetMapType;
87 
89  itkSetMacro(Boundary, PixelType);
90  itkGetConstMacro(Boundary, PixelType);
92 
95  static bool GetUseVectorBasedAlgorithm()
96  { return THistogram::UseVectorBasedAlgorithm(); }
97 protected:
100  void PrintSelf(std::ostream & os, Indent indent) const;
102 
104 // void ThreadedGenerateData (const OutputImageRegionType&
105 // outputRegionForThread,
106 // ThreadIdType threadId);
107 
109  virtual void ConfigureHistogram(THistogram & histogram);
110 
112 private:
113  MovingHistogramMorphologyImageFilter(const Self &); //purposely not
114  // implemented
115  void operator=(const Self &); //purposely not
116  // implemented
117 }; // end of class
118 } // end namespace itk
119 
120 #ifndef ITK_MANUAL_INSTANTIATION
121 #include "itkMovingHistogramMorphologyImageFilter.hxx"
122 #endif
123 
124 #endif
125