diff --git a/libs/ardour/luabindings.cc b/libs/ardour/luabindings.cc index dcb83ebe44..09ff8f83ca 100644 --- a/libs/ardour/luabindings.cc +++ b/libs/ardour/luabindings.cc @@ -78,6 +78,7 @@ #include "ardour/send.h" #include "ardour/session.h" #include "ardour/session_object.h" +#include "ardour/session_playlists.h" #include "ardour/sidechain.h" #include "ardour/solo_isolate_control.h" #include "ardour/solo_safe_control.h" @@ -261,6 +262,7 @@ CLASSKEYS(boost::shared_ptr); CLASSKEYS(boost::shared_ptr); CLASSKEYS(boost::shared_ptr); CLASSKEYS(boost::shared_ptr); +CLASSKEYS(boost::shared_ptr); CLASSKEYS(boost::shared_ptr); CLASSKEYS(boost::shared_ptr >); CLASSKEYS(boost::shared_ptr >); @@ -1127,6 +1129,7 @@ LuaBindings::common (lua_State* L) .addFunction ("combine", &Playlist::combine) .addFunction ("uncombine", &Playlist::uncombine) .addFunction ("split_region", &Playlist::split_region) + .addFunction ("get_orig_track_id", &Playlist::get_orig_track_id) //.addFunction ("split", &Playlist::split) // XXX needs MusicSample .addFunction ("cut", (boost::shared_ptr (Playlist::*)(std::list&, bool))&Playlist::cut) #if 0 @@ -1143,6 +1146,17 @@ LuaBindings::common (lua_State* L) .addFunction ("set_note_mode", &MidiPlaylist::set_note_mode) .endClass () + .beginWSPtrClass ("SessionPlaylists") + .addFunction ("by_name", &SessionPlaylists::by_name) + .addFunction ("by_id", &SessionPlaylists::by_id) + .addFunction ("source_use_count", &SessionPlaylists::source_use_count) + .addFunction ("region_use_count", &SessionPlaylists::region_use_count) + .addFunction ("playlists_for_track", &SessionPlaylists::playlists_for_track) + .addFunction ("get_used", &SessionPlaylists::get_used) + .addFunction ("get_unused", &SessionPlaylists::get_unused) + .addFunction ("n_playlists", &SessionPlaylists::n_playlists) + .endClass () + .deriveWSPtrClass ("Track") .addCast ("to_audio_track") .addCast ("to_midi_track") @@ -1636,6 +1650,10 @@ LuaBindings::common (lua_State* L) .beginStdVector > ("SourceList") .endClass () + // from SessionPlaylists + .beginStdVector > ("PlaylistList") + .endClass () + // std::list< boost::weak_ptr > .beginConstStdList > ("WeakAudioSourceList") .endClass () @@ -2279,6 +2297,7 @@ LuaBindings::common (lua_State* L) .addFunction ("abort_reversible_command", &Session::abort_reversible_command) .addFunction ("add_command", &Session::add_command) .addFunction ("add_stateful_diff_command", &Session::add_stateful_diff_command) + .addFunction ("playlists", &Session::playlists) .addFunction ("engine", (AudioEngine& (Session::*)())&Session::engine) .addFunction ("get_block_size", &Session::get_block_size) .addFunction ("worst_output_latency", &Session::worst_output_latency)