FX INTRODUCTION / 07 / DRAFT
Wobble: move a filter
Move from a fixed low-pass filter to one whose cutoff rises and falls.
This article is a work in progress. The examples will be refined through listening. Run starts playback; Stop ends it. Use Apply after editing values. Stop the playing iframe before trying another one.
Listen with the built-in FX
| Setting | Meaning |
|---|---|
| cutoff / depth | Cutoff and modulation depth |
| rate | One LFO cycle in beats, not Hz |
| resonance | Resonance |
| mix | Wet signal proportion |
Select none in FX Monitor to see the waveform after the built-in FX. This pass-through effect makes input and output overlap; it does not compare the signal before and after the built-in FX.
How the PCM is processed
Use a slowly moving sine wave as an LFO and derive the cutoff from its value. This moves a filter setting rather than replacing the audio waveform with a low-frequency signal. Both channels share the LFO phase, but keep separate filter history.
input[ch][i] is one input sample. ch identifies a left or right audio channel, not a physical FM voice. Store values carried between blocks in state. Since process cannot access outer variables, put settings in context.
Try it with liveFx
The 48000 in context.sampleRate is a placeholder. Match it to the actual output rate shown in FX Monitor. It is used to calculate times and frequencies; it does not change the browser's output sample rate.
Open in a separate Playground tab ↗
Select wobble-lab in FX Monitor to compare the input and output of this process.
- Try lfoHz at 0.25, 1, and 4 to hear different modulation speeds.
- Set lowHz and highHz equal for a stationary filter.
- Check whether high-frequency strength changes in Spectrum.
Scope of this example
The learning example is a first-order low-pass filter moving logarithmically between lowHz and highHz. It does not reproduce the built-in cutoff/depth or resonance behavior. At BPM 120, a built-in rate of two beats is one second; lfoHz 1 is one cycle per second.
The waveform shows changes over time; Spectrum shows the strength of frequency components. A short display window or smoothing can hide some changes. Listen while changing one setting at a time.