10 low_mode_(nullptr), band_mode_(nullptr), high_mode_(nullptr),
11 high_pass_(nullptr), low_shelf_(nullptr),
12 notch_(nullptr), band_shelf_(nullptr),
13 low_pass_(nullptr), high_shelf_(nullptr) {
173 for (
int i = 0; i < num_samples; ++i)
A state-variable filter (SVF) implementation, supporting multiple filter types (12/24 dB,...
Definition digital_svf.h:17
void setDriveCompensation(bool drive_compensation)
Enables or disables drive compensation (reducing drive as resonance increases).
Definition digital_svf.h:407
void reset(poly_mask reset_masks) override
Resets internal filter states for voices specified by the reset_masks.
Definition digital_svf.cpp:487
void setBasic(bool basic)
Sets whether this filter should use a simpler, “basic” processing path.
Definition digital_svf.h:400
void setSampleRate(int sample_rate) override
Sets the sample rate of the equalizer and propagates it to all internal filters.
Definition equalizer_module.cpp:141
Value * low_mode_
Determines if the low band uses a shelf or a high-pass filter.
Definition equalizer_module.h:78
void init() override
Initializes the EqualizerModule by creating parameter controls and linking them to internal filters.
Definition equalizer_module.cpp:17
std::shared_ptr< StereoMemory > audio_memory_
Memory buffer for storing processed audio samples.
Definition equalizer_module.h:89
DigitalSvf * low_shelf_
Low shelf filter for low band mode.
Definition equalizer_module.h:83
EqualizerModule()
Constructs an EqualizerModule.
Definition equalizer_module.cpp:8
DigitalSvf * band_shelf_
Band shelf filter for mid band mode.
Definition equalizer_module.h:85
DigitalSvf * high_pass_
High-pass filter for low band mode.
Definition equalizer_module.h:82
void hardReset() override
Resets the equalizer filters to their initial states, clearing any buffer or filter history.
Definition equalizer_module.cpp:111
DigitalSvf * low_pass_
Low-pass filter for high band mode.
Definition equalizer_module.h:86
Value * band_mode_
Determines if the mid band uses a shelf or a notch filter.
Definition equalizer_module.h:79
DigitalSvf * notch_
Notch filter for mid band mode.
Definition equalizer_module.h:84
void enable(bool enable) override
Enables or disables the equalizer module.
Definition equalizer_module.cpp:123
void processWithInput(const poly_float *audio_in, int num_samples) override
Processes an input audio buffer through the equalizer.
Definition equalizer_module.cpp:153
DigitalSvf * high_shelf_
High shelf filter for high band mode.
Definition equalizer_module.h:87
Value * high_mode_
Determines if the high band uses a shelf or a low-pass filter.
Definition equalizer_module.h:80
Base class for all signal-processing units in Vital.
Definition processor.h:212
void useOutput(Output *output)
Uses an existing Output object as this Processor's first output.
Definition processor.cpp:138
void plug(const Output *source)
Connects an external Output to this Processor's first input.
Definition processor.cpp:79
virtual void process(int num_samples)=0
Main processing function. Called by the ProcessorRouter.
force_inline Output * output(unsigned int index=0) const
Retrieves the Output pointer at a given index.
Definition processor.h:616
virtual void setSampleRate(int sample_rate)
Updates the sample rate of this Processor (scaled by oversampling).
Definition processor.h:285
virtual void init()
Called after constructor, used for any additional initialization. Subclasses can override....
Definition processor.h:258
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 s...
Definition processor.h:252
virtual void addIdleProcessor(Processor *processor)
Adds a Processor that should remain idle (not processed) in the router.
Definition processor_router.cpp:146
virtual void process(int num_samples) override
Processes audio through all Processors managed by this router.
Definition processor_router.cpp:57
@ kPassBlend
Blending parameter for low-pass, high-pass, band-pass.
Definition synth_filter.h:62
@ kResonance
Resonance parameter.
Definition synth_filter.h:58
@ kMidiCutoff
MIDI-based cutoff parameter.
Definition synth_filter.h:57
@ kStyle
Filter style (12 dB, 24 dB, etc.)
Definition synth_filter.h:61
@ kGain
Additional gain.
Definition synth_filter.h:60
@ kNotchPassSwap
Definition synth_filter.h:77
@ kShelving
Definition synth_filter.h:80
@ k12Db
Definition synth_filter.h:75
A ProcessorRouter that encapsulates a cohesive unit of functionality in the synthesizer.
Definition synth_module.h:129
Value * createBaseControl(std::string name, bool audio_rate=false, bool smooth_value=false)
Creates a simple control processor for a given parameter name.
Definition synth_module.cpp:22
virtual void enable(bool enable) override
Enables or disables this SynthModule and its owned processors.
Definition synth_module.cpp:516
Output * createMonoModControl(std::string name, bool audio_rate=false, bool smooth_value=false, Output *internal_modulation=nullptr)
Creates a monophonic mod control, including applying parameter scaling.
Definition synth_module.cpp:104
force_inline mono_float value() const
Returns the current mono_float value of the first lane.
Definition value.h:60
A control-rate variant of the Value processor.
Definition value.h:82
const poly_mask kFullMask
A mask covering all lanes of a poly_float vector.
Definition synth_constants.h:257
const cr::Value kValueZero(0.0f)
const cr::Value kValueTwo(2.0f)
const cr::Value kValueOne(1.0f)
Contains classes and functions used within the Vital synthesizer framework.
constexpr int kAudioMemorySamples
Size of the stereo audio memory buffer used for visualization.
Definition synth_constants.h:58
Holds and manages a buffer of samples (poly_float) for a Processor's output.
Definition processor.h:35
poly_float * buffer
Pointer to the output buffer.
Definition processor.h:110
Represents a vector of floating-point values using SIMD instructions.
Definition poly_values.h:600
Declares Value processors that output a constant value and can be dynamically set.