add new Route API ::master_send_enable_controllable() to provide generic access to a mixbus-centric control
This commit is contained in:
parent
c6ea3515d1
commit
fd291d1fa5
@ -567,6 +567,14 @@ class LIBARDOUR_API Route : public SessionObject, public Automatable, public Rou
|
||||
*/
|
||||
std::string send_name (uint32_t n) const;
|
||||
|
||||
/* well known control that enables/disables sending to the master bus.
|
||||
*
|
||||
* In Ardour, this returns null.
|
||||
* In Mixbus, it will return a suitable control, or null depending on
|
||||
* the route.
|
||||
*/
|
||||
boost::shared_ptr<AutomationControl> master_send_enable_controllable () const;
|
||||
|
||||
void protect_automation ();
|
||||
|
||||
enum {
|
||||
|
@ -5571,3 +5571,15 @@ Route::send_name (uint32_t n) const
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
boost::shared_ptr<AutomationControl>
|
||||
Route::master_send_enable_controllable () const
|
||||
{
|
||||
#ifdef MIXBUS
|
||||
boost::shared_ptr<ARDOUR::PluginInsert> plug = ch_post();
|
||||
assert (plug);
|
||||
return boost::dynamic_pointer_cast<ARDOUR::AutomationControl> (plug->control (Evoral::Parameter (ARDOUR::PluginAutomation, 0, port_channel_post_mstr_assign)));
|
||||
#else
|
||||
return boost::shared_ptr<AutomationControl>();
|
||||
#endif
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user