Vital
Loading...
Searching...
No Matches
vital::ModulationConnectionProcessor Class Reference

A processor that applies a modulation signal to a parameter, performing mapping, scaling, and morphing. More...

#include <modulation_connection_processor.h>

Inheritance diagram for vital::ModulationConnectionProcessor:
vital::SynthModule vital::ProcessorRouter vital::Processor

Public Types

enum  {
  kModulationInput , kModulationAmount , kModulationPower , kReset ,
  kNumInputs
}
 Input parameter indices. More...
 
enum  { kModulationOutput , kModulationPreScale , kModulationSource , kNumOutputs }
 Output parameter indices. More...
 

Public Member Functions

 ModulationConnectionProcessor (int index)
 Constructs a ModulationConnectionProcessor with a given index.
 
virtual ~ModulationConnectionProcessor ()
 
void init () override
 Initializes the processor, creating and connecting parameter controls (e.g., bipolar, stereo, bypass).
 
void process (int num_samples) override
 Processes a block of samples, handling both control-rate and audio-rate modulation.
 
void processAudioRate (int num_samples, const Output *source)
 Processes the modulation at audio-rate using the provided source output.
 
void processAudioRateLinear (int num_samples, const Output *source)
 Audio-rate processing with a linear transform (no remap, no morph).
 
void processAudioRateRemapped (int num_samples, const Output *source)
 Audio-rate processing with remapping via LineGenerator, but no morphing power.
 
void processAudioRateMorphed (int num_samples, const Output *source, poly_float power)
 Audio-rate processing with morphing power applied (no remapping).
 
void processAudioRateRemappedAndMorphed (int num_samples, const Output *source, poly_float power)
 Audio-rate processing with both remapping and morphing power applied.
 
void processControlRate (const Output *source)
 Processes the modulation at control-rate (once per block), when modulation or source is not audio-rate.
 
virtual Processorclone () const override
 Creates a clone of this processor.
 
void initializeBaseValue (Value *base_value)
 Initializes a base value for this modulation connection, used as a starting point.
 
void initializeMapping ()
 Sets the mapping function to a linear mapping in the internal LineGenerator.
 
mono_float currentBaseValue () const
 Retrieves the current base value of the modulation connection.
 
void setBaseValue (mono_float value)
 Sets the base value of the modulation connection.
 
bool isPolyphonicModulation () const
 Checks if the modulation is polyphonic (per-voice).
 
void setPolyphonicModulation (bool polyphonic)
 Sets whether the modulation should be treated as polyphonic.
 
bool isBipolar () const
 Checks if the modulation is bipolar (range -1 to 1).
 
void setBipolar (bool bipolar)
 Sets whether the modulation should be bipolar.
 
bool isStereo () const
 Checks if the modulation is stereo, applying a different scale factor to the right channel.
 
void setStereo (bool stereo)
 Sets whether the modulation should be stereo.
 
bool isBypassed () const
 Checks if the modulation connection is bypassed.
 
force_inline void setDestinationScale (mono_float scale)
 Sets the scaling factor for the destination parameter.
 
force_inline int index () const
 Gets the index identifier of this modulation connection.
 
LineGeneratorlineMapGenerator ()
 Retrieves the LineGenerator (map_generator_) used for remapping the modulation.
 
- Public Member Functions inherited from vital::SynthModule
 SynthModule (int num_inputs, int num_outputs, bool control_rate=false)
 Constructs a SynthModule with specified I/O and control rate.
 
virtual ~SynthModule ()
 Destructor.
 
control_map getControls ()
 Returns a map of all controls from this module and its submodules.
 
OutputgetModulationSource (std::string name)
 Retrieves a modulation source output by name.
 
const StatusOutputgetStatusOutput (std::string name) const
 Retrieves a StatusOutput by name.
 
ProcessorgetModulationDestination (std::string name, bool poly)
 Retrieves a modulation destination Processor by name and poly mode.
 
ProcessorgetMonoModulationDestination (std::string name)
 Retrieves a mono modulation destination by name.
 
ProcessorgetPolyModulationDestination (std::string name)
 Retrieves a poly modulation destination by name.
 
ValueSwitchgetModulationSwitch (std::string name, bool poly)
 Retrieves a modulation switch by name and poly mode.
 
ValueSwitchgetMonoModulationSwitch (std::string name)
 Retrieves a mono modulation switch by name.
 
ValueSwitchgetPolyModulationSwitch (std::string name)
 Retrieves a poly modulation switch by name.
 
void updateAllModulationSwitches ()
 Updates all modulation switches based on whether their destinations have inputs.
 
output_mapgetModulationSources ()
 Returns a reference to the map of modulation sources.
 
input_mapgetMonoModulationDestinations ()
 Returns a reference to the map of mono modulation destinations.
 
input_mapgetPolyModulationDestinations ()
 Returns a reference to the map of poly modulation destinations.
 
virtual output_mapgetMonoModulations ()
 Returns a reference to the map of mono modulation readouts.
 
virtual output_mapgetPolyModulations ()
 Returns a reference to the map of poly modulation readouts.
 
virtual void correctToTime (double seconds)
 Allows correction of module state to a given time (if needed).
 
void enableOwnedProcessors (bool enable)
 Enables or disables all owned processors.
 
virtual void enable (bool enable) override
 Enables or disables this SynthModule and its owned processors.
 
void addMonoProcessor (Processor *processor, bool own=true)
 Adds a mono processor to this module.
 
void addIdleMonoProcessor (Processor *processor)
 Adds a mono processor that is considered idle (not part of main processing chain).
 
void addSubmodule (SynthModule *module)
 Adds a submodule to this SynthModule.
 
- Public Member Functions inherited from vital::ProcessorRouter
 ProcessorRouter (int num_inputs=0, int num_outputs=0, bool control_rate=false)
 Constructs a ProcessorRouter with a specified number of inputs and outputs.
 
 ProcessorRouter (const ProcessorRouter &original)
 Copy constructor. Creates a new ProcessorRouter from an existing one.
 
virtual ~ProcessorRouter ()
 Destructor.
 
virtual void setSampleRate (int sample_rate) override
 Sets the sample rate for all Processors in this router.
 
virtual void setOversampleAmount (int oversample) override
 Sets the oversampling amount for all Processors in this router.
 
virtual void addProcessor (Processor *processor)
 Adds a Processor to be managed by this router.
 
virtual void addProcessorRealTime (Processor *processor)
 Adds a Processor to the router in real-time (no memory allocations).
 
virtual void addIdleProcessor (Processor *processor)
 Adds a Processor that should remain idle (not processed) in the router.
 
virtual void removeProcessor (Processor *processor)
 Removes a Processor from this router.
 
void connect (Processor *destination, const Output *source, int index)
 Connects a source Output to a destination Processor input by index.
 
void disconnect (const Processor *destination, const Output *source)
 Disconnects a source Output from a destination Processor.
 
bool isDownstream (const Processor *first, const Processor *second) const
 Checks if one Processor is downstream from another, i.e., if there's a path from the second to the first.
 
bool areOrdered (const Processor *first, const Processor *second) const
 Checks if the order of two Processors is fixed in the router's processing sequence.
 
virtual bool isPolyphonic (const Processor *processor) const
 Determines if a given Processor is polyphonic within this router.
 
virtual ProcessorRoutergetMonoRouter ()
 Gets the mono router that corresponds to this ProcessorRouter.
 
virtual ProcessorRoutergetPolyRouter ()
 Gets the polyphonic router that corresponds to this ProcessorRouter.
 
virtual void resetFeedbacks (poly_mask reset_mask)
 Resets all Feedback nodes within this router using a reset mask.
 
- Public Member Functions inherited from vital::Processor
 Processor (int num_inputs, int num_outputs, bool control_rate=false, int max_oversample=1)
 Constructs a Processor with a given number of inputs/outputs and oversampling.
 
virtual ~Processor ()
 Virtual destructor.
 
virtual bool hasState () const
 Indicates whether this Processor requires per-voice state.
 
virtual void processWithInput (const poly_float *audio_in, int num_samples)
 An optional processing function taking explicit input buffer. Fallback is an assertion failure (not supported).
 
virtual void reset (poly_mask reset_mask)
 Called to reset the Processor's per-voice state (e.g., on note-on).
 
virtual void hardReset ()
 Called to perform a "hard" reset for all voices.
 
bool initialized ()
 Returns whether this Processor has been initialized.
 
force_inline bool enabled () const
 Checks if this Processor is enabled.
 
force_inline int getSampleRate () const
 Retrieves the current (effective) sample rate.
 
force_inline int getOversampleAmount () const
 Retrieves the current oversampling factor.
 
force_inline bool isControlRate () const
 Checks if this Processor is running at control rate (buffer_size == 1).
 
virtual void setControlRate (bool control_rate)
 Sets whether this Processor runs at control rate.
 
force_inline poly_mask getResetMask (int input_index) const
 Retrieves a mask indicating which voices triggered a note-on event. Compares the input's trigger_value to kVoiceOn.
 
force_inline void clearOutputBufferForReset (poly_mask reset_mask, int input_index, int output_index) const
 Clears output samples for voices that are about to be reset, based on the trigger offset.
 
bool inputMatchesBufferSize (int input=0)
 Checks whether the buffer size of a particular input matches the size needed by this Processor.
 
bool checkInputAndOutputSize (int num_samples)
 Checks if all inputs and outputs have buffers big enough for num_samples.
 
virtual bool isPolyphonic () const
 Checks if this Processor is polyphonic by querying its ProcessorRouter.
 
void plug (const Output *source)
 Connects an external Output to this Processor's first input.
 
void plug (const Output *source, unsigned int input_index)
 Connects an external Output to a specified input index.
 
void plug (const Processor *source)
 Connects the first output of a Processor to this Processor's first input.
 
void plug (const Processor *source, unsigned int input_index)
 Connects the first output of a Processor to a specified input index.
 
void plugNext (const Output *source)
 Connects an external Output to the first available (unplugged) input.
 
void plugNext (const Processor *source)
 Connects the first output of a Processor to the first available (unplugged) input.
 
void useInput (Input *input)
 Uses an existing Input object as this Processor's first input.
 
void useInput (Input *input, int index)
 Uses an existing Input object at a specified input index.
 
void useOutput (Output *output)
 Uses an existing Output object as this Processor's first output.
 
void useOutput (Output *output, int index)
 Uses an existing Output object at a specified output index.
 
int connectedInputs ()
 Counts how many inputs are connected to a real source (not null_source_).
 
virtual void unplugIndex (unsigned int input_index)
 Removes the connection at a specified input index, if any.
 
virtual void unplug (const Output *source)
 Removes a connection to a given Output from all inputs.
 
virtual void unplug (const Processor *source)
 Removes connections to all outputs from a given Processor.
 
virtual void numInputsChanged ()
 Called when the number of inputs changes (e.g., new connections). Subclasses may override for dynamic behavior.
 
force_inline void router (ProcessorRouter *router)
 Sets the ProcessorRouter that owns or manages this Processor.
 
force_inline ProcessorRouterrouter () const
 Returns the ProcessorRouter that currently owns this Processor.
 
ProcessorRoutergetTopLevelRouter () const
 Gets the topmost (root) ProcessorRouter by traversing parent routers.
 
virtual void registerInput (Input *input, int index)
 Registers a new input, appending it to the input list.
 
virtual OutputregisterOutput (Output *output, int index)
 Registers a new Output in the output list at a specified index.
 
virtual void registerInput (Input *input)
 Registers a new Input by appending it to the end of the input list.
 
virtual OutputregisterOutput (Output *output)
 Registers a new Output by appending it to the end of the output list.
 
force_inline int numInputs () const
 Returns the total number of Input pointers (owned or otherwise).
 
force_inline int numOutputs () const
 Returns the total number of Output pointers (owned or otherwise).
 
force_inline int numOwnedInputs () const
 Returns how many Input objects this Processor owns.
 
force_inline int numOwnedOutputs () const
 Returns how many Output objects this Processor owns.
 
force_inline Inputinput (unsigned int index=0) const
 Retrieves the Input pointer at a given index.
 
force_inline bool isInputSourcePolyphonic (int index=0)
 Checks if the input source at a given index is polyphonic.
 
force_inline InputownedInput (unsigned int index=0) const
 Retrieves an owned Input pointer at a given index.
 
force_inline Outputoutput (unsigned int index=0) const
 Retrieves the Output pointer at a given index.
 
force_inline OutputownedOutput (unsigned int index=0) const
 Retrieves an owned Output pointer at a given index.
 
void setPluggingStart (int start)
 Sets the position at which plugNext starts searching for an open input.
 

Protected Attributes

int index_
 Unique identifier for this modulation connection.
 
bool polyphonic_
 True if modulation is polyphonic.
 
Valuecurrent_value_
 The base or initial value for the modulation.
 
Valuebipolar_
 Controls if the modulation is bipolar.
 
Valuestereo_
 Controls if the modulation is stereo.
 
Valuebypass_
 Controls if the modulation connection is bypassed.
 
poly_float power_
 Stored current power for morphing modulation.
 
poly_float modulation_amount_
 The current modulation amount scaled by the destination scale.
 
std::shared_ptr< mono_floatdestination_scale_
 The scale factor for final modulation output.
 
mono_float last_destination_scale_
 The last known destination scale to detect changes.
 
std::shared_ptr< LineGeneratormap_generator_
 The line mapping function for remapping modulation.
 
- Protected Attributes inherited from vital::SynthModule
std::shared_ptr< ModuleDatadata_
 Shared data storage for this SynthModule.
 
- Protected Attributes inherited from vital::ProcessorRouter
std::shared_ptr< CircularQueue< Processor * > > global_order_
 Global processing order reference.
 
std::shared_ptr< CircularQueue< Processor * > > global_reorder_
 Temporary storage for reorder operations.
 
CircularQueue< Processor * > local_order_
 Local ordering of Processors.
 
std::map< const Processor *, std::pair< int, std::unique_ptr< Processor > > > processors_
 Map of global to local Processors.
 
std::map< const Processor *, std::unique_ptr< Processor > > idle_processors_
 Idle Processors that are not active in the graph.
 
std::shared_ptr< std::vector< const Feedback * > > global_feedback_order_
 Global order of Feedback nodes.
 
std::vector< Feedback * > local_feedback_order_
 Local copies of Feedback nodes.
 
std::map< const Processor *, std::pair< int, std::unique_ptr< Feedback > > > feedback_processors_
 Map of global to local Feedback processors.
 
std::shared_ptr< int > global_changes_
 Global change counter.
 
int local_changes_
 Local change counter to track synchronization with global changes.
 
std::shared_ptr< CircularQueue< const Processor * > > dependencies_
 Queue for dependencies calculations.
 
std::shared_ptr< CircularQueue< const Processor * > > dependencies_visited_
 Queue of visited processors for dependencies calc.
 
std::shared_ptr< CircularQueue< const Processor * > > dependency_inputs_
 Queue of processors to check inputs for dependencies.
 
- Protected Attributes inherited from vital::Processor
std::shared_ptr< ProcessorStatestate_
 Shared state (sample rate, oversample, etc.)
 
int plugging_start_
 The index at which plugNext starts searching for an unplugged input.
 
std::vector< std::shared_ptr< Input > > owned_inputs_
 Inputs owned by this Processor.
 
std::vector< std::shared_ptr< Output > > owned_outputs_
 Outputs owned by this Processor.
 
std::shared_ptr< std::vector< Input * > > inputs_
 All inputs, owned or external.
 
std::shared_ptr< std::vector< Output * > > outputs_
 All outputs, owned or external.
 
ProcessorRouterrouter_
 The ProcessorRouter that manages this Processor.
 

Additional Inherited Members

- Protected Member Functions inherited from vital::SynthModule
ValuecreateBaseControl (std::string name, bool audio_rate=false, bool smooth_value=false)
 Creates a simple control processor for a given parameter name.
 
OutputcreateBaseModControl (std::string name, bool audio_rate=false, bool smooth_value=false, Output *internal_modulation=nullptr)
 Creates a base mod control, which is a control combined with a modulation input.
 
OutputcreateMonoModControl (std::string name, bool audio_rate=false, bool smooth_value=false, Output *internal_modulation=nullptr)
 Creates a monophonic mod control, including applying parameter scaling.
 
OutputcreatePolyModControl (std::string name, bool audio_rate=false, bool smooth_value=false, Output *internal_modulation=nullptr, Input *reset=nullptr)
 Creates a polyphonic mod control, including applying parameter scaling.
 
OutputcreateTempoSyncSwitch (std::string name, Processor *frequency, const Output *beats_per_second, bool poly, Input *midi=nullptr)
 Creates a tempo sync switch that toggles between tempo-based frequency and free-running frequency.
 
void createStatusOutput (std::string name, Output *source)
 Creates a status output associated with a given Output.
 
- Protected Member Functions inherited from vital::ProcessorRouter
virtual void addFeedback (Feedback *feedback)
 Adds a Feedback node to handle a feedback loop introduced by a connection.
 
virtual void removeFeedback (Feedback *feedback)
 Removes a previously added Feedback node.
 
void reorder (Processor *processor)
 Reorders the internal processing sequence to account for a Processor's dependencies.
 
virtual void updateAllProcessors ()
 Updates all processors to match the global order. Called when changes occur.
 
force_inline bool shouldUpdate ()
 Checks if local changes need to be synchronized with global changes.
 
virtual void createAddedProcessors ()
 Creates any processors that were added at the global level but not yet replicated locally.
 
virtual void deleteRemovedProcessors ()
 Deletes any processors that were removed at the global level but not yet removed locally.
 
const ProcessorgetContext (const Processor *processor) const
 Gets the processor context within this router for a global Processor reference.
 
void getDependencies (const Processor *processor) const
 Populates the internal dependencies structure for a given Processor.
 
ProcessorgetLocalProcessor (const Processor *global_processor)
 Retrieves the local instance of a globally defined Processor.
 
- Protected Member Functions inherited from vital::Processor
OutputaddOutput (int oversample=1)
 Creates and registers a new Output. Handles control rate vs. audio rate.
 
InputaddInput ()
 Creates and registers a new Input, initially connected to null_source_.
 
- Static Protected Attributes inherited from vital::Processor
static const Output null_source_
 A null (dummy) source used for unconnected inputs.
 

Detailed Description

A processor that applies a modulation signal to a parameter, performing mapping, scaling, and morphing.

The ModulationConnectionProcessor takes a modulation input (e.g., from an LFO or envelope), applies transformations such as bipolar shifting, remapping via a LineGenerator, applying power curves, and scaling by a destination amount. It can handle both control-rate and audio-rate modulation, and supports polyphonic and stereo modulation. The output is a transformed modulation signal ready to be applied to a parameter in the synth.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum

Input parameter indices.

  • kModulationInput: The raw modulation source signal.
  • kModulationAmount: The scaling amount applied to the modulation signal.
  • kModulationPower: The morphing power used for nonlinear shaping of the modulation.
  • kReset: A reset trigger to reinitialize states for new voice events.
Enumerator
kModulationInput 
kModulationAmount 
kModulationPower 
kReset 
kNumInputs 

◆ anonymous enum

anonymous enum

Output parameter indices.

  • kModulationOutput: The final, transformed modulation signal after all processing.
  • kModulationPreScale: The modulation signal before final scaling (for debug or further usage).
  • kModulationSource: The source modulation trigger value (for analysis or debug).
Enumerator
kModulationOutput 
kModulationPreScale 
kModulationSource 
kNumOutputs 

Constructor & Destructor Documentation

◆ ModulationConnectionProcessor()

vital::ModulationConnectionProcessor::ModulationConnectionProcessor ( int index)

Constructs a ModulationConnectionProcessor with a given index.

Parameters
indexAn identifier for this modulation connection, for parameter naming and tracking.

◆ ~ModulationConnectionProcessor()

virtual vital::ModulationConnectionProcessor::~ModulationConnectionProcessor ( )
inlinevirtual

Member Function Documentation

◆ clone()

virtual Processor * vital::ModulationConnectionProcessor::clone ( ) const
inlineoverridevirtual

Creates a clone of this processor.

Returns
A new ModulationConnectionProcessor instance with identical settings.

Reimplemented from vital::SynthModule.

◆ currentBaseValue()

mono_float vital::ModulationConnectionProcessor::currentBaseValue ( ) const
inline

Retrieves the current base value of the modulation connection.

Returns
The current base value as a mono_float.

◆ index()

force_inline int vital::ModulationConnectionProcessor::index ( ) const
inline

Gets the index identifier of this modulation connection.

Returns
The index of the modulation connection.

◆ init()

void vital::ModulationConnectionProcessor::init ( )
overridevirtual

Initializes the processor, creating and connecting parameter controls (e.g., bipolar, stereo, bypass).

Initializes parameters for bipolar, stereo, and bypass controls.

Reimplemented from vital::ProcessorRouter.

◆ initializeBaseValue()

void vital::ModulationConnectionProcessor::initializeBaseValue ( Value * base_value)
inline

Initializes a base value for this modulation connection, used as a starting point.

Parameters
base_valueA pointer to a Value that holds the base or default modulation value.

◆ initializeMapping()

void vital::ModulationConnectionProcessor::initializeMapping ( )
inline

Sets the mapping function to a linear mapping in the internal LineGenerator.

◆ isBipolar()

bool vital::ModulationConnectionProcessor::isBipolar ( ) const
inline

Checks if the modulation is bipolar (range -1 to 1).

Returns
True if bipolar, false if unipolar (0 to 1).

◆ isBypassed()

bool vital::ModulationConnectionProcessor::isBypassed ( ) const
inline

Checks if the modulation connection is bypassed.

Returns
True if bypassed, false if active.

◆ isPolyphonicModulation()

bool vital::ModulationConnectionProcessor::isPolyphonicModulation ( ) const
inline

Checks if the modulation is polyphonic (per-voice).

Returns
True if polyphonic, false if monophonic.

◆ isStereo()

bool vital::ModulationConnectionProcessor::isStereo ( ) const
inline

Checks if the modulation is stereo, applying a different scale factor to the right channel.

Returns
True if stereo, false if mono.

◆ lineMapGenerator()

LineGenerator * vital::ModulationConnectionProcessor::lineMapGenerator ( )
inline

Retrieves the LineGenerator (map_generator_) used for remapping the modulation.

Returns
A pointer to the LineGenerator instance.

◆ process()

void vital::ModulationConnectionProcessor::process ( int num_samples)
overridevirtual

Processes a block of samples, handling both control-rate and audio-rate modulation.

If the modulation or input source is control-rate, it processes once per block. Otherwise, it processes every sample.

Parameters
num_samplesNumber of samples in the block.

Handles choosing between control-rate or audio-rate processing, and prepares modulation inputs for further processing.

Reimplemented from vital::ProcessorRouter.

◆ processAudioRate()

void vital::ModulationConnectionProcessor::processAudioRate ( int num_samples,
const Output * source )

Processes the modulation at audio-rate using the provided source output.

This method determines if power morphing, remapping, or linear processing is needed and calls the appropriate function.

Parameters
num_samplesNumber of samples to process.
sourceThe modulation source output to read from.

Determines which audio-rate processing method to call based on power and remapping usage.

◆ processAudioRateLinear()

void vital::ModulationConnectionProcessor::processAudioRateLinear ( int num_samples,
const Output * source )

Audio-rate processing with a linear transform (no remap, no morph).

◆ processAudioRateMorphed()

void vital::ModulationConnectionProcessor::processAudioRateMorphed ( int num_samples,
const Output * source,
poly_float power )

Audio-rate processing with morphing power applied (no remapping).

◆ processAudioRateRemapped()

void vital::ModulationConnectionProcessor::processAudioRateRemapped ( int num_samples,
const Output * source )

Audio-rate processing with remapping via LineGenerator, but no morphing power.

◆ processAudioRateRemappedAndMorphed()

void vital::ModulationConnectionProcessor::processAudioRateRemappedAndMorphed ( int num_samples,
const Output * source,
poly_float power )

Audio-rate processing with both remapping and morphing power applied.

◆ processControlRate()

void vital::ModulationConnectionProcessor::processControlRate ( const Output * source)

Processes the modulation at control-rate (once per block), when modulation or source is not audio-rate.

Parameters
sourceThe modulation source output at control-rate.

Processes the modulation once per block at control-rate.

Involves applying remapping and morphing if needed, scaling, and applying bipolar and stereo adjustments.

◆ setBaseValue()

void vital::ModulationConnectionProcessor::setBaseValue ( mono_float value)
inline

Sets the base value of the modulation connection.

Parameters
valueThe new base value.

◆ setBipolar()

void vital::ModulationConnectionProcessor::setBipolar ( bool bipolar)
inline

Sets whether the modulation should be bipolar.

Parameters
bipolarTrue if bipolar, false otherwise.

◆ setDestinationScale()

force_inline void vital::ModulationConnectionProcessor::setDestinationScale ( mono_float scale)
inline

Sets the scaling factor for the destination parameter.

Parameters
scaleA mono_float scaling factor applied to the final modulation.

◆ setPolyphonicModulation()

void vital::ModulationConnectionProcessor::setPolyphonicModulation ( bool polyphonic)
inline

Sets whether the modulation should be treated as polyphonic.

Parameters
polyphonicTrue for polyphonic modulation, false for monophonic.

◆ setStereo()

void vital::ModulationConnectionProcessor::setStereo ( bool stereo)
inline

Sets whether the modulation should be stereo.

Parameters
stereoTrue if stereo, false otherwise.

Member Data Documentation

◆ bipolar_

Value* vital::ModulationConnectionProcessor::bipolar_
protected

Controls if the modulation is bipolar.

◆ bypass_

Value* vital::ModulationConnectionProcessor::bypass_
protected

Controls if the modulation connection is bypassed.

◆ current_value_

Value* vital::ModulationConnectionProcessor::current_value_
protected

The base or initial value for the modulation.

◆ destination_scale_

std::shared_ptr<mono_float> vital::ModulationConnectionProcessor::destination_scale_
protected

The scale factor for final modulation output.

◆ index_

int vital::ModulationConnectionProcessor::index_
protected

Unique identifier for this modulation connection.

◆ last_destination_scale_

mono_float vital::ModulationConnectionProcessor::last_destination_scale_
protected

The last known destination scale to detect changes.

◆ map_generator_

std::shared_ptr<LineGenerator> vital::ModulationConnectionProcessor::map_generator_
protected

The line mapping function for remapping modulation.

◆ modulation_amount_

poly_float vital::ModulationConnectionProcessor::modulation_amount_
protected

The current modulation amount scaled by the destination scale.

◆ polyphonic_

bool vital::ModulationConnectionProcessor::polyphonic_
protected

True if modulation is polyphonic.

◆ power_

poly_float vital::ModulationConnectionProcessor::power_
protected

Stored current power for morphing modulation.

◆ stereo_

Value* vital::ModulationConnectionProcessor::stereo_
protected

Controls if the modulation is stereo.


The documentation for this class was generated from the following files: