View Issue Details

IDProjectCategoryView StatusLast Update
0004758ardourbugspublic2015-09-18 15:19
Reportercolinf Assigned Tocth103  
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
Summary0004758: [PATCH] Auto-connect of bus outputs doesn't work
DescriptionWhen I create a bus, its outputs don't get connected to anything, regardless of the auto-connect settings. New tracks do auto-connect as expected, to the master bus or hardware outputs.
Additional InformationSeems like this was an (unintended) consequence of r9988, which was intended to disable auto-connecting of physical inputs to buses, but actually disabled auto-connect of both inputs and outputs.

Attached a patch to separate the auto_connect parameter of Session::add_routes() into input_auto_connect and output_auto_connect, and use it appropriately to only auto-connect outputs of buses.
TagsNo tags attached.

Activities

2012-03-06 19:12

 

auto-connect-bus-outputs.patch (2,790 bytes)   
Index: libs/ardour/session.cc
===================================================================
--- libs/ardour/session.cc	(revision 11605)
+++ libs/ardour/session.cc	(working copy)
@@ -673,7 +673,7 @@
 	}
 
 	rl.push_back (r);
-	add_routes (rl, false, false);
+	add_routes (rl, false, false, false);
 	
 	assert (_monitor_out);
 
@@ -1646,7 +1646,7 @@
 
   failed:
 	if (!new_routes.empty()) {
-		add_routes (new_routes, true, true);
+		add_routes (new_routes, true, true, true);
 
 		if (instrument) {
 			for (RouteList::iterator r = new_routes.begin(); r != new_routes.end(); ++r) {
@@ -1889,7 +1889,7 @@
 
   failed:
 	if (!new_routes.empty()) {
-		add_routes (new_routes, true, true);
+		add_routes (new_routes, true, true, true);
 	}
 
 	return ret;
@@ -2001,7 +2001,7 @@
 
   failure:
 	if (!ret.empty()) {
-		add_routes (ret, false, true);
+		add_routes (ret, false, true, true); // autoconnect outputs only
 	}
 
 	return ret;
@@ -2100,7 +2100,7 @@
 
   out:
 	if (!ret.empty()) {
-		add_routes (ret, true, true);
+		add_routes (ret, true, true, true);
 		IO::enable_connecting ();
 	}
 
@@ -2108,7 +2108,7 @@
 }
 
 void
-Session::add_routes (RouteList& new_routes, bool auto_connect, bool save)
+Session::add_routes (RouteList& new_routes, bool input_auto_connect, bool output_auto_connect, bool save)
 {
         ChanCount existing_inputs;
         ChanCount existing_outputs;
@@ -2165,8 +2165,8 @@
 			}
 		}
 
-		if (auto_connect) {
-			auto_connect_route (r, existing_inputs, existing_outputs, true);
+		if (input_auto_connect || output_auto_connect) {
+			auto_connect_route (r, existing_inputs, existing_outputs, true, input_auto_connect);
 		}
 	}
 
Index: libs/ardour/session_state.cc
===================================================================
--- libs/ardour/session_state.cc	(revision 11605)
+++ libs/ardour/session_state.cc	(working copy)
@@ -605,7 +605,7 @@
 		}
 
 		if (!rl.empty()) {
-			add_routes (rl, false, false);
+			add_routes (rl, false, false, false);
 		}
 
                 /* this allows the user to override settings with an environment variable.
@@ -1473,7 +1473,7 @@
 		new_routes.push_back (route);
 	}
 
-	add_routes (new_routes, false, false);
+	add_routes (new_routes, false, false, false);
 
 	return 0;
 }

Index: libs/ardour/ardour/session.h
===================================================================
--- libs/ardour/ardour/session.h	(revision 11605)
+++ libs/ardour/ardour/session.h	(working copy)
@@ -1224,7 +1224,7 @@
 
 	SerializedRCUManager<RouteList>  routes;
 
-	void add_routes (RouteList&, bool auto_connect, bool save);
+	void add_routes (RouteList&, bool input_auto_connect, bool output_auto_connect, bool save);
 	uint32_t destructive_index;
 
 	boost::shared_ptr<Route> XMLRouteFactory (const XMLNode&, int);
auto-connect-bus-outputs.patch (2,790 bytes)   

cth103

2012-03-07 13:24

administrator   ~0012871

Applied to SVN 11615. Thanks!

colinf

2015-09-18 15:19

updater   ~0017304

Closing old issues reported by me: these have long since been fixed.

Issue History

Date Modified Username Field Change
2012-03-06 19:12 colinf New Issue
2012-03-06 19:12 colinf File Added: auto-connect-bus-outputs.patch
2012-03-07 13:24 cth103 cost => 0.00
2012-03-07 13:24 cth103 Note Added: 0012871
2012-03-07 13:24 cth103 Status new => resolved
2012-03-07 13:24 cth103 Resolution open => fixed
2012-03-07 13:24 cth103 Assigned To => cth103
2015-09-18 15:19 colinf Note Added: 0017304
2015-09-18 15:19 colinf Status resolved => closed