move creation of Graph till after we have the engine running, since we need access...
authorPaul Davis <paul@linuxaudiosystems.com>
Sat, 14 Sep 2013 20:17:24 +0000 (16:17 -0400)
committerPaul Davis <paul@linuxaudiosystems.com>
Sat, 14 Sep 2013 20:17:24 +0000 (16:17 -0400)
libs/ardour/session_state.cc

index 7914b215655e56ea3ccec34082cc043aa616930c..e847ba45ce215a5d5926b3190c304c4f706ee6f7 100644 (file)
@@ -177,13 +177,6 @@ Session::pre_engine_init (string fullpath)
 
        set_history_depth (Config->get_history_depth());
        
-       if (how_many_dsp_threads () > 1) {
-               /* For now, only create the graph if we are using >1 DSP threads, as
-                  it is a bit slower than the old code with 1 thread.
-               */
-               _process_graph.reset (new Graph (*this));
-       }
-
         /* default: assume simple stereo speaker configuration */
 
         _speakers->setup_default_speakers (2);
@@ -217,6 +210,13 @@ Session::post_engine_init ()
        set_block_size (_engine.samples_per_cycle());
        set_frame_rate (_engine.sample_rate());
 
+       if (how_many_dsp_threads () > 1) {
+               /* For now, only create the graph if we are using >1 DSP threads, as
+                  it is a bit slower than the old code with 1 thread.
+               */
+               _process_graph.reset (new Graph (*this));
+       }
+
        n_physical_outputs = _engine.n_physical_outputs ();
        n_physical_inputs =  _engine.n_physical_inputs ();