This is the base class for all modulation behaviour. More...
Public Types | |
enum | Mode { GainMode = 0, PitchMode, PanMode } |
There are two modes that Modulation can work: GainMode and PitchMode. More... | |
Public Member Functions | |
void | applyModulationValue (float calculatedModulationValue, float &destinationValue) const noexcept |
This applies the previously calculated value to the supplied destination value depending on the modulation mode (adding or multiplying). More... | |
float | calcIntensityValue (float calculatedModulationValue) const noexcept |
This applies the intensity to the given value and returns the applied value. More... | |
float | getDisplayIntensity () const noexcept |
Returns the actual intensity of the Modulation. More... | |
float | getIntensity () const noexcept |
Returns the intensity. More... | |
Mode | getMode () const noexcept |
returns the mode the Modulator is operating. More... | |
void | setIntensity (float newIntensity) noexcept |
Sets the intensity of the modulation. More... | |
void | setIntensityFromSlider (float sliderValue) noexcept |
Use this method to set the intensity from the ModulatorEditorHeader's intensity slider converting linear -12 ... More... | |
This is the base class for all modulation behaviour.
enum Mode |
There are two modes that Modulation can work: GainMode and PitchMode.
|
noexcept |
This applies the previously calculated value to the supplied destination value depending on the modulation mode (adding or multiplying).
|
noexcept |
This applies the intensity to the given value and returns the applied value.
|
noexcept |
Returns the actual intensity of the Modulation.
Use this for GUI displays, since getIntensity() could be overwritten and behave funky.
|
noexcept |
Returns the intensity.
This is used by the modulator chain to either multiply or add the outcome of the Modulation.
You can subclass this method if you modulate the intensity. In this case, don't change the intensity directly (or you can't change it in the GUI anymore), but save the modulation value elsewhere and return the product:
virtual float getIntensity() const { return intensityModulation * Modulator::getIntensity(); };
|
noexcept |
Sets the intensity of the modulation.
The intensity is multiplied with the outcome or added depending on the TargetMode of the owner ModulatorChain.
In GainMode, the Intensity is between 0.0 and 1.0. In PitchMode, the Intensity can be between 0.5 and 2.0.
|
noexcept |
Use this method to set the intensity from the ModulatorEditorHeader's intensity slider converting linear -12 ...
12 to log 0.5 ... 2.