mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-10 00:34:59 +01:00
Lua Script Example to toggle monitor section
This commit is contained in:
parent
08e564dc2e
commit
aacb2d7be7
1 changed files with 12 additions and 0 deletions
12
scripts/_toggle_monitor_section.lua
Normal file
12
scripts/_toggle_monitor_section.lua
Normal file
|
|
@ -0,0 +1,12 @@
|
||||||
|
ardour { ["type"] = "Snippet", name = "Toggle Monitor Section" }
|
||||||
|
|
||||||
|
function factory () return function ()
|
||||||
|
if Session:monitor_out():isnil() then
|
||||||
|
Session:add_monitor_section ()
|
||||||
|
ARDOUR.config():set_use_monitor_bus (true)
|
||||||
|
else
|
||||||
|
Session:remove_monitor_section ()
|
||||||
|
ARDOUR.config():set_use_monitor_bus (false)
|
||||||
|
collectgarbage ()
|
||||||
|
end
|
||||||
|
end end
|
||||||
Loading…
Add table
Add a link
Reference in a new issue