US2400: send_pan_azimuth lookup function (currently mb-only)
This commit is contained in:
parent
e156ec28bb
commit
28d8f2f6b9
@ -557,6 +557,7 @@ public:
|
||||
*/
|
||||
boost::shared_ptr<AutomationControl> send_level_controllable (uint32_t n) const;
|
||||
boost::shared_ptr<AutomationControl> send_enable_controllable (uint32_t n) const;
|
||||
boost::shared_ptr<AutomationControl> send_pan_azi_controllable (uint32_t n) const;
|
||||
/* for the same value of @param n, this returns the name of the send
|
||||
* associated with the pair of controllables returned by the above two methods.
|
||||
*/
|
||||
|
@ -177,6 +177,7 @@ class LIBARDOUR_API Stripable : public SessionObject,
|
||||
*/
|
||||
virtual boost::shared_ptr<AutomationControl> send_level_controllable (uint32_t n) const = 0;
|
||||
virtual boost::shared_ptr<AutomationControl> send_enable_controllable (uint32_t n) const = 0;
|
||||
virtual boost::shared_ptr<AutomationControl> send_pan_azi_controllable (uint32_t n) const = 0;
|
||||
|
||||
/* for the same value of @param n, this returns the name of the send
|
||||
* associated with the pair of controllables returned by the above two methods.
|
||||
|
@ -137,6 +137,7 @@ class LIBARDOUR_API VCA : public Stripable,
|
||||
std::string comp_speed_name (uint32_t mode) const { return std::string(); }
|
||||
boost::shared_ptr<AutomationControl> send_level_controllable (uint32_t n) const { return boost::shared_ptr<AutomationControl>(); }
|
||||
boost::shared_ptr<AutomationControl> send_enable_controllable (uint32_t n) const { return boost::shared_ptr<AutomationControl>(); }
|
||||
boost::shared_ptr<AutomationControl> send_pan_azi_controllable (uint32_t n) const { return boost::shared_ptr<AutomationControl>(); }
|
||||
std::string send_name (uint32_t n) const { return std::string(); }
|
||||
boost::shared_ptr<AutomationControl> master_send_enable_controllable () const { return boost::shared_ptr<AutomationControl>(); }
|
||||
boost::shared_ptr<MonitorProcessor> monitor_control() const { return boost::shared_ptr<MonitorProcessor>(); }
|
||||
|
@ -5584,6 +5584,43 @@ Route::comp_speed_name (uint32_t mode) const
|
||||
#endif
|
||||
}
|
||||
|
||||
boost::shared_ptr<AutomationControl>
|
||||
Route::send_pan_azi_controllable (uint32_t n) const
|
||||
{
|
||||
#ifdef MIXBUS
|
||||
# undef MIXBUS_PORTS_H
|
||||
# include "../../gtk2_ardour/mixbus_ports.h"
|
||||
boost::shared_ptr<ARDOUR::PluginInsert> plug = ch_post();
|
||||
if (plug && !mixbus()) {
|
||||
uint32_t port_id = 0;
|
||||
switch (n) {
|
||||
# ifdef MIXBUS32C
|
||||
case 0: port_id = port_channel_post_aux0_pan; break; //32c mb "pan" controls use zero-based names, unlike levels. ugh
|
||||
case 1: port_id = port_channel_post_aux1_pan; break;
|
||||
case 2: port_id = port_channel_post_aux2_pan; break;
|
||||
case 3: port_id = port_channel_post_aux3_pan; break;
|
||||
case 4: port_id = port_channel_post_aux4_pan; break;
|
||||
case 5: port_id = port_channel_post_aux5_pan; break;
|
||||
case 6: port_id = port_channel_post_aux6_pan; break;
|
||||
case 7: port_id = port_channel_post_aux7_pan; break;
|
||||
case 8: port_id = port_channel_post_aux8_pan; break;
|
||||
case 9: port_id = port_channel_post_aux9_pan; break;
|
||||
case 10: port_id = port_channel_post_aux10_pan; break;
|
||||
case 11: port_id = port_channel_post_aux11_pan; break;
|
||||
# endif
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
if (port_id > 0) {
|
||||
return boost::dynamic_pointer_cast<ARDOUR::AutomationControl> (plug->control (Evoral::Parameter (ARDOUR::PluginAutomation, 0, port_id)));
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
boost::shared_ptr<AutomationControl>();
|
||||
}
|
||||
|
||||
boost::shared_ptr<AutomationControl>
|
||||
Route::send_level_controllable (uint32_t n) const
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user