ITK  4.13.0
Insight Segmentation and Registration Toolkit
itkGrayscaleConnectedClosingImageFilter.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 itkGrayscaleConnectedClosingImageFilter_h
19 #define itkGrayscaleConnectedClosingImageFilter_h
20 
21 #include "itkImageToImageFilter.h"
22 
23 namespace itk
24 {
44 template< typename TInputImage, typename TOutputImage >
45 class ITK_TEMPLATE_EXPORT GrayscaleConnectedClosingImageFilter:
46  public ImageToImageFilter< TInputImage, TOutputImage >
47 {
48 public:
54 
56  typedef TInputImage InputImageType;
57  typedef typename InputImageType::Pointer InputImagePointer;
58  typedef typename InputImageType::ConstPointer InputImageConstPointer;
59  typedef typename InputImageType::RegionType InputImageRegionType;
60  typedef typename InputImageType::PixelType InputImagePixelType;
62  typedef TOutputImage OutputImageType;
63  typedef typename OutputImageType::Pointer OutputImagePointer;
64  typedef typename OutputImageType::ConstPointer OutputImageConstPointer;
65  typedef typename OutputImageType::RegionType OutputImageRegionType;
66  typedef typename OutputImageType::PixelType OutputImagePixelType;
67 
69  itkStaticConstMacro(InputImageDimension, unsigned int,
70  TInputImage::ImageDimension);
71  itkStaticConstMacro(OutputImageDimension, unsigned int,
72  TOutputImage::ImageDimension);
74 
76  itkNewMacro(Self);
77 
81 
83  itkSetMacro(Seed, InputImageIndexType);
84  itkGetConstMacro(Seed, InputImageIndexType);
86 
93  itkSetMacro(FullyConnected, bool);
94  itkGetConstReferenceMacro(FullyConnected, bool);
95  itkBooleanMacro(FullyConnected);
97 
98 #ifdef ITK_USE_CONCEPT_CHECKING
99  // Begin concept checking
100  itkConceptMacro( InputEqualityComparableCheck,
102  itkConceptMacro( InputConvertibleToOutputCheck,
104  itkConceptMacro( InputOStreamWritableCheck,
106  // End concept checking
107 #endif
108 
109 protected:
112  void PrintSelf(std::ostream & os, Indent indent) const ITK_OVERRIDE;
113 
117  void GenerateInputRequestedRegion() ITK_OVERRIDE;
118 
120  void EnlargeOutputRequestedRegion( DataObject *itkNotUsed(output) ) ITK_OVERRIDE;
121 
124  void GenerateData() ITK_OVERRIDE;
125 
126 private:
127  ITK_DISALLOW_COPY_AND_ASSIGN(GrayscaleConnectedClosingImageFilter);
128 
129  unsigned long m_NumberOfIterationsUsed;
131 
132  bool m_FullyConnected;
133 }; // end of class
134 } // end namespace itk
135 
136 #ifndef ITK_MANUAL_INSTANTIATION
137 #include "itkGrayscaleConnectedClosingImageFilter.hxx"
138 #endif
139 
140 #endif
Base class for all process objects that output image data.
Enhance pixels associated with a dark object (identified by a seed pixel) where the dark object is su...
ImageToImageFilter< TInputImage, TOutputImage > Superclass
Base class for filters that take an image as input and produce an image as output.
Control indentation during Print() invocation.
Definition: itkIndent.h:49
#define itkConceptMacro(name, concept)
Base class for all data objects in ITK.