NifTK  16.4.1 - 0798f20
CMIC's Translational Medical Imaging Platform
itkMIDASConditionalDilationFilter.h
Go to the documentation of this file.
1 /*=============================================================================
2 
3  NifTK: A software platform for medical image computing.
4 
5  Copyright (c) University College London (UCL). All rights reserved.
6 
7  This software is distributed WITHOUT ANY WARRANTY; without even
8  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
9  PURPOSE.
10 
11  See LICENSE.txt in the top level directory for details.
12 
13 =============================================================================*/
14 
15 #ifndef itkMIDASConditionalDilationFilter_h
16 #define itkMIDASConditionalDilationFilter_h
17 
20 
21 namespace itk
22 {
23 
38  template <class TInputImage1, class TInputImage2, class TOutputImage>
39  class ITK_EXPORT MIDASConditionalDilationFilter : public MIDASBaseConditionalMorphologyFilter<TInputImage1, TInputImage2, TOutputImage>
40  {
41  public:
45  typedef SmartPointer<Self> Pointer;
46  typedef SmartPointer<const Self> ConstPointer;
47 
49  itkNewMacro(Self);
50 
53 
55  typedef typename TInputImage1::PixelType PixelType1;
56 
59 
61  typedef TInputImage1 InputMaskImageType;
62  typedef typename InputMaskImageType::Pointer InputMaskImagePointer;
67 
68  typedef TInputImage2 InputMainImageType;
69  typedef typename InputMainImageType::Pointer InputMainImagePointer;
72 
73  typedef TOutputImage OutputImageType;
74  typedef typename OutputImageType::Pointer OutputImagePointer;
78  typedef typename itk::ConstNeighborhoodIterator<OutputImageType>::RadiusType OutputImageRadiusType;
79 
82 
84  itkSetMacro(LowerThreshold, unsigned int);
85  itkGetConstMacro(LowerThreshold, unsigned int);
86 
88  itkSetMacro(UpperThreshold, unsigned int);
89  itkGetConstMacro(UpperThreshold, unsigned int);
90 
92  void SetConnectionBreakerImage(const InputMaskImageType* image);
93 
94  protected:
97  void PrintSelf(std::ostream& os, Indent indent) const;
98 
100  void DoFilter(InputMainImageType* inGrey, OutputImageType* inMask, OutputImageType *out);
101 
102  private:
103  MIDASConditionalDilationFilter(const Self&); //purposely not implemented
104  void operator=(const Self&); //purposely not implemented
105 
107  MeanFilterPointer m_MeanFilter;
108 
110  unsigned int m_LowerThreshold;
111  unsigned int m_UpperThreshold;
112  };
113 
114 }
115 
116 #ifndef ITK_MANUAL_INSTANTIATION
117 #include "itkMIDASConditionalDilationFilter.txx"
118 #endif
119 
120 #endif
TInputImage2::PixelType PixelType2
Definition: itkMIDASConditionalDilationFilter.h:58
SmartPointer< Self > Pointer
Definition: itkMIDASMeanIntensityWithinARegionFilter.h:43
OutputImageType::IndexType OutputImageIndexType
Definition: itkMIDASConditionalDilationFilter.h:77
InputMaskImageType::Pointer InputMaskImagePointer
Definition: itkMIDASConditionalDilationFilter.h:62
ImageType::SizeType SizeType
Definition: niftkMakeLapUSProbeBasicModel.cxx:31
InputMaskImageType::SizeType InputMaskImageSizeType
Definition: itkMIDASConditionalDilationFilter.h:63
TOutputImage OutputImageType
Definition: itkMIDASConditionalDilationFilter.h:73
GLenum GLsizei GLenum GLenum const GLvoid * image
Definition: glew.h:4052
TInputImage1 InputMaskImageType
Definition: itkMIDASConditionalDilationFilter.h:61
MIDASBaseConditionalMorphologyFilter< TInputImage1, TInputImage2, TOutputImage > SuperClass
Definition: itkMIDASConditionalDilationFilter.h:44
itk::ConstNeighborhoodIterator< OutputImageType >::RadiusType OutputImageRadiusType
Definition: itkMIDASConditionalDilationFilter.h:78
Definition: niftkITKAffineResampleImage.cxx:74
ImageType::IndexType IndexType
Definition: niftkMakeLapUSProbeBasicModel.cxx:32
InputMaskImageType::RegionType InputMaskImageRegionType
Definition: itkMIDASConditionalDilationFilter.h:64
OutputImageType::Pointer OutputImagePointer
Definition: itkMIDASConditionalDilationFilter.h:74
Base class for MIDASConditionalErosionFilter and MIDASConditionalDilationFilter.
Definition: itkMIDASBaseConditionalMorphologyFilter.h:32
InputMainImageType::Pointer InputMainImagePointer
Definition: itkMIDASConditionalDilationFilter.h:69
SmartPointer< Self > Pointer
Definition: itkMIDASConditionalDilationFilter.h:45
float PixelType
Definition: niftkBreastDCEandADC.cxx:88
InputMainImageType::SizeType InputMainImageSizeType
Definition: itkMIDASConditionalDilationFilter.h:70
ImageType::RegionType RegionType
Definition: niftkMakeLapUSProbeBasicModel.cxx:30
TInputImage1::PixelType PixelType1
Definition: itkMIDASConditionalDilationFilter.h:52
MeanFilterType::Pointer MeanFilterPointer
Definition: itkMIDASConditionalDilationFilter.h:81
TInputImage2 InputMainImageType
Definition: itkMIDASConditionalDilationFilter.h:68
InputMaskImageType::PixelType InputMaskImagePixelType
Definition: itkMIDASConditionalDilationFilter.h:65
virtual ~MIDASConditionalDilationFilter()
Definition: itkMIDASConditionalDilationFilter.h:96
InputMainImageType::RegionType InputMainImageRegionType
Definition: itkMIDASConditionalDilationFilter.h:71
itk::MIDASMeanIntensityWithinARegionFilter< TInputImage2, TInputImage1, TOutputImage > MeanFilterType
Definition: itkMIDASConditionalDilationFilter.h:80
SmartPointer< const Self > ConstPointer
Definition: itkMIDASConditionalDilationFilter.h:46
MIDASConditionalDilationFilter Self
Definition: itkMIDASConditionalDilationFilter.h:43
calculate the mean intensity within a binary mask (region).
Definition: itkMIDASMeanIntensityWithinARegionFilter.h:37
Performs the conditional dilation, described in step 4 of "Interactive Algorithms for the segmentatio...
Definition: itkMIDASConditionalDilationFilter.h:39
OutputImageType::RegionType OutputImageRegionType
Definition: itkMIDASConditionalDilationFilter.h:75
InputMaskImageType::IndexType InputMaskImageIndexType
Definition: itkMIDASConditionalDilationFilter.h:66
OutputImageType::SizeType OutputImageSizeType
Definition: itkMIDASConditionalDilationFilter.h:76