mirror of
https://github.com/brunoherbelin/vimix.git
synced 2025-12-09 17:29:59 +01:00
OSC set current by source name
This commit is contained in:
@@ -152,6 +152,7 @@ void Control::RequestListener::ProcessMessage( const osc::ReceivedMessage& m,
|
||||
// Current source target: apply attribute to the current sources
|
||||
else if ( target.compare(OSC_CURRENT) == 0 )
|
||||
{
|
||||
Source *_cs = Mixer::manager().findSource(attribute.substr(1));
|
||||
int sourceid = -1;
|
||||
if ( attribute.compare(OSC_SYNC) == 0) {
|
||||
// send the status of all sources
|
||||
@@ -175,6 +176,12 @@ void Control::RequestListener::ProcessMessage( const osc::ReceivedMessage& m,
|
||||
// send the status of all sources
|
||||
Control::manager().sendSourcesStatus(remoteEndpoint, m.ArgumentStream());
|
||||
}
|
||||
else if ( _cs != nullptr ) {
|
||||
// set current to given source by name
|
||||
Mixer::manager().setCurrentSource(_cs);
|
||||
// send the status of all sources
|
||||
Control::manager().sendSourcesStatus(remoteEndpoint, m.ArgumentStream());
|
||||
}
|
||||
// all other attributes operate on current source
|
||||
else {
|
||||
// apply attributes to current source
|
||||
|
||||
Reference in New Issue
Block a user