Explore Synth Building Blocks: Envelopes

Articles

Learning Synths

A chat with Jay Curtis / Lysdexic

Packages

RNBO Guitar Pedals

Synth Building Blocks

Synth Building Blocks: Intro

Synth Building Blocks: Generators

Synth Building Blocks: Buffers

Synth Building Blocks: Filters

Synth Building Blocks: Envelopes

Synth Building Blocks: Control Signals

Examples

Audio Effects
Event Sequencing
Random and Generative
Synthesis and Synthesizers
Sampling and Sample Playback
Utilities

Synth Building Blocks: Envelopes

The envelopes that come with the Synth Building Blocks package include both an AD and ADSR envelope, an envelope followers, and a lowpass gate circuit emulation. Other envelope adjacent abstractions exist, such as a MIDI sustain abstraction and an abstraction for stereo panning.

ADSR Envelopes

The SBB package's sbb.env.adsr abstraction resembles the most common envlope found in most synth systems. It generates a standard 4-stage attack-decay-sustain-release envelope. Similar to Max MSP and RNBO's adsr~ object, the values for the attack, decay, and release stages are given in milliseconds while the sustain value is given as an amplitude value from 0 - 1. The actual sustain length is triggered with the right inlet using gate values—1 to trigger the attack, decay, and sustain stages, and 0 to end the sustain stage with the release.

Screen Shot 2022-09-16 at 3.56.00 PM.png

This can be adventageous for chaining the envelopes of certain sounds with other events in your patch. However, in cases where it'd be better to trigger the envelope with one shot, the sbb.env.ad object can be used. In sbb.env.ad, the decay and release stages are omitted so that sound events can be triggered with a single event.

For an even simpler oneshot envelope, the sbb.env.lpg abstraction can be used. This emulates a lowpass gate, which will trigger a short envelope by sending a bang into the right inlet.

Envelope Follower

Using a preexisting signal as an envelope can also be done with Synth Building Blocks by using the package's envelope follower: sbb.env.follower. This abstraction takes an input signal and turns it into an envelope by scaling and sampling accordingly.

Screen Shot 2022-09-16 at 4.08.05 PM.png

In the example above, an audio file is acting as our envelope by being passed through sbb.env.follower and attenuating the signal coming from sbb.osc.analog.

Sustain and Crossfade

Two additional abstractions are available in SBB that fit into the general category of envelope processing. One is sbb.util.xfade which is a simple stereo panner that takes two stereo input and pans then to a single stereo output. The other, sbb.util.sustain, emulates a MIDI sustain pedal by filtering out note-off messages from the input.