ITK  4.12.0
Insight Segmentation and Registration Toolkit
itkAttributeOpeningLabelMapFilter.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 itkAttributeOpeningLabelMapFilter_h
19 #define itkAttributeOpeningLabelMapFilter_h
20 
23 
24 namespace itk {
42 template<typename TImage, typename TAttributeAccessor=
43  typename Functor::AttributeLabelObjectAccessor< typename TImage::LabelObjectType > >
44 class ITK_TEMPLATE_EXPORT AttributeOpeningLabelMapFilter :
45  public InPlaceLabelMapFilter<TImage>
46 {
47 public:
53 
55  typedef TImage ImageType;
56  typedef typename ImageType::Pointer ImagePointer;
58  typedef typename ImageType::PixelType PixelType;
59  typedef typename ImageType::IndexType IndexType;
60 
61  typedef typename Superclass::LabelObjectType LabelObjectType;
62 
63  typedef TAttributeAccessor AttributeAccessorType;
64  typedef typename AttributeAccessorType::AttributeValueType AttributeValueType;
65 
67  itkStaticConstMacro(ImageDimension, unsigned int,
68  TImage::ImageDimension);
69 
71  itkNewMacro(Self);
72 
74  itkTypeMacro(AttributeOpeningLabelMapFilter,
76 
77 #ifdef ITK_USE_CONCEPT_CHECKING
78  // Begin concept checking
79 /* itkConceptMacro(InputEqualityComparableCheck,
80  (Concept::EqualityComparable<InputImagePixelType>));
81  itkConceptMacro(IntConvertibleToInputCheck,
82  (Concept::Convertible<int, InputImagePixelType>));
83  itkConceptMacro(InputOStreamWritableCheck,
84  (Concept::OStreamWritable<InputImagePixelType>));*/
85  // End concept checking
86 #endif
87 
91  itkGetConstMacro(Lambda, AttributeValueType);
92  itkSetMacro(Lambda, AttributeValueType);
94 
101  itkGetConstMacro( ReverseOrdering, bool );
102  itkSetMacro( ReverseOrdering, bool );
103  itkBooleanMacro( ReverseOrdering );
105 
106 protected:
109 
110  void GenerateData() ITK_OVERRIDE;
111 
112  void PrintSelf(std::ostream& os, Indent indent) const ITK_OVERRIDE;
113 
114 private:
115  ITK_DISALLOW_COPY_AND_ASSIGN(AttributeOpeningLabelMapFilter);
116 
117  AttributeValueType m_Lambda;
118  bool m_ReverseOrdering;
119 
120 }; // end of class
121 
122 } // end namespace itk
123 
124 #ifndef ITK_MANUAL_INSTANTIATION
125 #include "itkAttributeOpeningLabelMapFilter.hxx"
126 #endif
127 
128 #endif
AttributeAccessorType::AttributeValueType AttributeValueType
virtual void PrintSelf(std::ostream &os, Indent indent) const override
Light weight base class for most itk classes.
SmartPointer< Self > Pointer
Base class for filters that takes an image as input and overwrites that image as the output...
SmartPointer< const Self > ConstPointer
remove the objects according to the value of their attribute
Control indentation during Print() invocation.
Definition: itkIndent.h:49