audio

@audio/dynamics-envelope0.1.4

Branching one-pole envelope follower. Returns a stateful per-sample detector

Status
pending calibration
Updated
Family
dynamics, 17 packages under it
Category
effects
Licence
MIT
Dependencies
none
Downloads
3,819 last month
Tests
92 in audiojs/dynamics's CI, passed at 2ee3ad9,
import { envelope } from '@audio/dynamics-envelope'

The common detector for the envelope-driven processors is a branching one-pole follower with separate attack/release time constants, peak or RMS detection.

import { envelope } from '@audio/dynamics-envelope'

let follow = envelope({ attack: 5, release: 100, detector: 'peak' })
let level = []
for (let x of samples) level.push(follow(x))
Param Default
sampleRate 44100 —
attack 5 ms
release 50 ms
detector 'peak' 'peak' or 'rms'
rmsWindow 256 samples, for RMS detector

Part of @audio/dynamics — the dynamics family umbrella. This README is generated from the umbrella docs.

MIT © audiojs