22 #ifndef otbVectorRescaleIntensityImageFilter_h
23 #define otbVectorRescaleIntensityImageFilter_h
25 #include "itkUnaryFunctorImageFilter.h"
26 #include "itkVariableLengthVector.h"
43 template <
typename TInput,
typename TOutput>
48 typedef typename itk::NumericTraits<typename TInput::ValueType>::RealType
RealType;
148 return !(*
this != other);
156 result.SetSize(x.GetSize());
162 itkGenericExceptionMacro(<<
"Pixel size different from scale or shift size !");
166 for (
unsigned int i = 0; i < x.GetSize(); ++i)
183 scaledComponent = std::pow(scaledComponent, 1. /
m_Gamma);
185 result[i] =
static_cast<typename TOutput::ValueType
>(scaledComponent +
m_OutputMinimum[i]);
219 template <
class TInputImage,
class TOutputImage = TInputImage>
221 :
public itk::UnaryFunctorImageFilter<TInputImage, TOutputImage,
222 Functor::VectorAffineTransform<typename TInputImage::PixelType, typename TOutputImage::PixelType>>
227 typedef itk::UnaryFunctorImageFilter<TInputImage, TOutputImage,
239 typedef typename itk::NumericTraits<InputValueType>::RealType
InputRealType;
249 itkSetMacro(AutomaticInputMinMaxComputation,
bool);
250 itkGetMacro(AutomaticInputMinMaxComputation,
bool);
251 itkBooleanMacro(AutomaticInputMinMaxComputation);
253 itkGetMacro(ClampThreshold,
double);
254 itkSetMacro(ClampThreshold,
double);
262 itkSetMacro(Gamma,
double);
263 itkGetConstReferenceMacro(Gamma,
double);
275 void PrintSelf(std::ostream& os, itk::Indent indent)
const override;
298 #ifndef OTB_MANUAL_INSTANTIATION
This filter performs a rescaling of a vector image on a per band basis.
InputPixelType::ValueType InputValueType
void BeforeThreadedGenerateData(void) override
TOutputImage::PixelType OutputPixelType
VectorRescaleIntensityImageFilter(const Self &)=delete
itk::SmartPointer< Self > Pointer
void PrintSelf(std::ostream &os, itk::Indent indent) const override
itk::UnaryFunctorImageFilter< TInputImage, TOutputImage, Functor::VectorAffineTransform< typename TInputImage::PixelType, typename TOutputImage::PixelType > > Superclass
void GenerateOutputInformation(void) override
VectorRescaleIntensityImageFilter Self
TInputImage InputImageType
InputPixelType m_InputMaximum
InputPixelType m_InputMinimum
bool m_AutomaticInputMinMaxComputation
VectorRescaleIntensityImageFilter()
void GenerateInputRequestedRegion(void) override
OutputPixelType m_OutputMaximum
OutputPixelType m_OutputMinimum
itk::NumericTraits< OutputValueType >::RealType OutputRealType
InputImageType::PixelType InputPixelType
itk::NumericTraits< InputValueType >::RealType InputRealType
void operator=(const Self &)=delete
InputImageType::ConstPointer InputImagePointer
OutputPixelType::ValueType OutputValueType
itk::SmartPointer< const Self > ConstPointer
~VectorRescaleIntensityImageFilter() override
The "otb" namespace contains all Orfeo Toolbox (OTB) classes.