Data Lab node
Envelope
The envelope of every channel: a peak follower with attack and release (ms), a running RMS over RMS Window (ms), or a peak hold that keeps the maximum for Hold ms and then releases. Same unit out. Peak is the window’s largest |value|, Crest Factor peak / RMS (1.41 for a sine, higher for spiky data).
Inputs
| Port | Type | Default |
|---|---|---|
| SignalThe Data Lab signal to analyse — a Signal node's output, a Window, or any float array with its sample rate. Multi-channel signals are handled per channel. | structure | — |
| ModePeak follower (attack/release), running RMS over RMS Window, or Peak hold (holds the maximum for Hold ms, then releases). | int | 0 |
| AttackHow fast the follower rises, ms (0 = instantly). | float | 10 |
| ReleaseHow fast the follower falls, ms. | float | 200 |
| RMS WindowLength of the RMS average, ms. | float | 50 |
| HoldHow long a peak is held before it releases, ms. | float | 500 |
| Update RateHow many times per second the analysis is recomputed (default 10); 0 = every frame. Lower rates save CPU on long windows — a moved parameter always recomputes at once. | float | 0 |
Outputs
| Port | Type |
|---|---|
| SignalThe Data Lab signal to analyse — a Signal node's output, a Window, or any float array with its sample rate. Multi-channel signals are handled per channel. | structure |
| Latest | float |
| Peak | float |
| Crest Factor | float |
How It Works
Envelope follows the shape of every channel rather than its instantaneous value, in three modes:
- Peak follower — rises with Attack and falls with Release, both in milliseconds. The classic audio envelope.
- RMS — a running root-mean-square over RMS Window milliseconds, which reads as loudness rather than as peaks.
- Peak hold — keeps the maximum for Hold milliseconds and then releases it.
The unit comes through unchanged. Two extra readings come out alongside the envelope Signal: Peak is the window's largest absolute value, and Crest Factor is peak divided by RMS — 1.41 for a sine, higher for spiky data, which makes it a good "how transient is this" measure.
Use Cases
- Loudness as a control — An audio window's RMS envelope drives particle energy, a light level or a scale.
- Beat and onset material — A fast-attack, slow-release peak follower into Events with a threshold.
- Gate a visual — Envelope into Compare into a Switch: something happens only while the signal is loud.
- Meters — Peak hold is exactly how a physical peak meter behaves.
- Characterise a source — Crest Factor distinguishes a drum from a pad at the same RMS.
Tips
- Fast attack, slow release is the setting that reads as musical. Equal attack and release just smooths.
- RMS mode with a 50 ms window is a good general-purpose loudness signal.
- Envelope before Events, not after — thresholding a raw waveform chatters.
- The envelope keeps the input's unit, so Plot's axis stays meaningful.
- For frequency-resolved energy, use Spectrum's Band Levels instead of one broadband envelope.
Open Envelope in the interactive catalog →
Envelope is one of 381 nodes in Grafit Pro.
Free download. Every feature for 7 days, no card. Then €99.99 once — or keep playing your projects as a Player.