00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018 #ifndef __itkBinaryMorphologicalOpeningImageFilter_h
00019 #define __itkBinaryMorphologicalOpeningImageFilter_h
00020
00021 #include "itkImageToImageFilter.h"
00022
00023 namespace itk {
00024
00046 template<class TInputImage, class TOutputImage, class TKernel>
00047 class ITK_EXPORT BinaryMorphologicalOpeningImageFilter :
00048 public ImageToImageFilter<TInputImage, TOutputImage>
00049 {
00050 public:
00052 typedef BinaryMorphologicalOpeningImageFilter Self;
00053 typedef ImageToImageFilter<TInputImage, TOutputImage> Superclass;
00054 typedef SmartPointer<Self> Pointer;
00055 typedef SmartPointer<const Self> ConstPointer;
00056
00058 itkNewMacro(Self);
00059
00061 itkTypeMacro(BinaryMorphologicalOpeningImageFilter,
00062 ImageToImageFilter);
00063
00064 typedef TInputImage InputImageType;
00065 typedef TOutputImage OutputImageType;
00066 typedef typename InputImageType::Pointer InputImagePointer;
00067 typedef typename OutputImageType::RegionType OutputImageRegionType;
00068
00070 typedef typename TInputImage::PixelType PixelType;
00071
00073 typedef TKernel KernelType;
00074
00076 itkSetMacro(Kernel, KernelType);
00077
00079 itkGetConstReferenceMacro(Kernel, KernelType);
00080
00083 itkSetMacro(ForegroundValue, PixelType);
00084
00087 itkGetMacro(ForegroundValue, PixelType);
00088
00090 itkSetMacro(BackgroundValue, PixelType);
00091
00093 itkGetMacro(BackgroundValue, PixelType);
00094
00095 protected:
00096 BinaryMorphologicalOpeningImageFilter();
00097 ~BinaryMorphologicalOpeningImageFilter() {};
00098 void PrintSelf(std::ostream& os, Indent indent) const;
00099
00105 void GenerateInputRequestedRegion();
00106
00109 void GenerateData ();
00110
00111 private:
00112 BinaryMorphologicalOpeningImageFilter(const Self&);
00113 void operator=(const Self&);
00114
00116 KernelType m_Kernel;
00117
00118 PixelType m_ForegroundValue;
00119
00120 PixelType m_BackgroundValue;
00121
00122 };
00123
00124 }
00125
00126 #ifndef ITK_MANUAL_INSTANTIATION
00127 #include "itkBinaryMorphologicalOpeningImageFilter.txx"
00128 #endif
00129
00130 #endif
00131