void ParameterRamper::init() { /* Call this from the kernel init. Updates the internal value from the UI value. */ setImmediate(data->uiValue); }
void ParameterRamper::startRamp(float newGoal, uint32_t duration) { if (duration == 0) { setImmediate(newGoal); } else { /* Set a new ramp. Assigning to inverseSlope must come before assigning to goal. */ data->inverseSlope = (get() - newGoal) / float(duration); data->samplesRemaining = duration; data->goal = data->uiValue = newGoal; } }
void init() { setImmediate(_uiValue); }
ParameterRamper::ParameterRamper(float value) : data(new InternalData) { setImmediate(value); }
ParameterRamper(float value) { setImmediate(value); }