summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLen Ovens <len@ovenwerks.net>2018-10-22 12:36:59 -0700
committerLen Ovens <len@ovenwerks.net>2018-10-30 12:15:28 -0700
commitbe5a89aa22df9c0c3a35908d3a3020514f8f504a (patch)
treeb8cf89c3d0534bd625c8ab6e3411768be8e09d40
parent5b2eb6107c3ae056e7c27182008b46b4df5c2b28 (diff)
Add ListenBus to stripable types
-rw-r--r--libs/ardour/ardour/presentation_info.h4
-rw-r--r--libs/ardour/ardour/stripable.h1
-rw-r--r--libs/ardour/enums.cc1
-rw-r--r--libs/ardour/presentation_info.cc2
-rw-r--r--libs/ardour/session.cc2
5 files changed, 8 insertions, 2 deletions
diff --git a/libs/ardour/ardour/presentation_info.h b/libs/ardour/ardour/presentation_info.h
index 0bcfff9210..842d18292c 100644
--- a/libs/ardour/ardour/presentation_info.h
+++ b/libs/ardour/ardour/presentation_info.h
@@ -117,11 +117,13 @@ class LIBARDOUR_API PresentationInfo : public PBD::Stateful
Hidden = 0x100,
/* single bit indicates that the group order is set */
OrderSet = 0x400,
+ /* bus type for monitor mixes */
+ ListenBus = 0x2000,
/* special mask to delect out "state" bits */
StatusMask = (Hidden),
/* special mask to delect select type bits */
- TypeMask = (AudioBus|AudioTrack|MidiTrack|MidiBus|VCA|MasterOut|MonitorOut|Auditioner)
+ TypeMask = (AudioBus|AudioTrack|MidiTrack|MidiBus|VCA|MasterOut|MonitorOut|Auditioner|ListenBus)
};
static const Flag AllStripables; /* mask to use for any route or VCA (but not auditioner) */
diff --git a/libs/ardour/ardour/stripable.h b/libs/ardour/ardour/stripable.h
index 08b2a6bd69..4ba7532d9a 100644
--- a/libs/ardour/ardour/stripable.h
+++ b/libs/ardour/ardour/stripable.h
@@ -74,6 +74,7 @@ class LIBARDOUR_API Stripable : public SessionObject,
bool is_private_route() const { return is_auditioner(); }
bool is_master() const { return _presentation_info.flags() & PresentationInfo::MasterOut; }
bool is_monitor() const { return _presentation_info.flags() & PresentationInfo::MonitorOut; }
+ bool is_listenbus() const { return _presentation_info.flags() & PresentationInfo::ListenBus; }
int set_state (XMLNode const&, int);
diff --git a/libs/ardour/enums.cc b/libs/ardour/enums.cc
index 6e2f1dfc99..5b7bbe457d 100644
--- a/libs/ardour/enums.cc
+++ b/libs/ardour/enums.cc
@@ -734,6 +734,7 @@ setup_enum_writer ()
REGISTER_CLASS_ENUM (PresentationInfo, Auditioner);
REGISTER_CLASS_ENUM (PresentationInfo, Hidden);
REGISTER_CLASS_ENUM (PresentationInfo, OrderSet);
+ REGISTER_CLASS_ENUM (PresentationInfo, ListenBus);
REGISTER_BITS (_PresentationInfo_Flag);
REGISTER_CLASS_ENUM (MusicalMode,Dorian);
diff --git a/libs/ardour/presentation_info.cc b/libs/ardour/presentation_info.cc
index 23d82f6409..889a94d7dc 100644
--- a/libs/ardour/presentation_info.cc
+++ b/libs/ardour/presentation_info.cc
@@ -112,7 +112,7 @@ PresentationInfo::send_static_change (const PropertyChange& what_changed)
}
const PresentationInfo::order_t PresentationInfo::max_order = UINT32_MAX;
-const PresentationInfo::Flag PresentationInfo::Bus = PresentationInfo::Flag (PresentationInfo::AudioBus|PresentationInfo::MidiBus);
+const PresentationInfo::Flag PresentationInfo::Bus = PresentationInfo::Flag (PresentationInfo::AudioBus|PresentationInfo::MidiBus|PresentationInfo::ListenBus);
const PresentationInfo::Flag PresentationInfo::Track = PresentationInfo::Flag (PresentationInfo::AudioTrack|PresentationInfo::MidiTrack);
const PresentationInfo::Flag PresentationInfo::Route = PresentationInfo::Flag (PresentationInfo::Bus|PresentationInfo::Track);
const PresentationInfo::Flag PresentationInfo::AllRoutes = PresentationInfo::Flag (PresentationInfo::Route|PresentationInfo::MasterOut|PresentationInfo::MonitorOut);
diff --git a/libs/ardour/session.cc b/libs/ardour/session.cc
index da4421d4a2..50e5825f68 100644
--- a/libs/ardour/session.cc
+++ b/libs/ardour/session.cc
@@ -3257,6 +3257,8 @@ Session::new_audio_route (int input_channels, int output_channels, RouteGroup* r
StateProtector sp (this);
if (Profile->get_trx()) {
add_routes (ret, false, false, false, order);
+ } else if (flags == PresentationInfo::ListenBus) {
+ add_routes (ret, false, false, true, order); // no autoconnect
} else {
add_routes (ret, false, true, true, order); // autoconnect // outputs only
}