THuiLinearMappingFunction Class Reference

class THuiLinearMappingFunction : public MHuiMappingFunction

Linear mapping function.

Does not implement change flags, which means that if iFactor or iOffset is changed while the mapping function is in use, timed values will not notify the change.

Inherits from

Constructor & Destructor Documentation

THuiLinearMappingFunction(TReal32, TReal32)

IMPORT_CTHuiLinearMappingFunction(TReal32aFactor = 1.0,
TReal32aOffset = 0.0
)

Constructor.

Parameters

TReal32 aFactor = 1.0
TReal32 aOffset = 0.0

Member Functions Documentation

MapValue(TReal32, TInt)

IMPORT_C TReal32MapValue(TReal32aValue,
TIntaMode
)const [virtual]

Perform the mapping. Defines a function y = f(x, mode).

Implement this method that calculates a output value for a timed value based on the input value and a component/mode parameter.

For example the aValue input could be an angle, and the aMode could be a X or Y component enumeration, then the MapValue could calculate return a x or y position on a curve path.

Parameters

TReal32 aValueUnmapped value.
TInt aModeMapping mode used for mapping this value.

Member Data Documentation

TReal32 iFactor

TReal32 iFactor

Multiply by a factor.

TReal32 iOffset

TReal32 iOffset

Apply offset after multiplication.