position audio filters

This commit is contained in:
Sam Lavigne 2023-09-25 19:30:11 -04:00
parent 6a86e82809
commit 28ab153f92
1 changed files with 11 additions and 6 deletions

View File

@ -298,7 +298,12 @@ function autoLayout(_nodes) {
for (let n of _nodes) {
if (n.nodeType === "filter") {
let _w = prev && prev.width ? prev.width : w;
n.position = { x: prev ? prev.position.x + _w + margin : 0, y: -50 };
let _x = prev ? prev.position.x + _w + margin : 0;
let _y = -50;
if (n.data.inputs && n.data.inputs[0] && n.data.inputs[0] === "a") {
_y = 50;
}
n.position = { x: _x, y: _y };
prev = n;
}
}