The asymmetric one-pole that lags a control signal the way a photoresistor lags its LED. More...
#include <vactrol.hpp>
Public Member Functions | |
| VactrolConditionerT () | |
| void | prepare (double sample_rate) |
| void | set_rise_ms (double ms) |
| void | set_fall_ms (double ms) |
| double | rise_ms () const |
| double | fall_ms () const |
| void | reset () |
| double | control () const |
| Current conditioned control in [0, 1] without advancing. | |
| double | process (double target) |
| Advances one sample toward target (clamped to [0, 1]) and returns the conditioned control. | |
Static Public Attributes | |
| static constexpr double | kMinRiseMs = 0.1 |
| Default rise time in ms — the LED reaching brightness. | |
| static constexpr double | kMaxRiseMs = 50.0 |
| static constexpr double | kDefaultRiseMs = 2.0 |
| static constexpr double | kMinFallMs = 10.0 |
| Default fall time in ms — the photoresistor recovering. | |
| static constexpr double | kMaxFallMs = 2000.0 |
| static constexpr double | kDefaultFallMs = 200.0 |
The asymmetric one-pole that lags a control signal the way a photoresistor lags its LED.
Input and output are in [0, 1].
|
inline |
|
inline |
Current conditioned control in [0, 1] without advancing.
|
inline |
|
inline |
|
inline |
Advances one sample toward target (clamped to [0, 1]) and returns the conditioned control.
|
inline |
|
inline |
|
inline |
|
inline |
|
staticconstexpr |
|
staticconstexpr |
|
staticconstexpr |
|
staticconstexpr |
|
staticconstexpr |
Default fall time in ms — the photoresistor recovering.
Slow, and the control that sets how long a struck note takes to disappear. [design parameter] default 200 ms, range 10 .. 2000 ms.
|
staticconstexpr |
Default rise time in ms — the LED reaching brightness.
Fast. [design parameter] default 2.0 ms, range 0.1 .. 50 ms.