Contents

class

SushiDSP::FmvToneStack

The passive FMV stack, solved from its netlist by the nodal DK method.

Declared in
include/SushiDSP/circuits/FmvToneStack.hpp

The deck is the Bassman arrangement: the treble cap feeds the treble pot, whose wiper is the output and whose bottom end joins the bass pot; the slope resistor feeds a node that reaches the bass pot through the bass cap and the middle pot through the middle cap; the middle pot is a rheostat to ground under the bass pot. That netlist reproduces the hand-derived closed form this class used to carry to 1.2e-14 across 480 knob and frequency combinations, which is what test_fmv_tone_stack.cpp asserts.

Public member functions

FmvToneStack(double sample_rate, const FmvComponents &components, const FmvSourceLoad &termination={})

Parameters

sample_rate

The rate the section runs at, in hertz.

components

The stack's component values.

termination

What drives the input and what loads the output.

void set_bass(float normalized)

Sets the bass pot position and re-derives the matrices.

Parameters

normalized

Bass pot position in [0, 1]. Values outside are clamped.

void set_middle(float normalized)

Sets the middle pot position and re-derives the matrices.

Parameters

normalized

Middle pot position in [0, 1]. Values outside are clamped.

void set_treble(float normalized)

Sets the treble pot position and re-derives the matrices.

Parameters

normalized

Treble pot position in [0, 1]. Values outside are clamped.

float process_sample(float input)

Processes one sample.

Audio-thread safe.

Parameters

input

The input sample.

Returns

The tone-shaped output sample.

void reset()

Clears the reactive state.