OSC: Add command to select Master
This commit is contained in:
@@ -543,6 +543,7 @@ OSC::register_callbacks()
|
||||
REGISTER_CALLBACK (serv, "/master/mute", "i", master_set_mute);
|
||||
REGISTER_CALLBACK (serv, "/master/trimdB", "f", master_set_trim);
|
||||
REGISTER_CALLBACK (serv, "/master/pan_stereo_position", "f", master_set_pan_stereo_position);
|
||||
REGISTER_CALLBACK (serv, "/master/select", "f", master_select);
|
||||
REGISTER_CALLBACK (serv, "/monitor/gain", "f", monitor_set_gain);
|
||||
REGISTER_CALLBACK (serv, "/monitor/fader", "f", monitor_set_fader);
|
||||
REGISTER_CALLBACK (serv, "/monitor/db_delta", "f", monitor_delta_gain);
|
||||
@@ -2484,6 +2485,22 @@ OSC::master_set_mute (uint32_t state)
|
||||
return 0;
|
||||
}
|
||||
|
||||
int
|
||||
OSC::master_select (lo_message msg)
|
||||
{
|
||||
if (!session) {
|
||||
return -1;
|
||||
}
|
||||
OSCSurface *sur = get_surface(get_address (msg));
|
||||
sur->expand_enable = false;
|
||||
boost::shared_ptr<Stripable> s = session->master_out();
|
||||
if (s) {
|
||||
SetStripableSelection (s);
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
int
|
||||
OSC::monitor_set_gain (float dB)
|
||||
{
|
||||
|
||||
@@ -306,6 +306,7 @@ class OSC : public ARDOUR::ControlProtocol, public AbstractUI<OSCUIRequest>
|
||||
PATH_CALLBACK_MSG(refresh_surface);
|
||||
PATH_CALLBACK_MSG(bank_up);
|
||||
PATH_CALLBACK_MSG(bank_down);
|
||||
PATH_CALLBACK_MSG(master_select);
|
||||
|
||||
#define PATH_CALLBACK(name) \
|
||||
static int _ ## name (const char *path, const char *types, lo_arg **argv, int argc, void *data, void *user_data) { \
|
||||
@@ -622,6 +623,7 @@ class OSC : public ARDOUR::ControlProtocol, public AbstractUI<OSCUIRequest>
|
||||
int master_set_trim (float dB);
|
||||
int master_set_pan_stereo_position (float position, lo_message msg);
|
||||
int master_set_mute (uint32_t state);
|
||||
int master_select (lo_message msg);
|
||||
int monitor_set_gain (float dB);
|
||||
int monitor_set_fader (float position);
|
||||
int monitor_delta_gain (float delta);
|
||||
|
||||
Reference in New Issue
Block a user