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;
135 void operator=(
const Self&) =
delete;
146 #ifndef OTB_MANUAL_INSTANTIATION