summaryrefslogtreecommitdiff
path: root/libs/ardour/luabindings.cc
diff options
context:
space:
mode:
authorRobin Gareus <robin@gareus.org>2017-08-17 01:13:28 +0200
committerRobin Gareus <robin@gareus.org>2017-08-17 01:13:39 +0200
commita4ee2d3c1743245b2c0bb8ec65c09974b130cce5 (patch)
treed069705778898a74e894cc4e14d71968b4c4870a /libs/ardour/luabindings.cc
parent76036ae0f369ea76aaa47bb43e41af450114f190 (diff)
Expose enums used in RCConfig and other missing classes to Lua.
Diffstat (limited to 'libs/ardour/luabindings.cc')
-rw-r--r--libs/ardour/luabindings.cc113
1 files changed, 110 insertions, 3 deletions
diff --git a/libs/ardour/luabindings.cc b/libs/ardour/luabindings.cc
index e53cc02dc0..5ff36d6f69 100644
--- a/libs/ardour/luabindings.cc
+++ b/libs/ardour/luabindings.cc
@@ -1381,6 +1381,12 @@ LuaBindings::common (lua_State* L)
.addFunction ("reset_parameters_to_default", &PluginInsert::reset_parameters_to_default)
.endClass ()
+ .deriveWSPtrClass <ReadOnlyControl, PBD::StatefulDestructible> ("ReadOnlyControl")
+ .addFunction ("get_parameter", &ReadOnlyControl::get_parameter)
+ .addFunction ("describe_parameter", &ReadOnlyControl::describe_parameter)
+ .addFunction ("desc", &ReadOnlyControl::desc)
+ .endClass ()
+
.deriveWSPtrClass <AutomationControl, PBD::Controllable> ("AutomationControl")
.addCast<Evoral::Control> ("to_ctrl")
.addCast<SlavableAutomationControl> ("to_slavable")
@@ -1394,7 +1400,7 @@ LuaBindings::common (lua_State* L)
.addFunction ("alist", &AutomationControl::alist)
.endClass ()
- .deriveWSPtrClass <SlavableAutomationControl, AutomationControl> ("SlavableAutomationControl,")
+ .deriveWSPtrClass <SlavableAutomationControl, AutomationControl> ("SlavableAutomationControl")
.addFunction ("add_master", &SlavableAutomationControl::add_master)
.addFunction ("remove_master", &SlavableAutomationControl::remove_master)
.addFunction ("clear_masters", &SlavableAutomationControl::clear_masters)
@@ -1780,8 +1786,8 @@ LuaBindings::common (lua_State* L)
.endNamespace ()
.beginNamespace ("MidiTempoMapDisposition")
- .addConst ("SMFTempoIgnore", ARDOUR::MidiTrackNameSource(SMFTempoIgnore))
- .addConst ("SMFTempoUse", ARDOUR::MidiTrackNameSource(SMFTempoUse))
+ .addConst ("SMFTempoIgnore", ARDOUR::MidiTempoMapDisposition(SMFTempoIgnore))
+ .addConst ("SMFTempoUse", ARDOUR::MidiTempoMapDisposition(SMFTempoUse))
.endNamespace ()
.beginNamespace ("RegionPoint")
@@ -1837,6 +1843,107 @@ LuaBindings::common (lua_State* L)
.addConst ("Extend", ARDOUR::InsertMergePolicy(InsertMergeExtend))
.endNamespace ()
+ .beginNamespace ("AFLPosition")
+ .addConst ("AFLFromBeforeProcessors", ARDOUR::AFLPosition(AFLFromBeforeProcessors))
+ .addConst ("AFLFromAfterProcessors", ARDOUR::AFLPosition(AFLFromAfterProcessors))
+ .endNamespace ()
+
+ .beginNamespace ("PFLPosition")
+ .addConst ("PFLFromBeforeProcessors", ARDOUR::PFLPosition(PFLFromBeforeProcessors))
+ .addConst ("PFLFromAfterProcessors", ARDOUR::PFLPosition(PFLFromAfterProcessors))
+ .endNamespace ()
+
+ .beginNamespace ("AutoReturnTarget")
+ .addConst ("LastLocate", ARDOUR::AutoReturnTarget(LastLocate))
+ .addConst ("RangeSelectionStart", ARDOUR::AutoReturnTarget(RangeSelectionStart))
+ .addConst ("Loop", ARDOUR::AutoReturnTarget(Loop))
+ .addConst ("RegionSelectionStart", ARDOUR::AutoReturnTarget(RegionSelectionStart))
+ .endNamespace ()
+
+ .beginNamespace ("FadeShape")
+ .addConst ("FadeLinear", ARDOUR::FadeShape(FadeLinear))
+ .addConst ("FadeFast", ARDOUR::FadeShape(FadeFast))
+ .addConst ("FadeSlow", ARDOUR::FadeShape(FadeSlow))
+ .addConst ("FadeConstantPower", ARDOUR::FadeShape(FadeConstantPower))
+ .addConst ("FadeSymmetric", ARDOUR::FadeShape(FadeSymmetric))
+ .endNamespace ()
+
+ .beginNamespace ("DenormalModel")
+ .addConst ("DenormalNone", ARDOUR::DenormalModel(DenormalNone))
+ .addConst ("DenormalFTZ", ARDOUR::DenormalModel(DenormalFTZ))
+ .addConst ("DenormalDAZ", ARDOUR::DenormalModel(DenormalDAZ))
+ .addConst ("DenormalFTZDAZ", ARDOUR::DenormalModel(DenormalFTZDAZ))
+ .endNamespace ()
+
+ .beginNamespace ("BufferingPreset")
+ .addConst ("Small", ARDOUR::BufferingPreset(Small))
+ .addConst ("Medium", ARDOUR::BufferingPreset(Medium))
+ .addConst ("Large", ARDOUR::BufferingPreset(Large))
+ .addConst ("Custom", ARDOUR::BufferingPreset(Custom))
+ .endNamespace ()
+
+ .beginNamespace ("EditMode")
+ .addConst ("Slide", ARDOUR::EditMode(Slide))
+ .addConst ("Splice", ARDOUR::EditMode(Splice))
+ .addConst ("Ripple", ARDOUR::EditMode(Ripple))
+ .addConst ("Lock", ARDOUR::EditMode(Lock))
+ .endNamespace ()
+
+ .beginNamespace ("AutoConnectOption")
+ .addConst ("ManualConnect", ARDOUR::AutoConnectOption(ManualConnect))
+ .addConst ("AutoConnectPhysical", ARDOUR::AutoConnectOption(AutoConnectPhysical))
+ .addConst ("AutoConnectMaster", ARDOUR::AutoConnectOption(AutoConnectMaster))
+ .endNamespace ()
+
+ .beginNamespace ("LayerModel")
+ .addConst ("LaterHigher", ARDOUR::LayerModel(LaterHigher))
+ .addConst ("Manual", ARDOUR::LayerModel(Manual))
+ .endNamespace ()
+
+ .beginNamespace ("ListenPosition")
+ .addConst ("AfterFaderListen", ARDOUR::ListenPosition(AfterFaderListen))
+ .addConst ("PreFaderListen", ARDOUR::ListenPosition(PreFaderListen))
+ .endNamespace ()
+
+ .beginNamespace ("MonitorModel")
+ .addConst ("HardwareMonitoring", ARDOUR::MonitorModel(HardwareMonitoring))
+ .addConst ("SoftwareMonitoring", ARDOUR::MonitorModel(SoftwareMonitoring))
+ .addConst ("ExternalMonitoring", ARDOUR::MonitorModel(ExternalMonitoring))
+ .endNamespace ()
+
+ .beginNamespace ("RegionSelectionAfterSplit")
+ .addConst ("None", ARDOUR::RegionSelectionAfterSplit(None))
+ .addConst ("NewlyCreatedLeft", ARDOUR::RegionSelectionAfterSplit(NewlyCreatedLeft))
+ .addConst ("NewlyCreatedRight", ARDOUR::RegionSelectionAfterSplit(NewlyCreatedRight))
+ .addConst ("NewlyCreatedBoth", ARDOUR::RegionSelectionAfterSplit(NewlyCreatedBoth))
+ .addConst ("Existing", ARDOUR::RegionSelectionAfterSplit(Existing))
+ .addConst ("ExistingNewlyCreatedLeft", ARDOUR::RegionSelectionAfterSplit(ExistingNewlyCreatedLeft))
+ .addConst ("ExistingNewlyCreatedRight", ARDOUR::RegionSelectionAfterSplit(ExistingNewlyCreatedRight))
+ .addConst ("ExistingNewlyCreatedBoth", ARDOUR::RegionSelectionAfterSplit(ExistingNewlyCreatedBoth))
+ .endNamespace ()
+
+ .beginNamespace ("ShuttleBehaviour")
+ .addConst ("Sprung", ARDOUR::ShuttleBehaviour(Sprung))
+ .addConst ("Wheel", ARDOUR::ShuttleBehaviour(Wheel))
+ .endNamespace ()
+
+ .beginNamespace ("ShuttleUnits")
+ .addConst ("Percentage", ARDOUR::ShuttleUnits(Percentage))
+ .addConst ("Semitones", ARDOUR::ShuttleUnits(Semitones))
+ .endNamespace ()
+
+ .beginNamespace ("SyncSource")
+ .addConst ("Engine", ARDOUR::SyncSource(Engine))
+ .addConst ("MTC", ARDOUR::SyncSource(MTC))
+ .addConst ("MIDIClock", ARDOUR::SyncSource(MIDIClock))
+ .addConst ("LTC", ARDOUR::SyncSource(LTC))
+ .endNamespace ()
+
+ .beginNamespace ("TracksAutoNamingRule")
+ .addConst ("UseDefaultNames", ARDOUR::TracksAutoNamingRule(UseDefaultNames))
+ .addConst ("NameAfterDriver", ARDOUR::TracksAutoNamingRule(NameAfterDriver))
+ .endNamespace ()
+
.endNamespace (); // end ARDOUR
luabridge::getGlobalNamespace (L)