21 #ifndef otbLocalHistogramImageFunction_h
22 #define otbLocalHistogramImageFunction_h
24 #include "itkImageFunction.h"
25 #include "itkHistogram.h"
26 #include "itkNumericTraits.h"
54 template <
class TInputImage,
class TCoordRep =
double>
56 :
public itk::ImageFunction<TInputImage, typename itk::Statistics::Histogram<typename TInputImage::PixelType>::Pointer, TCoordRep>
61 typedef itk::ImageFunction<TInputImage, typename itk::Statistics::Histogram<typename TInputImage::PixelType>::Pointer, TCoordRep>
Superclass;
78 typedef itk::Statistics::Histogram<typename TInputImage::PixelType>
HistogramType;
84 itkStaticConstMacro(ImageDimension,
unsigned int, InputImageType::ImageDimension);
93 this->ConvertPointToNearestIndex(point, index);
94 return this->EvaluateAtIndex(index);
99 this->ConvertContinuousIndexToNearestIndex(cindex, index);
100 return this->EvaluateAtIndex(index);
107 itkSetMacro(NeighborhoodRadius,
unsigned int);
108 itkGetConstReferenceMacro(NeighborhoodRadius,
unsigned int);
112 itkSetClampMacro(NumberOfHistogramBins,
unsigned long, 1, itk::NumericTraits<unsigned long>::max());
113 itkGetConstMacro(NumberOfHistogramBins,
unsigned long);
116 itkSetMacro(HistogramMin,
double);
117 itkGetConstReferenceMacro(HistogramMin,
double);
119 itkSetMacro(HistogramMax,
double);
120 itkGetConstReferenceMacro(HistogramMax,
double);
122 itkSetMacro(GaussianSmoothing,
bool);
123 itkGetConstReferenceMacro(GaussianSmoothing,
bool);
124 itkBooleanMacro(GaussianSmoothing);
131 void PrintSelf(std::ostream& os, itk::Indent indent)
const override;
146 #ifndef OTB_MANUAL_INSTANTIATION
Calculate a local histogram over a specified circular neighborhood.
LocalHistogramImageFunction(const Self &)=delete
TInputImage InputImageType
itk::ImageFunction< TInputImage, typename itk::Statistics::Histogram< typename TInputImage::PixelType >::Pointer, TCoordRep > Superclass
void operator=(const Self &)=delete
unsigned int m_NeighborhoodRadius
~LocalHistogramImageFunction() override
OutputType Evaluate(const PointType &point) const override
OutputType EvaluateAtContinuousIndex(const ContinuousIndexType &cindex) const override
Superclass::PointType PointType
Superclass::IndexType IndexType
itk::SmartPointer< Self > Pointer
itk::SmartPointer< const Self > ConstPointer
HistogramType::Pointer HistogramPointer
Superclass::ContinuousIndexType ContinuousIndexType
unsigned long m_NumberOfHistogramBins
itk::Statistics::Histogram< typename TInputImage::PixelType > HistogramType
LocalHistogramImageFunction Self
Superclass::OutputType OutputType
The "otb" namespace contains all Orfeo Toolbox (OTB) classes.