# envelopes.lib

This library contains a collection of envelope generators. Its official prefix is `en`.

#### References

- https://github.com/grame-cncm/faustlibraries/blob/master/envelopes.lib

## Functions Reference

### `(en.)ar`

AR (Attack, Release) envelope generator (useful to create percussion envelopes). `ar` is a standard Faust function.

#### Usage

    ar(at,rt,t) : _

Where:

- `at`: attack (sec)
- `rt`: release (sec)
- `t`: trigger signal (attack is triggered when `t>0`, release is triggered when `t=0`)

### `(en.)asr`

ASR (Attack, Sustain, Release) envelope generator. `asr` is a standard Faust function.

#### Usage

    asr(at,sl,rt,t) : _

Where:

- `at`: attack (sec)
- `sl`: sustain level (between 0..1)
- `rt`: release (sec)
- `t`: trigger signal (attack is triggered when `t>0`, release is triggered when `t=0`)

### `(en.)adsr`

ADSR (Attack, Decay, Sustain, Release) envelope generator. `adsr` is a standard Faust function.

#### Usage

    adsr(at,dt,sl,rt,t) : _

Where:

- `at`: attack time (sec)
- `dt`: decay time (sec)
- `sl`: sustain level (between 0..1)
- `rt`: release time (sec)
- `t`: trigger signal (attack is triggered when `t>0`, release is triggered when `t=0`)

### `(en.)smoothEnvelope`

An envelope with an exponential attack and release. `smoothEnvelope` is a standard Faust function.

#### Usage

    smoothEnvelope(ar,t) : _

- `ar`: attack and release duration (s)
- `t`: trigger signal (attack is triggered when `t>0`, release is triggered when `t=0`)

### `(en.)arfe`

ARFE (Attack and Release-to-Final-value Exponentially) envelope generator. Approximately equal to `smoothEnvelope(Attack/6.91)` when Attack == Release.

#### Usage

    arfe(at,rt,fl,t) : _

Where:

- `at`: attack (sec)
- `rt`: release (sec)
- `fl`: final level to approach upon release (such as 0)
- `t`: trigger signal (attack is triggered when `t>0`, release is triggered when `t=0`)

### `(en.)are`

ARE (Attack, Release) envelope generator with Exponential segments. Approximately equal to `smoothEnvelope(Attack/6.91)` when Attack == Release.

#### Usage

    are(at,rt,t) : _

Where:

- `at`: attack (sec)
- `rt`: release (sec)
- `t`: trigger signal (attack is triggered when `t>0`, release is triggered when `t=0`)

### `(en.)asre`

ASRE (Attack, Sustain, Release) envelope generator with Exponential segments.

#### Usage

    asre(at,sl,rt,t) : _

Where:

- `at`: attack (sec)
- `sl`: sustain level (between 0..1)
- `rt`: release (sec)
- `t`: trigger signal (attack is triggered when `t>0`, release is triggered when `t=0`)

### `(en.)adsre`

ADSRE (Attack, Decay, Sustain, Release) envelope generator with Exponential segments.

#### Usage

    adsre(at,dt,sl,rt,t) : _

Where:

- `at`: attack (sec)
- `dt`: decay (sec)
- `sl`: sustain level (between 0..1)
- `rt`: release (sec)
- `t`: trigger signal (attack is triggered when `t>0`, release is triggered when `t=0`)

### `(en.)dx7envelope`

DX7 operator envelope generator with 4 independent rates and levels. It is essentially a 4 points BPF.

#### Usage

    dx7_envelope(R1,R2,R3,R4,L1,L2,L3,L4,t) : _

Where:

- `RN`: rates in seconds
- `LN`: levels (0-1)
- `t`: trigger signal

#### Search

From here you can search these documents. Enter your search terms below.

#### Keyboard Shortcuts

Keys | Action
--- | ---
`?` | Open this help
`n` | Next page
`p` | Previous page
`s` | Search