ITK  6.0.0
Insight Toolkit
itkScalarImageToHistogramGenerator.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 itkScalarImageToHistogramGenerator_h
19#define itkScalarImageToHistogramGenerator_h
20
23#include "itkHistogram.h"
24#include "itkObject.h"
25
26namespace itk
27{
28namespace Statistics
29{
36template <typename TImageType>
37class ITK_TEMPLATE_EXPORT ScalarImageToHistogramGenerator : public Object
38{
39public:
40 ITK_DISALLOW_COPY_AND_MOVE(ScalarImageToHistogramGenerator);
41
47
49 itkOverrideGetNameOfClassMacro(ScalarImageToHistogramGenerator);
50
52 itkNewMacro(Self);
53
54 using ImageType = TImageType;
57 using PixelType = typename ImageType::PixelType;
59
61 using GeneratorType = itk::Statistics::SampleToHistogramFilter<AdaptorType, HistogramType>;
62
64
67
68public:
70 void
72
75 void
77
81 const HistogramType *
82 GetOutput() const;
83
85 void
86 SetNumberOfBins(unsigned int numberOfBins);
87
89 void
90 SetMarginalScale(double marginalScale);
91
95 void
97
101 void
103
107 void
109
110protected:
113 void
114 PrintSelf(std::ostream & os, Indent indent) const override;
115
116private:
117 AdaptorPointer m_ImageToListSampleAdaptor{};
118
119 GeneratorPointer m_HistogramGenerator{};
120};
121} // end of namespace Statistics
122} // end of namespace itk
123
124#ifndef ITK_MANUAL_INSTANTIATION
125# include "itkScalarImageToHistogramGenerator.hxx"
126#endif
127
128#endif
Control indentation during Print() invocation.
Definition: itkIndent.h:50
Light weight base class for most itk classes.
Define additional traits for native types such as int or float.
Base class for most ITK classes.
Definition: itkObject.h:62
This class stores measurement vectors in the context of n-dimensional histogram.
Definition: itkHistogram.h:78
This class provides ListSample interface to ITK Image.
void SetHistogramMax(RealPixelType maximumValue)
void PrintSelf(std::ostream &os, Indent indent) const override
void SetNumberOfBins(unsigned int numberOfBins)
typename NumericTraits< PixelType >::RealType RealPixelType
void SetHistogramMin(RealPixelType minimumValue)
itk::Statistics::SampleToHistogramFilter< AdaptorType, HistogramType > GeneratorType
SmartPointer< const Self > ConstPointer
SmartPointer< Self > Pointer
The "itk" namespace contains all Insight Segmentation and Registration Toolkit (ITK) classes....