Effects & parameters
Per-channel FX and synth parameters are stored in SMP tables and applied by dedicated modules.
Modules
| File | Role |
|---|---|
toern_filter.ino | setFilters, mixer gain smoothing, filter transitions |
toern_filterUI.ino | Matrix sliders, pages, encoder colors for filter mode |
toern_parameters.ino | setParams, defaults, envelope/synth default packs, reset |
FX chain (conceptual)
For a typical sample channel:
envelope → bitcrusher → filter → freeverb → mixers → output
Synth channels insert oscillator/ladder stages earlier but still land in crush/filter/verb → mix.
UI value vs audio value
The matrix usually shows 0–32 (or enums as text). Mapping functions convert those into Hz, resonance, wet/dry, bit depth, etc. When adding a parameter:
- Extend the settings array /
FilterTypeor related enum if needed. - Teach
setFilters/setParamsthe mapping. - Add a slider definition for filter UI (
SliderDefEntry/ name index tables). - Keep display enums in sync with
enumNamespointers.
Fast filter encoder
During play, encoder #3 can adjust a per-channel “default fast filter” target (defaultFastFilter, setDefaultFastFilterValue) without entering full filter mode — useful when tracing runtime parameter paths.