From eefa90a2bc7416ba38bfbd9b803f36dfd0ccaaeb Mon Sep 17 00:00:00 2001 From: Felix Roos Date: Sat, 13 Jan 2024 22:24:59 +0100 Subject: [PATCH] fix: synth default envelope --- packages/superdough/synth.mjs | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/packages/superdough/synth.mjs b/packages/superdough/synth.mjs index c4586e92..6a3e381a 100644 --- a/packages/superdough/synth.mjs +++ b/packages/superdough/synth.mjs @@ -29,12 +29,11 @@ export function registerSynthSounds() { registerSound( s, (t, value, onended) => { - const [attack, decay, sustain, release] = getADSRValues([ - value.attack, - value.decay, - value.sustain, - value.release, - ]); + const [attack, decay, sustain, release] = getADSRValues( + [value.attack, value.decay, value.sustain, value.release], + 'linear', + [0.001, 0.05, 0.6, 0.01], + ); let sound; if (waveforms.includes(s)) {