13#ifndef ML_LUTFRESCALE_H
14#define ML_LUTFRESCALE_H
Untyped base class for LUTData template classes.
LUT transform to rescale a LUT's index range and to convert an absolute to a relative LUT.
double getNativeMaxIndex(void) const override
Get native maximum index.
int getHeight(void) const override
Get native LUT height (= number of rows, numbering starts at 0)
const LUTFunction * _inLUT
Input LUT.
bool renderLUTNative(LUTDataBase *lutData, LUTIteratorBase *lutIterator) const override
Render the lookup table into lutData using lutIterator to access and increment the LUT pointers.
virtual void setSourceRange(double sourceMin, double sourceMax)
Set source index range.
virtual void setAutoSourceRange(bool autoSourceRange)
Set auto source index range flag.
virtual bool getAutoSourceRange(void) const
Get auto source index range flag.
LUTVisualType getVisualType(void) const override
Get LUT visual type.
int getDepth(void) const override
Get native LUT depth (= number of layers, numbering starts at 0)
LUTFRescale(void)
Constructor.
void setRelative(bool relative) override
Set/reset relative flag, can only be set if input LUT is absolute.
virtual double transformInverse(double index) const
Apply inverse rescaling to index.
virtual double getTargetMin(void) const
Get minimum target index.
virtual double getSourceMax(void) const
Get maximum source index.
double getNativeMinValue(void) const override
Get native minimum LUT value.
double getNativeMinIndex(void) const override
Get native minimum index.
virtual void setInputLUT(const LUTFunction *inLUT)
Set input LUT, set relative flag to true if input LUT is relative.
bool renderLUTRescaled(LUTDataBase *lutData, LUTIteratorBase *lutIterator, double minIndex, double maxIndex) const override
Render rescaled LUT into lutData using lutIterator to access and increment the LUT pointers.
double getNativeMaxValue(void) const override
Get native maximum LUT value.
bool _autoSourceRange
Source index range is determined from input LUT.
bool isValid(void) const override
Return true if the LUT function is valid.
virtual double transformForward(double index) const
Apply rescaling to index.
ML_CLASS_HEADER(LUTFRescale)
virtual void setTargetRange(double targetMin, double targetMax)
Set target index range.
virtual double getSourceMin(void) const
Get minimum source index.
virtual double getTargetMax(void) const
Get maximum target index.
Common base class for lookup tables.
void changed(void)
Assign a new LUT ID.
LUT iterator base class with type independent functionality and declarations.
#define MLLUT_EXPORT
System specific macro definitions.
Target mlrange_cast(Source arg)
Generic version of checked ML casts.
LUTVisualType
LUT visual type constants to identify the visual interpretation of the individual LUT channels.