Compressor Module — Dynamics Compressor
A shared processor module used by all six synth engines (Neuro, BIA, Kick, Snare, Hihat). Juno uses a dedicated limiter instead.
Exports
| Export | Signature | Purpose |
|---|---|---|
paramDefs |
{} |
9 parameter definitions |
build |
(ctx, params) → {input, output, nodes} |
Creates compressor subgraph: split → dry/wet → SC HPF → compressor → makeup → sum |
update |
(nodes, params) → undefined |
Updates AudioParam values on an existing compressor graph |
Params
| Param | Range | Default | Description |
|---|---|---|---|
compThreshold |
–60–0 dB | –24 | Level above which compression begins |
compRatio |
1–20 | 4 | Amount of gain reduction above threshold |
compAttack |
0.001–0.1 s | 0.003 | How quickly the compressor responds |
compRelease |
0.01–1 s | 0.1 | How quickly compression releases |
compKnee |
0–40 dB | 30 (Neuro) / 0 (drums) | Softens the transition at threshold |
compMakeup |
0–24 dB | 0 | Output boost to compensate for gain reduction |
compMix |
0–1 | 1 | Dry/wet blend |
compSC |
off/on | off | Sidechain HPF on detection circuit |
compSCFreq |
20–1000 Hz | 200 | Sidechain HPF cutoff frequency |
Signal Flow
input → split → (→ SC HPF →) comp → makeupGain → wetGain → sum → output
└→ dryGain →────────────────────────────→ sum
When SC HPF is on, the compressor detection hears a highpass-filtered version of the signal, preventing low frequencies from triggering gain reduction.
Integrations
- Neuro: full 9 params, knee default 30 (soft), GR meter via formula
- Kick/Snare/Hihat/BIA: full 9 params, knee default 0 (hard), shared module
build()via backward loop
Previously each drum engine had an inline createDynamicsCompressor() with
only 4 params (threshold, ratio, attack, release). They now use the shared
module's build() for consistent feature coverage.