Allow Lua [session] script to directly set controllables

This commit is contained in:
Robin Gareus 2024-04-21 16:31:10 +02:00
parent 894e6d27a4
commit bcbb4393fc
Signed by: rgareus
GPG Key ID: A090BCE02CF57F04
1 changed files with 9 additions and 0 deletions

View File

@ -5688,6 +5688,15 @@ Session::setup_lua ()
LuaBindings::stddef (L);
LuaBindings::common (L);
LuaBindings::dsp (L);
luabridge::getGlobalNamespace (L)
.beginNamespace ("Ardour")
.beginClass <Session> ("Session")
/* thse are private to Session */
.addFunction ("rt_set_controls", &Session::rt_set_controls)
.addFunction ("rt_clear_all_solo_state", &Session::rt_clear_all_solo_state)
.endClass ()
.endNamespace ();
lua_mlock (L, 0);
luabridge::push <Session *> (L, this);
lua_setglobal (L, "Session");