Clean up BusProfile:
authorRobin Gareus <robin@gareus.org>
Tue, 15 Aug 2017 18:38:24 +0000 (20:38 +0200)
committerRobin Gareus <robin@gareus.org>
Tue, 15 Aug 2017 22:51:20 +0000 (00:51 +0200)
 * requested_physical_in/out was unused
 * input/output Autoconnect just overrides Preference/Config
   (can be done by a template script)
 * master_out_channels is kept for compatibility (allow to create
   new empty session)

libs/ardour/ardour/types.h
libs/ardour/session_state.cc

index 7a0c5762b720d2de593033c8b5b0178e56609a69..854fb04066691349cf574531cb075b1b08c59b3d 100644 (file)
@@ -625,11 +625,7 @@ namespace ARDOUR {
        };
 
        struct BusProfile {
-               AutoConnectOption input_ac;      /* override the RC config for input auto-connection */
-               AutoConnectOption output_ac;     /* override the RC config for output auto-connection */
-               uint32_t master_out_channels;    /* how many channels for the master bus */
-               uint32_t requested_physical_in;  /* now many of the available physical inputs to consider usable */
-               uint32_t requested_physical_out; /* now many of the available physical inputs to consider usable */
+               uint32_t master_out_channels; /* how many channels for the master bus, 0: no master bus */
        };
 
        enum FadeShape {
index 5e1525dbed5bb198b68fbee243f9d000d6b26e8d..b0b8a46a4b506a59654315f63e744cfef49c62a4 100644 (file)
@@ -657,7 +657,6 @@ Session::create (const string& session_template, BusProfile* bus_profile)
        /* set up Master Out and Monitor Out if necessary */
 
        if (bus_profile) {
-
                RouteList rl;
                ChanCount count(DataType::AUDIO, bus_profile->master_out_channels);
 
@@ -678,29 +677,11 @@ Session::create (const string& session_template, BusProfile* bus_profile)
 
                        rl.push_back (r);
 
-               } else {
-                       /* prohibit auto-connect to master, because there isn't one */
-                       bus_profile->output_ac = AutoConnectOption (bus_profile->output_ac & ~AutoConnectMaster);
                }
 
                if (!rl.empty()) {
                        add_routes (rl, false, false, false, PresentationInfo::max_order);
                }
-
-               // Waves Tracks: Skip this. Always use autoconnection for Tracks
-               if (!ARDOUR::Profile->get_trx()) {
-
-                       /* this allows the user to override settings with an environment variable.
-                       */
-
-                       if (no_auto_connect()) {
-                               bus_profile->input_ac = AutoConnectOption (0);
-                               bus_profile->output_ac = AutoConnectOption (0);
-                       }
-
-                       Config->set_input_auto_connect (bus_profile->input_ac);
-                       Config->set_output_auto_connect (bus_profile->output_ac);
-               }
        }
 
        if (Config->get_use_monitor_bus() && bus_profile) {