diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2010-04-27 03:10:53 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2010-04-27 03:10:53 +0000 |
commit | a8e354ed7bb38f8be8bfdda33841f3f238e8bbab (patch) | |
tree | e2ab48a8b041c1146f33e87de60689314e52a1e1 /libs/ardour/ardour/route.h | |
parent | 56469c195640b561119852fd6d27a4b56e5af7e2 (diff) |
yet more work on Ye Fabled Solo Architecture. now do forward and backward propagation of solo status from a soloed track. tweak GUI appearance
git-svn-id: svn://localhost/ardour2/branches/3.0@7001 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/ardour/route.h')
-rw-r--r-- | libs/ardour/ardour/route.h | 38 |
1 files changed, 35 insertions, 3 deletions
diff --git a/libs/ardour/ardour/route.h b/libs/ardour/ardour/route.h index f9ba1a8e8a..6068103896 100644 --- a/libs/ardour/ardour/route.h +++ b/libs/ardour/ardour/route.h @@ -238,7 +238,7 @@ class Route : public SessionObject, public AutomatableControls, public RouteGrou PBD::Signal0<void> phase_invert_changed; PBD::Signal0<void> denormal_protection_changed; PBD::Signal1<void,void*> listen_changed; - PBD::Signal1<void,void*> solo_changed; + PBD::Signal2<void,bool,void*> solo_changed; PBD::Signal1<void,void*> solo_safe_changed; PBD::Signal1<void,void*> solo_isolated_changed; PBD::Signal1<void,void*> comment_changed; @@ -273,8 +273,39 @@ class Route : public SessionObject, public AutomatableControls, public RouteGrou int listen_via (boost::shared_ptr<Route>, Placement p, bool active, bool aux); void drop_listen (boost::shared_ptr<Route>); - bool feeds (boost::shared_ptr<Route>, bool* via_send_only = 0); - std::set<boost::weak_ptr<Route> > fed_by; + /** + * return true if this route feeds the first argument via at least one + * (arbitrarily long) signal pathway. + */ + bool feeds (boost::shared_ptr<Route>, bool* via_send_only = 0); + + /** + * return true if this route feeds the first argument directly, via + * either its main outs or a send. + */ + bool direct_feeds (boost::shared_ptr<Route>, bool* via_send_only = 0); + + struct FeedRecord { + boost::weak_ptr<Route> r; + bool sends_only; + + FeedRecord (boost::shared_ptr<Route> rp, bool sendsonly) + : r (rp) + , sends_only (sendsonly) {} + }; + + struct FeedRecordCompare { + bool operator() (const FeedRecord& a, const FeedRecord& b) const { + return a.r < b.r; + } + }; + + typedef std::set<FeedRecord,FeedRecordCompare> FedBy; + + const FedBy& fed_by() const { return _fed_by; } + void clear_fed_by (); + bool add_fed_by (boost::shared_ptr<Route>, bool sends_only); + bool not_fed() const { return _fed_by.empty(); } /* Controls (not all directly owned by the Route */ @@ -393,6 +424,7 @@ class Route : public SessionObject, public AutomatableControls, public RouteGrou bool _have_internal_generator; bool _solo_safe; DataType _default_type; + FedBy _fed_by; virtual ChanCount input_streams () const; |