Interpolant
Base class for all interpolant types.
This is the base class for all interpolation methods used in keyframe
tracks. Each interpolant type provides a different method for
calculating values between keyframes.
Methods
Interpolant(const vector<f32>& parameterPositions, const vector<f32>& sampleValues, u32 sampleSize, vector<f32>* resultBuffer = nullptr)
Constructor for base interpolant
| parameterPositions | Array of parameter positions (times) | |
| sampleValues | Array of sample values | |
| sampleSize | Size of each sample | |
| resultBuffer | Optional result buffer | nullptr |
virtual f32 evaluate(f32 t) const
Evaluates the interpolant at parameter t
| t | Parameter value to evaluate |
void copySampleValue(u32 index) const
Copies a sample value to the result buffer
| index | Index of the sample to copy |
void copySampleValue(u32 index, f32 weight) const
Copies a weighted sample value to the result buffer
| index | Index of the sample to copy | |
| weight | Weight factor |