diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2016-11-25 10:29:16 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2016-11-25 10:29:42 +0000 |
commit | c5eda4cfe1e7b9ae9abbe2e7b6bd640586a3b9fb (patch) | |
tree | 7141aae5abeddbf141a2ff207ebe0cf205c9de28 /libs/ardour/session_rtevents.cc | |
parent | e35ce4c002e0dfb4db76a5108e0028719f469734 (diff) |
provisional changes to speed up solo changes to large numbers of routes.
Moves global update of solo state and emission of Session::SoloChanged to
a single point after 1 to N solo controls are changed.
Also avoid unnecessarily emitted Activated() signal for listen controls,
though Process::{activate,deactive}() should probably be redesigned to
avoid this in a "deeper" way
Diffstat (limited to 'libs/ardour/session_rtevents.cc')
-rw-r--r-- | libs/ardour/session_rtevents.cc | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/libs/ardour/session_rtevents.cc b/libs/ardour/session_rtevents.cc index 00d966acaa..5f1c7a54cb 100644 --- a/libs/ardour/session_rtevents.cc +++ b/libs/ardour/session_rtevents.cc @@ -64,9 +64,28 @@ Session::set_control (boost::shared_ptr<AutomationControl> ac, double val, Contr void Session::rt_set_controls (boost::shared_ptr<ControlList> cl, double val, Controllable::GroupControlDisposition gcd) { + /* Note that we require that all controls in the ControlList are of the + same type. + */ + if (cl->empty()) { + return; + } + for (ControlList::iterator c = cl->begin(); c != cl->end(); ++c) { (*c)->set_value (val, gcd); } + + /* some controls need global work to take place after they are set. Do + * that here. + */ + + switch (cl->front()->parameter().type()) { + case SoloAutomation: + update_route_solo_state (); + break; + default: + break; + } } void |