ITK 6.0.0
Insight Toolkit
 
Loading...
Searching...
No Matches
itkMinimumMaximumImageFilter.h
Go to the documentation of this file.
1/*=========================================================================
2 *
3 * Copyright NumFOCUS
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 * https://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 itkMinimumMaximumImageFilter_h
19#define itkMinimumMaximumImageFilter_h
20
21#include "itkImageSink.h"
23#include <mutex>
24
25#include <vector>
26
27#include "itkNumericTraits.h"
28
29namespace itk
30{
47template <typename TInputImage>
48class ITK_TEMPLATE_EXPORT MinimumMaximumImageFilter : public ImageSink<TInputImage>
49{
50public:
51 ITK_DISALLOW_COPY_AND_MOVE(MinimumMaximumImageFilter);
52
54 static constexpr unsigned int InputImageDimension = TInputImage::ImageDimension;
55
61
63 using InputImagePointer = typename TInputImage::Pointer;
64
65 using RegionType = typename TInputImage::RegionType;
66 using SizeType = typename TInputImage::SizeType;
67 using IndexType = typename TInputImage::IndexType;
68 using PixelType = typename TInputImage::PixelType;
69
72
74 itkNewMacro(Self);
75
77 itkOverrideGetNameOfClassMacro(MinimumMaximumImageFilter);
78
80 using InputImageType = TInputImage;
81
84
86 itkGetDecoratedOutputMacro(Minimum, PixelType);
87
89 itkGetDecoratedOutputMacro(Maximum, PixelType);
90
96 MakeOutput(const DataObjectIdentifierType & name) override;
97
98
99 // Change the access from protected to public to expose streaming option, a using statement can not be used due to
100 // limitations of wrapping.
101 void
102 SetNumberOfStreamDivisions(const unsigned int n) override
103 {
105 }
106 unsigned int
108 {
110 }
111
113 itkConceptMacro(GreaterThanComparableCheck, (Concept::GreaterThanComparable<PixelType>));
115
116protected:
118 ~MinimumMaximumImageFilter() override = default;
119 void
120 PrintSelf(std::ostream & os, Indent indent) const override;
121
123 void
125
128 void
130
131 void
133
134
135 itkSetDecoratedOutputMacro(Minimum, PixelType);
136 itkSetDecoratedOutputMacro(Maximum, PixelType);
137
138private:
141
142 std::mutex m_Mutex{};
143};
144} // end namespace itk
145
146#ifndef ITK_MANUAL_INSTANTIATION
147# include "itkMinimumMaximumImageFilter.hxx"
148#endif
149
150#endif
SmartPointer< Self > Pointer
virtual void SetNumberOfStreamDivisions(unsigned int _arg)
virtual unsigned int GetNumberOfStreamDivisions() const
Control indentation during Print() invocation.
Definition itkIndent.h:50
typename TInputImage::IndexType IndexType
ProcessObject::DataObjectIdentifierType DataObjectIdentifierType
DataObjectPointer MakeOutput(const DataObjectIdentifierType &name) override
Make a DataObject of the correct type to used as the specified output.
typename TInputImage::PixelType PixelType
~MinimumMaximumImageFilter() override=default
unsigned int GetNumberOfStreamDivisions() const override
typename TInputImage::SizeType SizeType
static constexpr unsigned int InputImageDimension
typename TInputImage::Pointer InputImagePointer
void ThreadedStreamedGenerateData(const RegionType &) override
void SetNumberOfStreamDivisions(const unsigned int n) override
void PrintSelf(std::ostream &os, Indent indent) const override
typename TInputImage::RegionType RegionType
void AfterStreamedGenerateData() override
SimpleDataObjectDecorator< PixelType > PixelObjectType
typename DataObject::Pointer DataObjectPointer
void BeforeStreamedGenerateData() override
DataObject::DataObjectIdentifierType DataObjectIdentifierType
virtual DataObjectPointer MakeOutput(DataObjectPointerArraySizeType idx)
Make a DataObject of the correct type to used as the specified output.
Decorates any "simple" data type (data types without smart pointers) with a DataObject API.
Implements transparent reference counting.
#define itkConceptMacro(name, concept)
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....