Build with this node

Start with a prompt in Studio, or copy it into your own coding agent.

Ask Studio

@maruaudio/dsp/filters/string-readout colours a string or body signal with up to three RBJ biquad sections in series: a high-pass low cut (Q 0.7071), a peaking band and a high shelf (Q 0.7071), each a @maru/filters-biquad state. A section runs only when it is engaged. With all three off, the tick returns its input unchanged, as a double.

const state = createStringReadout(); prepareStringReadout(state, 48000)
state.bandGain = -6; configureStringReadout(state)
const y = stringReadoutTick(state, x)

Parameters

There are no setters. The caller writes the state fields, then calls configureStringReadout, which copies them into the biquads and updates their coefficients. The fields are not clamped.

FieldEngages the section whenDefaultUnit
cutoff> 0 (high-pass frequency)0 (off)Hz
bandGain!== 00 (off)dB
bandFrequencywith bandGain55Hz
bandQwith bandGain4Q
shelfGain!== 00 (off)dB
shelfFrequencywith shelfGain1000Hz

Lifecycle

createStringReadout (biquads at 48 kHz) → prepareStringReadout(state, rate) → field writes and configureStringReadout → stringReadoutTick → resetStringReadout. Prepare sets the rate, configures and clears all three histories. Configure runs outside the tick and clears any section it turns off, so a section switched back on does not replay an old tail. Reset clears the histories and keeps the fields.

When to use it

The radiation stage after a physical string or piano model: trim low rumble, cut or lift one resonance region and tilt the top end, with exact bypass when every control is neutral.

Limits

  • Mono sample tick; coefficient changes apply at once, with no smoothing.
  • Fields bypass the biquad setters, so the biquad clamps do not apply.
  • When any section is engaged the input is rounded to f32 before filtering.

Algorithm properties and proofs

No Lean 4 proof is mapped to this node.

Explore proofs alongside performance

Ports

  • In ininput · audio · mono
  • Out outoutput · audio · mono

One sample per stringReadoutTick call.

Dependencies

Dependents

No other node imports this one.

Used by