fixed filter envelope popping...

This commit is contained in:
Jade (Rose) Rowland 2023-12-20 13:09:04 -05:00
parent fb81f6f268
commit dec039ead3
2 changed files with 18 additions and 39 deletions

View file

@ -29,13 +29,12 @@ export function registerSynthSounds() {
registerSound(
s,
(t, value, onended) => {
const defaultADSRValues = [0.001, 0.1, 0.6, 0.01];
const [attack, decay, sustain, release] = getADSRValues(
[value.attack, value.decay, value.sustain, value.release],
defaultADSRValues,
0,
0.6,
);
const [attack, decay, sustain, release] = getADSRValues([
value.attack,
value.decay,
value.sustain,
value.release,
]);
let sound;
if (waveforms.includes(s)) {