audio

@audio/effect-tremolo1.2.0

Tremolo

Tremolo — amplitude modulation via LFO

Status
calibrated
Updated
Family
effect, 26 packages under it
Plugin
tremolo, effect, streaming, 3 parameters
Category
effects
Licence
MIT
Dependencies
none
Downloads
2,268 last month
Tests
138 in audiojs/effect's CI, passed at 5ff5a84,

Listen

// "Local Forecast" by Kevin MacLeod (incompetech.com), CC BY 4.0, incompetech.com/music/royalty-free/faq.html
audio('/samples/music/modern/local-forecast.mp3').tremolo()

// "Local Forecast" by Kevin MacLeod (incompetech.com), CC BY 4.0, incompetech.com/music/royalty-free/faq.html

Parameters

  • effect
  • streaming
rate
5 Hz
0.1 to 20 Hz
depth
0.5
0 to 1
phase
0 deg
−180 to 180 deg
import tremolo from '@audio/effect-tremolo'

Amplitude modulation via LFO — periodic volume pulsing.

rate LFO rate in Hz (default 5) · depth modulation depth 0–1 (default 0.5) · phase LFO phase of each channel ahead of the one before, degrees −180–180 (default 0, the channels together; 180 is an auto-pan) · channel index of the channel this call processes (default 0) · fs sample rate

In stereo, each channel keeps its own params object with its channel index (the /audio factory does this). At 180, the left gain rises as the right falls and the two add to 2 − depth: an auto-pan. Channel 0 never shifts, so a mono signal is the same at any phase. Channel c runs c × phase ahead, so at 90 channel 4 is a whole cycle on and moves with channel 0. A change of phase glides across the next call.

import tremolo from '@audio/effect-tremolo'

let p = { rate: 5, depth: 0.7, fs: 44100 }
for (let buf of stream) tremolo(buf, p)

Use when: vintage amp tremolo, rhythmic pulsing, guitar effects
Not for: pitch modulation (use vibrato)


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

MIT © audiojs