add some assert for reloading saved plugin pin connections
[ardour.git] / libs / ardour / luabindings.cc
index a475416c19a0fe70b4038bca0c61de680b04cfbb..2fa6fa0604dd780cb37d0a4f45e40b4e5cd7803d 100644 (file)
@@ -102,8 +102,10 @@ luabridge::getIdentityKey ()
 
 /* ...and this is the ugly part of it.
  *
- * We need to foward declare classes from gtk2_ardour.
- * This is needed because some of the classes use objects from libardour
+ * We need to foward declare classes from gtk2_ardour
+ * end explicily list classes which are used by gtk2_ardour's bindings.
+ *
+ * This is needed because some of the GUI classes use objects from libardour
  * as function parameters and the .exe would re-create symbols for libardour
  * objects.
  *
@@ -143,6 +145,32 @@ CLASSKEYS(std::bitset<47ul>); // LuaSignal::LAST_SIGNAL
 CLASSKEYS(ArdourMarker*);
 CLASSKEYS(ARDOUR::RouteGroup);
 CLASSKEYS(ARDOUR::LuaProc);
+CLASSKEYS(ARDOUR::DataType);
+CLASSKEYS(ARDOUR::ChanCount);
+CLASSKEYS(boost::shared_ptr<ARDOUR::Processor>);
+CLASSKEYS(ARDOUR::ParameterDescriptor);
+CLASSKEYS(boost::shared_ptr<ARDOUR::AutomationList>);
+CLASSKEYS(boost::shared_ptr<Evoral::ControlList>);
+CLASSKEYS(ARDOUR::LuaOSC::Address);
+CLASSKEYS(ARDOUR::Session);
+CLASSKEYS(ARDOUR::BufferSet);
+CLASSKEYS(ARDOUR::ChanMapping);
+CLASSKEYS(ARDOUR::DSP::DspShm);
+CLASSKEYS(PBD::ID);
+CLASSKEYS(ARDOUR::Location);
+CLASSKEYS(ARDOUR::PluginInfo);
+CLASSKEYS(PBD::PropertyChange);
+CLASSKEYS(std::vector<std::string>);
+CLASSKEYS(std::list<boost::shared_ptr<ARDOUR::Route> >);
+CLASSKEYS(boost::shared_ptr<ARDOUR::PluginInfo>);
+CLASSKEYS(boost::shared_ptr<ARDOUR::Region>);
+CLASSKEYS(boost::weak_ptr<ARDOUR::Route>);
+CLASSKEYS(std::list<boost::shared_ptr<ARDOUR::Region> >);
+CLASSKEYS(std::list<ARDOUR::AudioRange>);
+CLASSKEYS(Evoral::Beats);
+CLASSKEYS(ARDOUR::AudioEngine);
+CLASSKEYS(void);
+CLASSKEYS(float);
 
 #endif // end windows special case
 
@@ -401,7 +429,7 @@ LuaBindings::common (lua_State* L)
                .addFunction ("move_to", &Location::move_to)
                .endClass ()
 
-               .deriveClass <Locations, PBD::StatefulDestructible> ("Location")
+               .deriveClass <Locations, PBD::StatefulDestructible> ("Locations")
                .addFunction ("auto_loop_location", &Locations::auto_loop_location)
                .addFunction ("auto_punch_location", &Locations::auto_punch_location)
                .addFunction ("session_range_location", &Locations::session_range_location)
@@ -537,7 +565,7 @@ LuaBindings::common (lua_State* L)
                .addFunction ("set_record_enabled", &Track::set_record_enabled)
                .addFunction ("set_record_safe", &Track::set_record_safe)
                .addFunction ("bounceable", &Track::bounceable)
-               .addFunction ("bounce", &Track::bounce_range)
+               .addFunction ("bounce", &Track::bounce)
                .addFunction ("bounce_range", &Track::bounce_range)
                .addFunction ("playlist", &Track::playlist)
                .endClass ()
@@ -673,6 +701,7 @@ LuaBindings::common (lua_State* L)
                .addFunction ("output_map", (ARDOUR::ChanMapping (PluginInsert::*)(uint32_t) const)&PluginInsert::output_map)
                .addFunction ("set_input_map", &PluginInsert::set_input_map)
                .addFunction ("set_output_map", &PluginInsert::set_output_map)
+               .addFunction ("sidechain_input", &PluginInsert::sidechain_input)
                .endClass ()
 
                .deriveWSPtrClass <AutomationControl, PBD::Controllable> ("AutomationControl")
@@ -976,6 +1005,7 @@ LuaBindings::dsp (lua_State* L)
                .beginNamespace ("ARDOUR")
 
                .beginClass <AudioBuffer> ("AudioBuffer")
+               .addEqualCheck ()
                .addFunction ("data", (Sample*(AudioBuffer::*)(framecnt_t))&AudioBuffer::data)
                .addFunction ("silence", &AudioBuffer::silence)
                .addFunction ("apply_gain", &AudioBuffer::apply_gain)
@@ -984,12 +1014,14 @@ LuaBindings::dsp (lua_State* L)
                .endClass()
 
                .beginClass <MidiBuffer> ("MidiBuffer")
+               .addEqualCheck ()
                .addFunction ("silence", &MidiBuffer::silence)
                .addFunction ("empty", &MidiBuffer::empty)
                // TODO iterators..
                .endClass()
 
                .beginClass <BufferSet> ("BufferSet")
+               .addEqualCheck ()
                .addFunction ("get_audio", static_cast<AudioBuffer&(BufferSet::*)(size_t)>(&BufferSet::get_audio))
                .addFunction ("count", static_cast<const ChanCount&(BufferSet::*)()const>(&BufferSet::count))
                .endClass()