mirror of
https://github.com/juanjiant-bit/JIANT.git
synced 2026-12-06 04:44:33 +01:00
The owner: "a more aggressive filter type in the style of the Korg MS-20: a 2-pole Sallen-Key-style low-pass with diode-like soft clipping in the resonance feedback, screaming but controlled at high reso, the same knobs". TYPE 5, MS20 (voice.c tf_ms20): the trapezoidal SVF (dsp.c) held at damping 2 (no resonance of its own: the MS-20's soft knee at RES 0), its band-pass fed back into the input through softclip at half full scale, a sample late (the linear part stable, the clip bounded: bounded however it is driven). Its small-signal damping 2 - kn, RES exponential to it (2 x 2^-(6 RES / 127): Q 0.5 .. 33): soft in most of the travel, a scream at the top that still dies out when the part is silent (no whistle on its own); a hot input clipped in the loop growls instead of ringing louder. Out at 3/4 through a knee at 16000 (under full scale). CUT moves with LFO / ENV DEST FILTER as the SVF's (tf_run's sweep kept where it is heard); KNOB 4 drives as ever (ANALOG's DRIVE, the others' DIST). On ANALOG and LOFI the MS20 is the part's filter after the voices (their own open, as under the combs), at ANALOG's CUT RES (E4 E5: tf_run takes the cut it is given, P_FCUT for the others as before). TYPE crossfades in and out as the combs do (its state from the input, tf_ms). LP HP BP untouched (goldens). DRUM's IMAGE narrowed under it (the mono sum). The FILTER page draws it as a low-pass with a higher peak. Web editor: MS20. tests/filter_test.c: MS20 bounded and dying out at RES 0 / 100 / 127, CUT 0 / 64 / 127, C1..C8 (3 engines); its ring longer as RES rises; a full-scale saw at RES 127, every CUT, C1..C7: peak 31577, x0.99 .. x2.84 RES 0's level. The lockup check now about the mean (the SVF's fixed point holds a DC at CUT 0: no sound): every TYPE passes it, the old three too. Demo build/filter_demo/ms20_sweep.wav (a riff, CUT swept, RES 40 .. 127). CPU: tf_ms20's loop 94 instructions a sample (the SVF's in tf_run ~ the same), only on a part with MS20; tf_run 121 -> 126 (the branch; budgets added to target_budget.txt). Image 577496 -> 578116 B; RAM .data+.bss 88740 -> 88804 B (its state, 78 B); pool unchanged. Goldens 157 unchanged. MANUAL (EN, ES): MS20. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KMHk6yH4XbP1xxHYKCo9Mh