ITK  4.4.0
Insight Segmentation and Registration Toolkit
itkBinaryReconstructionByDilationImageFilter.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 __itkBinaryReconstructionByDilationImageFilter_h
19 #define __itkBinaryReconstructionByDilationImageFilter_h
20 
21 #include "itkImageToImageFilter.h"
23 #include "itkLabelMap.h"
28 
29 
30 namespace itk {
31 
54 template<class TInputImage>
56  public ImageToImageFilter<TInputImage, TInputImage>
57 {
58 public:
64 
66  typedef TInputImage InputImageType;
67  typedef TInputImage OutputImageType;
68  typedef typename InputImageType::Pointer InputImagePointer;
69  typedef typename InputImageType::ConstPointer InputImageConstPointer;
70  typedef typename InputImageType::RegionType InputImageRegionType;
71  typedef typename InputImageType::PixelType InputImagePixelType;
72  typedef typename OutputImageType::Pointer OutputImagePointer;
73  typedef typename OutputImageType::ConstPointer OutputImageConstPointer;
74  typedef typename OutputImageType::RegionType OutputImageRegionType;
75  typedef typename OutputImageType::PixelType OutputImagePixelType;
76 
78  itkStaticConstMacro(InputImageDimension, unsigned int,
79  TInputImage::ImageDimension);
80  itkStaticConstMacro(OutputImageDimension, unsigned int,
81  TInputImage::ImageDimension);
82  itkStaticConstMacro(ImageDimension, unsigned int,
83  TInputImage::ImageDimension);
85 
92 
94  itkNewMacro(Self);
95 
99 
106  itkSetMacro(FullyConnected, bool);
107  itkGetConstReferenceMacro(FullyConnected, bool);
108  itkBooleanMacro(FullyConnected);
110 
111 #ifdef ITK_USE_CONCEPT_CHECKING
112 
113  itkConceptMacro(InputEqualityComparableCheck,
115  itkConceptMacro(IntConvertibleToInputCheck,
117  itkConceptMacro(InputOStreamWritableCheck,
119 
121 #endif
122 
127  itkSetMacro(BackgroundValue, OutputImagePixelType);
128  itkGetConstMacro(BackgroundValue, OutputImagePixelType);
130 
135  itkSetMacro(ForegroundValue, OutputImagePixelType);
136  itkGetConstMacro(ForegroundValue, OutputImagePixelType);
138 
140  void SetMarkerImage( const InputImageType *input );
141 
143  InputImageType * GetMarkerImage();
144 
146  void SetMaskImage( const InputImageType *input );
147 
149  InputImageType * GetMaskImage();
150 
151 protected:
154  void PrintSelf(std::ostream& os, Indent indent) const;
155 
159  void GenerateInputRequestedRegion();
160 
162  void EnlargeOutputRequestedRegion(DataObject *itkNotUsed(output));
163 
166  void GenerateData();
167 
168 private:
169  BinaryReconstructionByDilationImageFilter(const Self&); //purposely not implemented
170  void operator=(const Self&); //purposely not implemented
171 
175 }; // end of class
176 
177 } // end namespace itk
178 
179 #ifndef ITK_MANUAL_INSTANTIATION
180 #include "itkBinaryReconstructionByDilationImageFilter.hxx"
181 #endif
182 
183 #endif
184