X-Git-Url: https://git.carlh.net/gitweb/?a=blobdiff_plain;f=libs%2Fardour%2Fluabindings.cc;h=a5878a2efd9dfbe149bedc09436cd13815e5f17b;hb=9775c5c9f1b81340f3177ede038f02faed71c887;hp=04275991b718cdbef020d69f68e985738c4edda0;hpb=38a029c0698eb23fb7ed9323ccad021c0330d2dd;p=ardour.git diff --git a/libs/ardour/luabindings.cc b/libs/ardour/luabindings.cc index 04275991b7..a5878a2efd 100644 --- a/libs/ardour/luabindings.cc +++ b/libs/ardour/luabindings.cc @@ -18,9 +18,11 @@ #include -#include "timecode/bbt_time.h" #include "pbd/stateful_diff_command.h" #include "pbd/openuri.h" + +#include "temporal/bbt_time.h" + #include "evoral/Control.hpp" #include "evoral/ControlList.hpp" #include "evoral/Range.hpp" @@ -35,9 +37,11 @@ #include "ardour/audio_track.h" #include "ardour/audioplaylist.h" #include "ardour/buffer_set.h" -#include "ardour/beats_frames_converter.h" +#include "ardour/beats_samples_converter.h" #include "ardour/chan_mapping.h" #include "ardour/dB.h" +#include "ardour/disk_reader.h" +#include "ardour/disk_writer.h" #include "ardour/dsp_filter.h" #include "ardour/file_source.h" #include "ardour/fluid_synth.h" @@ -62,7 +66,9 @@ #include "ardour/runtime_functions.h" #include "ardour/region.h" #include "ardour/region_factory.h" +#include "ardour/return.h" #include "ardour/route_group.h" +#include "ardour/send.h" #include "ardour/session.h" #include "ardour/session_object.h" #include "ardour/sidechain.h" @@ -170,8 +176,8 @@ CLASSKEYS(Selectable*); CLASSKEYS(std::list); CLASSKEYS(ARDOUR::AudioEngine); -CLASSKEYS(ARDOUR::BeatsFramesConverter); -CLASSKEYS(ARDOUR::DoubleBeatsFramesConverter); +CLASSKEYS(ARDOUR::BeatsSamplesConverter); +CLASSKEYS(ARDOUR::DoubleBeatsSamplesConverter); CLASSKEYS(ARDOUR::BufferSet); CLASSKEYS(ARDOUR::ChanCount); CLASSKEYS(ARDOUR::ChanMapping); @@ -196,6 +202,7 @@ CLASSKEYS(ARDOUR::PresentationInfo); CLASSKEYS(ARDOUR::RCConfiguration); CLASSKEYS(ARDOUR::Session); CLASSKEYS(ARDOUR::SessionConfiguration); +CLASSKEYS(ARDOUR::Slavable); CLASSKEYS(ARDOUR::Source); CLASSKEYS(ARDOUR::VCA); CLASSKEYS(ARDOUR::VCAManager); @@ -205,8 +212,8 @@ CLASSKEYS(PBD::Configuration); CLASSKEYS(PBD::PropertyChange); CLASSKEYS(PBD::StatefulDestructible); -CLASSKEYS(Evoral::Beats); -CLASSKEYS(Evoral::Event); +CLASSKEYS(Temporal::Beats); +CLASSKEYS(Evoral::Event); CLASSKEYS(Evoral::ControlEvent); @@ -234,7 +241,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); CLASSKEYS(boost::shared_ptr); @@ -246,8 +253,8 @@ 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 >); CLASSKEYS(boost::shared_ptr); CLASSKEYS(boost::shared_ptr); @@ -346,7 +353,7 @@ LuaBindings::stddef (lua_State* L) .beginStdVector ("FloatArrayVector") .endClass () - // framepos_t, frameoffset_t lists e.g. AnalysisFeatureList + // samplepos_t, sampleoffset_t lists e.g. AnalysisFeatureList .beginStdList ("Int64List") .endClass () @@ -507,17 +514,17 @@ LuaBindings::common (lua_State* L) luabridge::getGlobalNamespace (L) .beginNamespace ("Evoral") - .beginClass > ("Event") - .addFunction ("clear", &Evoral::Event::clear) - .addFunction ("size", &Evoral::Event::size) - .addFunction ("set_buffer", &Evoral::Event::set_buffer) - .addFunction ("buffer", (uint8_t*(Evoral::Event::*)())&Evoral::Event::buffer) - .addFunction ("time", (framepos_t (Evoral::Event::*)())&Evoral::Event::time) + .beginClass > ("Event") + .addFunction ("clear", &Evoral::Event::clear) + .addFunction ("size", &Evoral::Event::size) + .addFunction ("set_buffer", &Evoral::Event::set_buffer) + .addFunction ("buffer", (uint8_t*(Evoral::Event::*)())&Evoral::Event::buffer) + .addFunction ("time", (samplepos_t (Evoral::Event::*)())&Evoral::Event::time) .endClass () - .beginClass ("Beats") + .beginClass ("Beats") .addConstructor () - .addFunction ("to_double", &Evoral::Beats::to_double) + .addFunction ("to_double", &Temporal::Beats::to_double) .endClass () .beginClass ("Parameter") @@ -563,22 +570,22 @@ LuaBindings::common (lua_State* L) .addData ("logarithmic", &Evoral::ParameterDescriptor::logarithmic) .endClass () - .beginClass > ("Range") - .addConstructor () - .addData ("from", &Evoral::Range::from) - .addData ("to", &Evoral::Range::to) + .beginClass > ("Range") + .addConstructor () + .addData ("from", &Evoral::Range::from) + .addData ("to", &Evoral::Range::to) .endClass () - .deriveWSPtrClass , Evoral::ControlSet> ("Sequence") + .deriveWSPtrClass , Evoral::ControlSet> ("Sequence") .endClass () - .beginWSPtrClass > ("NotePtr") - .addFunction ("time", &Evoral::Note::time) - .addFunction ("note", &Evoral::Note::note) - .addFunction ("velocity", &Evoral::Note::velocity) - .addFunction ("off_velocity", &Evoral::Note::off_velocity) - .addFunction ("length", &Evoral::Note::length) - .addFunction ("channel", &Evoral::Note::channel) + .beginWSPtrClass > ("NotePtr") + .addFunction ("time", &Evoral::Note::time) + .addFunction ("note", &Evoral::Note::note) + .addFunction ("velocity", &Evoral::Note::velocity) + .addFunction ("off_velocity", &Evoral::Note::off_velocity) + .addFunction ("length", &Evoral::Note::length) + .addFunction ("channel", &Evoral::Note::channel) .endClass () /* libevoral enums */ @@ -721,15 +728,15 @@ LuaBindings::common (lua_State* L) .beginClass ("Progress") .endClass () - .beginClass ("MusicFrame") - .addConstructor () - .addFunction ("set", &MusicFrame::set) - .addData ("frame", &MusicFrame::frame) - .addData ("division", &MusicFrame::division) + .beginClass ("MusicSample") + .addConstructor () + .addFunction ("set", &MusicSample::set) + .addData ("frame", &MusicSample::sample) + .addData ("division", &MusicSample::division) .endClass () .beginClass ("AudioRange") - .addConstructor () + .addConstructor () .addFunction ("length", &AudioRange::length) .addFunction ("equal", &AudioRange::equal) .addData ("start", &AudioRange::start) @@ -771,7 +778,7 @@ LuaBindings::common (lua_State* L) // templated class definitions .beginClass > ("BoolProperty").endClass () .beginClass > ("FloatProperty").endClass () - .beginClass > ("FrameposProperty").endClass () + .beginClass > ("FrameposProperty").endClass () // actual references (TODO: also expose GQuark for std::set) // ardour/region.h .addConst ("Start", &ARDOUR::Properties::start) @@ -786,7 +793,7 @@ LuaBindings::common (lua_State* L) // expand templated PropertyDescriptor .addFunction ("containsBool", &PBD::PropertyChange::contains) .addFunction ("containsFloat", &PBD::PropertyChange::contains) - .addFunction ("containsFramePos", &PBD::PropertyChange::contains) + .addFunction ("containsFramePos", &PBD::PropertyChange::contains) .endClass () .beginClass ("PropertyList") @@ -869,6 +876,10 @@ LuaBindings::common (lua_State* L) .addFunction ("connected_to", (bool (Port::*)(std::string const &)const)&Port::connected_to) .addFunction ("connect", (int (Port::*)(std::string const &))&Port::connect) .addFunction ("disconnect", (int (Port::*)(std::string const &))&Port::disconnect) + .addFunction ("physically_connected", &Port::physically_connected) + .addFunction ("private_latency_range", &Port::private_latency_range) + .addFunction ("public_latency_range", &Port::public_latency_range) + .addRefFunction ("get_connected_latency_range", &Port::get_connected_latency_range) //.addStaticFunction ("port_offset", &Port::port_offset) // static .endClass () @@ -905,6 +916,8 @@ LuaBindings::common (lua_State* L) .addFunction ("midi", &IO::midi) .addFunction ("port_by_name", &IO::nth) .addFunction ("n_ports", &IO::n_ports) + .addFunction ("latency", &IO::latency) + .addFunction ("public_latency", &IO::latency) .endClass () .deriveWSPtrClass ("PannerShell") @@ -958,10 +971,16 @@ LuaBindings::common (lua_State* L) .addConst ("max_order", ARDOUR::PresentationInfo::max_order) .endClass () + .beginWSPtrClass ("Slavable") + .addFunction ("assign", &Slavable::assign) + .addFunction ("unassign", &Slavable::unassign) + .endClass () + .deriveWSPtrClass ("Stripable") .addCast ("to_route") .addCast ("to_vca") .addFunction ("is_auditioner", &Stripable::is_auditioner) + .addFunction ("is_private_route", &Stripable::is_private_route) .addFunction ("is_master", &Stripable::is_master) .addFunction ("is_monitor", &Stripable::is_monitor) .addFunction ("is_hidden", &Stripable::is_hidden) @@ -1019,6 +1038,7 @@ LuaBindings::common (lua_State* L) .deriveWSPtrClass ("Route") .addCast ("to_track") .addCast ("to_automatable") + .addCast ("to_slavable") .addFunction ("set_name", &Route::set_name) .addFunction ("comment", &Route::comment) .addFunction ("active", &Route::active) @@ -1051,6 +1071,8 @@ LuaBindings::common (lua_State* L) .addFunction ("trim", &Route::trim) .addFunction ("peak_meter", (boost::shared_ptr (Route::*)())&Route::peak_meter) .addFunction ("set_meter_point", &Route::set_meter_point) + .addFunction ("signal_latency", &Route::signal_latency) + .addFunction ("playback_latency", &Route::playback_latency) .endClass () .deriveWSPtrClass ("Playlist") @@ -1059,7 +1081,7 @@ LuaBindings::common (lua_State* L) .addFunction ("region_by_id", &Playlist::region_by_id) .addFunction ("data_type", &Playlist::data_type) .addFunction ("n_regions", &Playlist::n_regions) - //.addFunction ("get_extent", &Playlist::get_extent) // pair + //.addFunction ("get_extent", &Playlist::get_extent) // pair .addFunction ("region_list", &Playlist::region_list) .addFunction ("add_region", &Playlist::add_region) .addFunction ("remove_region", &Playlist::remove_region) @@ -1077,13 +1099,13 @@ LuaBindings::common (lua_State* L) .addFunction ("lower_region", &Playlist::lower_region) .addFunction ("raise_region_to_top", &Playlist::raise_region_to_top) .addFunction ("lower_region_to_bottom", &Playlist::lower_region_to_bottom) - .addFunction ("duplicate", (void (Playlist::*)(boost::shared_ptr, framepos_t, framecnt_t, float))&Playlist::duplicate) + .addFunction ("duplicate", (void (Playlist::*)(boost::shared_ptr, samplepos_t, samplecnt_t, float))&Playlist::duplicate) .addFunction ("duplicate_until", &Playlist::duplicate_until) .addFunction ("duplicate_range", &Playlist::duplicate_range) .addFunction ("combine", &Playlist::combine) .addFunction ("uncombine", &Playlist::uncombine) .addFunction ("split_region", &Playlist::split_region) - .addFunction ("split", (void (Playlist::*)(framepos_t))&Playlist::split) + .addFunction ("split", (void (Playlist::*)(samplepos_t))&Playlist::split) .addFunction ("cut", (boost::shared_ptr (Playlist::*)(std::list&, bool))&Playlist::cut) #if 0 .addFunction ("copy", &Playlist::copy) @@ -1203,6 +1225,7 @@ LuaBindings::common (lua_State* L) .addFunction ("scale_amplitude", &AudioRegion::scale_amplitude) .addFunction ("maximum_amplitude", &AudioRegion::maximum_amplitude) .addFunction ("rms", &AudioRegion::rms) + .addRefFunction ("separate_by_channel", &AudioRegion::separate_by_channel) .endClass () .deriveWSPtrClass ("Source") @@ -1250,15 +1273,16 @@ LuaBindings::common (lua_State* L) .endClass () .deriveWSPtrClass ("Automatable") + .addCast ("to_slavable") .addFunction ("automation_control", (boost::shared_ptr(Automatable::*)(const Evoral::Parameter&, bool))&Automatable::automation_control) //.addFunction ("what_can_be_automated", &Automatable::what_can_be_automated) .endClass () - .deriveWSPtrClass , Automatable> ("AutomatableSequence") - .addCast > ("to_sequence") + .deriveWSPtrClass , Automatable> ("AutomatableSequence") + .addCast > ("to_sequence") .endClass () - .deriveWSPtrClass > ("MidiModel") + .deriveWSPtrClass > ("MidiModel") .addFunction ("apply_command", (void (MidiModel::*)(Session*, Command*))&MidiModel::apply_command) .addFunction ("new_note_diff_command", &MidiModel::new_note_diff_command) .endClass () @@ -1300,8 +1324,12 @@ LuaBindings::common (lua_State* L) .addCast ("to_ioprocessor") .addCast ("to_unknownprocessor") .addCast ("to_amp") + .addCast ("to_diskioprocessor") + .addCast ("to_diskreader") + .addCast ("to_diskwriter") .addCast ("to_peakmeter") .addCast ("to_monitorprocessor") + .addCast ("to_send") #if 0 // those objects are not yet bound .addCast ("to_capturingprocessor") .addCast ("to_delayline") @@ -1312,8 +1340,22 @@ LuaBindings::common (lua_State* L) .addFunction ("active", &Processor::active) .addFunction ("activate", &Processor::activate) .addFunction ("deactivate", &Processor::deactivate) - .addFunction ("output_streams", &PluginInsert::output_streams) - .addFunction ("input_streams", &PluginInsert::input_streams) + .addFunction ("input_latency", &Processor::input_latency) + .addFunction ("output_latency", &Processor::output_latency) + .addFunction ("capture_offset", &Processor::capture_offset) + .addFunction ("playback_offset", &Processor::playback_offset) + .addFunction ("output_streams", &Processor::output_streams) + .addFunction ("input_streams", &Processor::input_streams) + .addFunction ("signal_latency", &Processor::signal_latency) + .endClass () + + .deriveWSPtrClass ("DiskIOProcessor") + .endClass () + + .deriveWSPtrClass ("DiskReader") + .endClass () + + .deriveWSPtrClass ("DiskWriter") .endClass () .deriveWSPtrClass ("IOProcessor") @@ -1330,6 +1372,20 @@ LuaBindings::common (lua_State* L) .addFunction ("panner_shell", &Route::panner_shell) .endClass () + .deriveWSPtrClass ("Send") + .addFunction ("get_delay_in", &Send::get_delay_in) + .addFunction ("get_delay_out", &Send::get_delay_out) + .endClass () + + .deriveWSPtrClass ("InternalSend") + .endClass () + + .deriveWSPtrClass ("Return") + .endClass () + + .deriveWSPtrClass ("InternalReturn") + .endClass () + .beginNamespace ("Plugin") .beginClass ("IOPortDescription") .addData ("name", &Plugin::IOPortDescription::name) @@ -1530,6 +1586,10 @@ LuaBindings::common (lua_State* L) .beginConstStdList > ("WeakAudioSourceList") .endClass () + // typedef std::vector > RegionVector + .beginStdVector > ("RegionVector") + .endClass () + // typedef std::list > RegionList .beginConstStdList > ("RegionList") .endClass () @@ -1566,14 +1626,14 @@ LuaBindings::common (lua_State* L) .addVoidPtrConstructor > > () .endClass () - .beginStdList > > ("NotePtrList") + .beginStdList > > ("NotePtrList") .endClass () .beginConstStdList ("EventList") .endClass () #if 0 // depends on Evoal:: Note, Beats see note_fixer.h - // typedef Evoral::Note Note; + // typedef Evoral::Note Note; // std::set< boost::weak_ptr > .beginStdSet > ("WeakNoteSet") .endClass () @@ -1588,41 +1648,41 @@ LuaBindings::common (lua_State* L) .addFunction ("note_type", &Tempo::note_type) .addFunction ("note_types_per_minute", (double (Tempo::*)() const)&Tempo::note_types_per_minute) .addFunction ("quarter_notes_per_minute", &Tempo::quarter_notes_per_minute) - .addFunction ("frames_per_quarter_note", &Tempo::frames_per_quarter_note) - .addFunction ("frames_per_note_type", &Tempo::frames_per_note_type) + .addFunction ("samples_per_quarter_note", &Tempo::samples_per_quarter_note) + .addFunction ("samples_per_note_type", &Tempo::samples_per_note_type) .endClass () .beginClass ("Meter") .addConstructor () .addFunction ("divisions_per_bar", &Meter::divisions_per_bar) .addFunction ("note_divisor", &Meter::note_divisor) - .addFunction ("frames_per_bar", &Meter::frames_per_bar) - .addFunction ("frames_per_grid", &Meter::frames_per_grid) + .addFunction ("samples_per_bar", &Meter::samples_per_bar) + .addFunction ("samples_per_grid", &Meter::samples_per_grid) .endClass () - .beginClass ("BeatsFramesConverter") - .addConstructor () - .addFunction ("to", &BeatsFramesConverter::to) - .addFunction ("from", &BeatsFramesConverter::from) + .beginClass ("BeatsSamplesConverter") + .addConstructor () + .addFunction ("to", &BeatsSamplesConverter::to) + .addFunction ("from", &BeatsSamplesConverter::from) .endClass () - .beginClass ("DoubleBeatsFramesConverter") - .addConstructor () - .addFunction ("to", &DoubleBeatsFramesConverter::to) - .addFunction ("from", &DoubleBeatsFramesConverter::from) + .beginClass ("DoubleBeatsSamplesConverter") + .addConstructor () + .addFunction ("to", &DoubleBeatsSamplesConverter::to) + .addFunction ("from", &DoubleBeatsSamplesConverter::from) .endClass () .beginClass ("TempoMap") .addFunction ("add_tempo", &TempoMap::add_tempo) .addFunction ("add_meter", &TempoMap::add_meter) - .addFunction ("tempo_section_at_frame", (TempoSection& (TempoMap::*)(framepos_t))&TempoMap::tempo_section_at_frame) - .addFunction ("tempo_section_at_frame", (const TempoSection& (TempoMap::*)(framepos_t) const)&TempoMap::tempo_section_at_frame) - .addFunction ("meter_section_at_frame", &TempoMap::meter_section_at_frame) + .addFunction ("tempo_section_at_frame", (TempoSection& (TempoMap::*)(samplepos_t))&TempoMap::tempo_section_at_sample) + .addFunction ("tempo_section_at_frame", (const TempoSection& (TempoMap::*)(samplepos_t) const)&TempoMap::tempo_section_at_sample) + .addFunction ("meter_section_at_frame", &TempoMap::meter_section_at_sample) .addFunction ("meter_section_at_beat", &TempoMap::meter_section_at_beat) - .addFunction ("bbt_at_frame", &TempoMap::bbt_at_frame) - .addFunction ("exact_beat_at_frame", &TempoMap::exact_beat_at_frame) - .addFunction ("exact_qn_at_frame", &TempoMap::exact_qn_at_frame) - .addFunction ("framepos_plus_qn", &TempoMap::framepos_plus_qn) + .addFunction ("bbt_at_frame", &TempoMap::bbt_at_sample) + .addFunction ("exact_beat_at_frame", &TempoMap::exact_beat_at_sample) + .addFunction ("exact_qn_at_frame", &TempoMap::exact_qn_at_sample) + .addFunction ("samplepos_plus_qn", &TempoMap::samplepos_plus_qn) .addFunction ("framewalk_to_qn", &TempoMap::framewalk_to_qn) .endClass () @@ -1691,6 +1751,7 @@ LuaBindings::common (lua_State* L) .addConst ("Write", ARDOUR::AutoState(Write)) .addConst ("Touch", ARDOUR::AutoState(Touch)) .addConst ("Play", ARDOUR::AutoState(Play)) + .addConst ("Latch", ARDOUR::AutoState(Latch)) .endNamespace () .beginNamespace ("AutomationType") @@ -1988,7 +2049,10 @@ LuaBindings::common (lua_State* L) .addFunction ("set_output_device_name", &AudioBackend::set_output_device_name) .endClass() - .beginClass ("PortEngine") + .beginClass ("LatencyRange") + .addVoidConstructor () + .addData ("min", &LatencyRange::min) + .addData ("max", &LatencyRange::max) .endClass() .beginClass ("PortManager") @@ -2028,6 +2092,7 @@ LuaBindings::common (lua_State* L) .addFunction ("create_vca", &VCAManager::create_vca) .addFunction ("remove_vca", &VCAManager::remove_vca) .addFunction ("vca_by_number", &VCAManager::vca_by_number) + .addFunction ("vca_by_name", &VCAManager::vca_by_name) .addFunction ("vcas", &VCAManager::vcas) .addFunction ("n_vcas", &VCAManager::n_vcas) .endClass() @@ -2083,10 +2148,10 @@ LuaBindings::common (lua_State* L) .addFunction ("scripts_changed", &Session::scripts_changed) // used internally .addFunction ("transport_rolling", &Session::transport_rolling) .addFunction ("request_transport_speed", &Session::request_transport_speed) - .addFunction ("transport_frame", &Session::transport_frame) + .addFunction ("transport_frame", &Session::transport_sample) .addFunction ("transport_speed", &Session::transport_speed) - .addFunction ("frame_rate", &Session::frame_rate) - .addFunction ("nominal_frame_rate", &Session::nominal_frame_rate) + .addFunction ("sample_rate", &Session::sample_rate) + .addFunction ("nominal_sample_rate", &Session::nominal_sample_rate) .addFunction ("samples_per_timecode_frame", &Session::samples_per_timecode_frame) .addFunction ("timecode_frames_per_hour", &Session::timecode_frames_per_hour) .addFunction ("timecode_frames_per_second", &Session::timecode_frames_per_second) @@ -2098,8 +2163,8 @@ LuaBindings::common (lua_State* L) .addFunction ("last_transport_start", &Session::last_transport_start) .addFunction ("goto_start", &Session::goto_start) .addFunction ("goto_end", &Session::goto_end) - .addFunction ("current_start_frame", &Session::current_start_frame) - .addFunction ("current_end_frame", &Session::current_end_frame) + .addFunction ("current_start_frame", &Session::current_start_sample) + .addFunction ("current_end_frame", &Session::current_end_sample) .addFunction ("actively_recording", &Session::actively_recording) .addFunction ("new_audio_track", &Session::new_audio_track) .addFunction ("new_audio_route", &Session::new_audio_route) @@ -2123,7 +2188,6 @@ LuaBindings::common (lua_State* L) .addFunction ("get_remote_nth_stripable", &Session::get_remote_nth_stripable) .addFunction ("get_remote_nth_route", &Session::get_remote_nth_route) .addFunction ("route_by_selected_count", &Session::route_by_selected_count) - .addFunction ("track_by_diskstream_id", &Session::track_by_diskstream_id) .addFunction ("source_by_id", &Session::source_by_id) .addFunction ("controllable_by_id", &Session::controllable_by_id) .addFunction ("processor_by_id", &Session::processor_by_id) @@ -2150,8 +2214,8 @@ LuaBindings::common (lua_State* L) .addFunction ("get_block_size", &Session::get_block_size) .addFunction ("worst_output_latency", &Session::worst_output_latency) .addFunction ("worst_input_latency", &Session::worst_input_latency) - .addFunction ("worst_track_latency", &Session::worst_track_latency) - .addFunction ("worst_playback_latency", &Session::worst_playback_latency) + .addFunction ("worst_route_latency", &Session::worst_route_latency) + .addFunction ("worst_latency_preroll", &Session::worst_latency_preroll) .addFunction ("cfg", &Session::cfg) .addFunction ("route_groups", &Session::route_groups) .addFunction ("new_route_group", &Session::new_route_group) @@ -2305,11 +2369,11 @@ LuaBindings::dsp (lua_State* L) .beginClass ("AudioBuffer") .addEqualCheck () - .addFunction ("data", (Sample*(AudioBuffer::*)(framecnt_t))&AudioBuffer::data) + .addFunction ("data", (Sample*(AudioBuffer::*)(samplecnt_t))&AudioBuffer::data) .addFunction ("silence", &AudioBuffer::silence) .addFunction ("apply_gain", &AudioBuffer::apply_gain) .addFunction ("check_silence", &AudioBuffer::check_silence) - .addFunction ("read_from", (void (AudioBuffer::*)(const Sample*, framecnt_t, framecnt_t, framecnt_t))&AudioBuffer::check_silence) + .addFunction ("read_from", (void (AudioBuffer::*)(const Sample*, samplecnt_t, samplecnt_t, samplecnt_t))&AudioBuffer::check_silence) .endClass() .beginClass ("MidiBuffer") @@ -2319,10 +2383,10 @@ LuaBindings::dsp (lua_State* L) .addFunction ("empty", &MidiBuffer::empty) .addFunction ("resize", &MidiBuffer::resize) .addFunction ("copy", (void (MidiBuffer::*)(MidiBuffer const * const))&MidiBuffer::copy) - .addFunction ("push_event", (bool (MidiBuffer::*)(const Evoral::Event&))&MidiBuffer::push_back) - .addFunction ("push_back", (bool (MidiBuffer::*)(framepos_t, size_t, const uint8_t*))&MidiBuffer::push_back) + .addFunction ("push_event", (bool (MidiBuffer::*)(const Evoral::Event&))&MidiBuffer::push_back) + .addFunction ("push_back", (bool (MidiBuffer::*)(samplepos_t, size_t, const uint8_t*))&MidiBuffer::push_back) // TODO iterators.. - .addExtCFunction ("table", &luabridge::CFunc::listToTable, MidiBuffer>) + .addExtCFunction ("table", &luabridge::CFunc::listToTable, MidiBuffer>) .endClass() .beginClass ("BufferSet") @@ -2335,12 +2399,12 @@ LuaBindings::dsp (lua_State* L) luabridge::getGlobalNamespace (L) .beginNamespace ("Evoral") - .deriveClass , Evoral::Event > ("Event") + .deriveClass , Evoral::Event > ("Event") // add Ctor? - .addFunction ("type", &Evoral::Event::type) - .addFunction ("channel", &Evoral::Event::channel) - .addFunction ("set_type", &Evoral::Event::set_type) - .addFunction ("set_channel", &Evoral::Event::set_channel) + .addFunction ("type", &Evoral::Event::type) + .addFunction ("channel", &Evoral::Event::channel) + .addFunction ("set_type", &Evoral::Event::set_type) + .addFunction ("set_channel", &Evoral::Event::set_channel) .endClass () .endNamespace ();