Switchboard SDK
|
Ducks music signal based on voice signal. Music signal has to be connected to the first input bus, ducking voice signals have to be connected to the second input bus. Output is the ducked music signal. More...
#include <MusicDuckingV2Node.hpp>
Public Member Functions | |
WASM float | getDuckingAmount () const |
Gets the current ducking amount. Returned value is between 0 and 1. | |
WASM void | setDuckingAmount (float duckingAmount) |
Sets the current ducking amount. The provided value has to be between 0 and 1, where 0 means no ducking and 1 means maximum ducking. | |
WASM float | getActivationThreshold () const |
Gets the current ducking amount. Returned value is between 0 and 1. | |
WASM void | setActivationThreshold (float threshold) |
Sets the current activation threshold. The provided value has to be between 0 and 1. | |
WASM void | setAttackSeconds (float attackSeconds) |
Sets the attack time of the ducking. | |
WASM float | getAttackSeconds () const |
Gets the current attack time of the ducking. | |
WASM void | setReleaseSeconds (float releaseSeconds) |
Sets the release time of the ducking. | |
WASM float | getReleaseSeconds () const |
Gets the current release time of the ducking. | |
WASM void | setHoldSeconds (float holdSeconds) |
Sets the hold time of the ducking. | |
WASM float | getHoldSeconds () const |
Gets the current hold time of the ducking. | |
WASM bool | getForcedDuckingEnabled () const |
Gets whether forced ducking is enabled. | |
WASM void | setForcedDuckingEnabled (const bool newValue) |
Enables or disables forced ducking. | |
bool | setNumberOfBuses (const uint numberOfInputBuses, const uint numberOfOutputBuses) override |
Sets number of buses. | |
bool | setBusFormats (AudioBusFormatList &inputBusFormats, AudioBusFormatList &outputBusFormats) override |
Sets bus formats. | |
bool | process (AudioBusList &inBuses, AudioBusList &outBuses) override |
Processes audio data from the given input buses and produces the audio output to the given output buses. | |
Public Member Functions inherited from switchboard::AudioProcessorNode | |
virtual | ~AudioProcessorNode ()=default |
AudioProcessorNode virtual destructor. | |
Public Member Functions inherited from switchboard::AudioNode | |
AudioNode () | |
AudioNode constructor. | |
virtual | ~AudioNode ()=default |
AudioNode virtual destructor. | |
const std::string & | getType () const |
Gets the type of the audio node. | |
virtual const std::string | getDisplayName () const |
Gets the display name of the audio node. | |
virtual std::vector< std::unique_ptr< Parameter > > & | getParameters () |
Gets the parameters of the audio node. | |
virtual Parameter * | getParameter (const std::string &name) |
Gets the parameter with the given name. | |
Additional Inherited Members | |
Public Attributes inherited from switchboard::AudioNode | |
std::string | name |
The name of the audio node. | |
Protected Attributes inherited from switchboard::AudioNode | |
std::string | type |
std::vector< std::unique_ptr< Parameter > > | parameters |
Ducks music signal based on voice signal. Music signal has to be connected to the first input bus, ducking voice signals have to be connected to the second input bus. Output is the ducked music signal.
MusicDuckingV2Node class.
float switchboard::MusicDuckingV2Node::getActivationThreshold | ( | ) | const |
Gets the current ducking amount. Returned value is between 0 and 1.
float switchboard::MusicDuckingV2Node::getAttackSeconds | ( | ) | const |
Gets the current attack time of the ducking.
float switchboard::MusicDuckingV2Node::getDuckingAmount | ( | ) | const |
Gets the current ducking amount. Returned value is between 0 and 1.
bool switchboard::MusicDuckingV2Node::getForcedDuckingEnabled | ( | ) | const |
Gets whether forced ducking is enabled.
When forced ducking is enabled, the input ducking signal is ignored and ducking is always applied.
float switchboard::MusicDuckingV2Node::getHoldSeconds | ( | ) | const |
Gets the current hold time of the ducking.
float switchboard::MusicDuckingV2Node::getReleaseSeconds | ( | ) | const |
Gets the current release time of the ducking.
|
overridevirtual |
Processes audio data from the given input buses and produces the audio output to the given output buses.
Should be overridden by subclasses.
inBuses | The input buses that contain the audio data. |
outBuses | The output buses which should be filled with the processed audio data. |
Implements switchboard::AudioProcessorNode.
void switchboard::MusicDuckingV2Node::setActivationThreshold | ( | float | threshold | ) |
Sets the current activation threshold. The provided value has to be between 0 and 1.
threshold | The new activation threshold. |
void switchboard::MusicDuckingV2Node::setAttackSeconds | ( | float | attackSeconds | ) |
Sets the attack time of the ducking.
When set to 0, the ducking is applied immediately without any ramping.
attackSeconds | The new attack time value in seconds. |
|
overridevirtual |
Sets bus formats.
Should be overridden by subclasses. Please note that setNumberOfBuses is guaranteed to be called before this method.
inputBusFormats | The input bus formats to set. |
outputBusFormats | The output bus formats to set. |
Implements switchboard::AudioProcessorNode.
void switchboard::MusicDuckingV2Node::setDuckingAmount | ( | float | duckingAmount | ) |
Sets the current ducking amount. The provided value has to be between 0 and 1, where 0 means no ducking and 1 means maximum ducking.
duckingAmount | The new amount. |
void switchboard::MusicDuckingV2Node::setForcedDuckingEnabled | ( | const bool | newValue | ) |
Enables or disables forced ducking.
newValue | True when it is enabled, false when it is not. |
void switchboard::MusicDuckingV2Node::setHoldSeconds | ( | float | holdSeconds | ) |
Sets the hold time of the ducking.
holdSeconds | The new hold time value in seconds. |
|
overridevirtual |
Sets number of buses.
Should be overridden by subclasses
numberOfInputBuses | The number of input buses to set. |
numberOfOutputBuses | The number of output buses to set. |
Implements switchboard::AudioProcessorNode.
void switchboard::MusicDuckingV2Node::setReleaseSeconds | ( | float | releaseSeconds | ) |
Sets the release time of the ducking.
When set to 0, the ducking is disabled immediately without any ramping.
releaseSeconds | The new release time value in seconds. |