start shaping up VCA assign process
[ardour.git] / libs / ardour / route.cc
index 49528e30e32e2be564b7249c67c1b5249b12b04c..8b1f47ec4ec22a6409472fe16266dba077523ac5 100644 (file)
@@ -69,6 +69,7 @@
 #include "ardour/session.h"
 #include "ardour/unknown_processor.h"
 #include "ardour/utils.h"
+#include "ardour/vca.h"
 
 #include "i18n.h"
 
@@ -3345,7 +3346,7 @@ Route::set_processor_state (const XMLNode& node)
 
        for (niter = nlist.begin(); niter != nlist.end(); ++niter) {
 
-               XMLProperty const * prop = (*niter)->property ("type");
+               XMLProperty* prop = (*niter)->property ("type");
 
                if (prop->value() == "amp") {
                        _amp->set_state (**niter, Stateful::current_state_version);
@@ -5883,3 +5884,13 @@ Route::master_send_enable_controllable () const
        return boost::shared_ptr<AutomationControl>();
 #endif
 }
+
+bool
+Route::slaved_to (boost::shared_ptr<VCA> vca) const
+{
+       if (!vca || !_gain_control) {
+               return false;
+       }
+
+       return _gain_control->slaved_to (vca->control());
+}