Allow penv values to be falsy

This commit is contained in:
Aria
2025-09-09 20:43:05 -05:00
parent cc27d482cd
commit 38ce593c60
+1 -1
View File
@@ -174,7 +174,7 @@ let curves = ['linear', 'exponential'];
export function getPitchEnvelope(param, value, t, holdEnd) {
// envelope is active when any of these values is set
const hasEnvelope = value.pattack ?? value.pdecay ?? value.psustain ?? value.prelease ?? value.penv;
if (!hasEnvelope) {
if (hasEnvelope === undefined) {
return;
}
const penv = nanFallback(value.penv, 1, true);