mirror of
https://codeberg.org/uzu/strudel
synced 2026-07-13 06:19:33 -04:00
Fixes for zzfx and soundfonts
This commit is contained in:
@@ -19,7 +19,11 @@ const getNodeParam = (node, name) => {
|
||||
}
|
||||
}
|
||||
// Built-in node case
|
||||
const p = node?.[name];
|
||||
let p = node?.[name];
|
||||
if (p === undefined && name === 'frequency') {
|
||||
// Fallbacks for source nodes without 'frequency' params (e.g. soundfonts)
|
||||
p = node?.['detune'] ?? node?.['playbackRate'];
|
||||
}
|
||||
if (p instanceof AudioParam) {
|
||||
return p;
|
||||
}
|
||||
|
||||
@@ -75,7 +75,6 @@ export const getZZFX = (value, t) => {
|
||||
source.start(t);
|
||||
return {
|
||||
node: source,
|
||||
nodes: { source: [source] },
|
||||
};
|
||||
};
|
||||
|
||||
@@ -91,6 +90,7 @@ export function registerZZFXSounds() {
|
||||
});
|
||||
return {
|
||||
node: o,
|
||||
nodes: { source: [o] },
|
||||
stop: () => {},
|
||||
};
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user