mirror of
https://github.com/vsariola/sointu.git
synced 2025-06-04 01:28:45 -04:00
fix(sointu): NumDelayLines did not take polyphony into account, resulting in panic
This commit is contained in:
parent
6d2b63a5e9
commit
0f942f73d9
2
patch.go
2
patch.go
@ -30,7 +30,7 @@ func (p Patch) NumDelayLines() int {
|
|||||||
for _, instr := range p {
|
for _, instr := range p {
|
||||||
for _, unit := range instr.Units {
|
for _, unit := range instr.Units {
|
||||||
if unit.Type == "delay" {
|
if unit.Type == "delay" {
|
||||||
total += len(unit.VarArgs)
|
total += len(unit.VarArgs) * instr.NumVoices
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user