More non-rt calls to VCA - fixes VCA automation writing
authorRobin Gareus <robin@gareus.org>
Fri, 21 Jul 2017 21:07:51 +0000 (23:07 +0200)
committerRobin Gareus <robin@gareus.org>
Fri, 21 Jul 2017 21:07:51 +0000 (23:07 +0200)
This calls for a unified API to invoke
Automatable methods  ::transport_located() and ::transport_stopped()
on Stripables,  rather than indirectly calling it via
Route::non_realtime_locate(), Route::nonrealtime_handle_transport_stopped()

libs/ardour/session_transport.cc

index faf6458b16677b4103aebb51790008a099c8277a..4ee294557982625005c9785fbd4519cd15ab4293 100644 (file)
@@ -454,7 +454,10 @@ Session::butler_transport_work ()
                        }
                        (*i)->non_realtime_locate (_transport_frame);
                }
-
+               VCAList v = _vca_manager->vcas ();
+               for (VCAList::const_iterator i = v.begin(); i != v.end(); ++i) {
+                       (*i)->transport_located (_transport_frame);
+               }
        }
 
        if (ptw & PostTransportAdjustCaptureBuffering) {
@@ -503,6 +506,10 @@ Session::butler_transport_work ()
                                        goto restart;
                                }
                        }
+                       VCAList v = _vca_manager->vcas ();
+                       for (VCAList::const_iterator i = v.begin(); i != v.end(); ++i) {
+                               (*i)->transport_located (_transport_frame);
+                       }
                }
        }
 
@@ -608,6 +615,12 @@ Session::non_realtime_locate ()
                        (*i)->non_realtime_locate (_transport_frame);
                }
        }
+       {
+               VCAList v = _vca_manager->vcas ();
+               for (VCAList::const_iterator i = v.begin(); i != v.end(); ++i) {
+                       (*i)->transport_located (_transport_frame);
+               }
+       }
 
        _scene_changer->locate (_transport_frame);
 
@@ -888,6 +901,13 @@ Session::non_realtime_stop (bool abort, int on_entry, bool& finished)
                }
        }
 
+       {
+               VCAList v = _vca_manager->vcas ();
+               for (VCAList::const_iterator i = v.begin(); i != v.end(); ++i) {
+                       (*i)->transport_located (_transport_frame);
+               }
+       }
+
        have_looped = false;
 
        /* don't bother with this stuff if we're disconnected from the engine,