Envelope follower
Track the level of an audio bundle as one control lane per channel, with attack and release.
- Control
- Since 0.2.0
- envelope
- follower
- level
- audio to control
Envelope follower tracks the level of an audio bundle and outputs it as one control lane per channel.
What it does#
Audio comes in and a slowly moving level comes out. Detector chooses RMS (a smoothed average of the signal's energy) or Peak (the largest swing). Attack sets how fast the level rises and Release how fast it falls, in milliseconds. Gain boosts the audio before it is measured so quiet sources can reach 1; the audio itself passes on unchanged elsewhere because the follower only produces a control output. Stereo audio gives a two-lane output.
When to use it#
Use it to make something react to loudness: scale the follower's output and cable it to a control. For per-frequency reaction use Band energies.
Ports#
| Port | Direction | Signal | Lanes |
|---|---|---|---|
audio | Input | Audio | Inferred from the cable |
control | Output | Control | Inferred from the cable |
Parameters#
| Parameter | Label | Range | Default | Unit | Scale | Notes |
|---|---|---|---|---|---|---|
attack_ms | Attack | 0 to 2000 | 10 | ms | linear | How fast the follower rises. |
release_ms | Release | 0 to 5000 | 200 | ms | linear | How fast the follower falls. |
mode | Detector | 0 to 1 | 0 | linear | Measure RMS or peak level. Choices: 0 RMS, 1 Peak. | |
gain_db | Gain | -24 to 48 | 0 | dB | linear | Boost applied before the follower so quiet sources reach 1. |
Attack (attack_ms)#
How fast the follower rises, 0 to 2000 ms.
Release (release_ms)#
How fast the follower falls, 0 to 5000 ms.
Detector (mode)#
RMS or Peak. RMS follows perceived level; Peak reacts to short transients. A discrete choice.
Gain (gain_db)#
Boost, from -24 to 48 dB, applied before the follower so quiet sources reach 1.
Tips#
- Use a fast Attack and a slower Release for a natural-looking level.
- If the output barely moves, raise Gain.
See also#
Band energies, Smooth, Scale, Cables.
Help patches
Each help patch is an ordinary Toy that teaches one idea. The diagram shows the Patch; the preview shows its Frame. Open it in TuneToys to play and edit it.
1. Follow the level of a tone
beginner Teaches: attack_ms, release_ms, mode, gain_db
An envelope follower measures a tone and exposes its timing and gain.
Connections as text
- Oscillator audio output connected to Patch outputs audio input
- Oscillator audio output connected to Envelope follower audio input
- The tone goes to the output and to the follower; the follower makes a control lane from its level.
- Gain lifts quiet sources so they reach 1. Attack and Release set how fast the lane moves.
Related nodes
- Band energies Split audio into log-spaced bands and follow each one's energy as a control lane: the audio-to-visual bridge.
- Smooth Slow a control lane down with separate rise and fall times so jumpy sensors and buttons stop clicking.
- Scale Map a control range onto another with a curve, clamp and inversion. Depth and offset for any modulation.