InterpolateTypeInterface Class Reference

#include <interpolation.h>

Inheritance diagram for InterpolateTypeInterface:

Public Member Functions

MAXON_METHOD const DataTypeGetInterpolateDataType () const
 
MAXON_METHOD void InterpolateLinear (void *data1, const void *data2, Float blend) const
 
MAXON_METHOD void InterpolateInOutline (void *data, const Block< void * > &outline, const Block< Float > &weights) const
 
MAXON_METHOD void Average (void *data, const Block< const void * > &dataSet) const
 
MAXON_FUNCTION void InterpolateBilinear (const DataTypePtr dataType, void *data1, const void *data2, const void *data3, const void *data4, Float blendS, Float blendT) const
 

Static Public Member Functions

static MAXON_METHOD InterpolateType GetInterpolationClass (const DataType &datatype)
 

Private Member Functions

 MAXON_INTERFACE (InterpolateTypeInterface, MAXON_REFERENCE_CONST, "net.maxon.geometry.interface.interpolate")
 

Member Function Documentation

◆ MAXON_INTERFACE()

MAXON_INTERFACE ( InterpolateTypeInterface  ,
MAXON_REFERENCE_CONST  ,
"net.maxon.geometry.interface.interpolate"   
)
private

◆ GetInterpolateDataType()

MAXON_METHOD const DataType& GetInterpolateDataType ( ) const

Returns the datatype this class manages, e.g. Vector2d32

Returns
The datatype.

◆ InterpolateLinear()

MAXON_METHOD void InterpolateLinear ( void *  data1,
const void *  data2,
Float  blend 
) const

Interpolates linearly between two data values. Both addresses must be cast to the appropriate datatype.

Parameters
[in,out]data1The address of the first value. The value will be overwritten with the result.
[in]data2The address of the second value.
[in]blendThe blend percentage [0.0..blend..1.0]

◆ InterpolateInOutline()

MAXON_METHOD void InterpolateInOutline ( void *  data,
const Block< void * > &  outline,
const Block< Float > &  weights 
) const

Interpolates a value in the polygon outline using given weights. The addresses in data and outline need to be cast to the appropriate datatype.

Parameters
[in,out]dataThe address of the value. The value will be overwritten with the result.
[in]outlineThe outline data used to perform the interpolation.
[in]weightsWeights to use for the interpolation; represent the interpolation distance from each outline edge.

◆ Average()

MAXON_METHOD void Average ( void *  data,
const Block< const void * > &  dataSet 
) const

Averages values in dataSet and stores the result under the specified data pointer.

Parameters
[in,out]dataThe resulting data pointer to be filled. The caller owns the memory.
[in]dataSetThe data set to average.

◆ InterpolateBilinear()

MAXON_FUNCTION void InterpolateBilinear ( const DataTypePtr  dataType,
void *  data1,
const void *  data2,
const void *  data3,
const void *  data4,
Float  blendS,
Float  blendT 
) const

Interpolates bilinearly between four data values. All addresses must be cast to the appropriate datatype.

Parameters
[in,out]data1The address of the first value. The value will be overwritten with the result.
[in]data2The address of the second value.
[in]data3The address of the third value.
[in]data4The address of the fourth value.
[in]blendSThe first blend percentage [0.0..blend..1.0]. Interpolation Scheme [data1 .. blendS .. data2] and [data4 .. blendS .. data3].
[in]blendTThe second blend percentage [0.0..blend..1.0]. Interpolation Scheme [blendS1 .. blendT .. blendS2]

◆ GetInterpolationClass()

static MAXON_METHOD InterpolateType GetInterpolationClass ( const DataType datatype)
static

Return the interpolation class for the passed data type if exist.

Parameters
[in]datatypeThe DataType.
Returns
The interpolation class or an empty class if do not exist.