13
0

Fix Mixer Recall script

Add new Mixbus internal processors to well_known list, and ensure that
proc is not nil before invalidation
This commit is contained in:
Nikolaus Gullotta 2020-04-16 10:59:16 -05:00
parent 87626e0bdd
commit 4fffb39258
No known key found for this signature in database
GPG Key ID: C1580877951565A3

View File

@ -204,7 +204,16 @@ function factory ()
local rt_group = group_by_name(group_name) local rt_group = group_by_name(group_name)
if rt_group then rt_group:add(rt) end if rt_group then rt_group:add(rt) end
well_known = {'PRE', 'Trim', 'EQ', 'Comp', 'Fader', 'POST'} well_known = {
'PRE',
'Trim',
'EQ',
'Comp',
'Fader',
'POST',
"Input Stage",
"Mixbus Limiter"
}
protected_instrument = false protected_instrument = false
for k, v in pairs(order) do for k, v in pairs(order) do
local proc = Session:processor_by_id(PBD.ID(1)) local proc = Session:processor_by_id(PBD.ID(1))
@ -220,8 +229,10 @@ function factory ()
for _, control in pairs(well_known) do for _, control in pairs(well_known) do
if name == control then if name == control then
proc = get_processor_by_name(rt, control) proc = get_processor_by_name(rt, control)
invalidate[v] = proc:to_stateful():id():to_s() if proc and not(proc:isnil()) then
goto nextproc invalidate[v] = proc:to_stateful():id():to_s()
goto nextproc
end
end end
end end
if not(proc) then goto nextproc end if not(proc) then goto nextproc end