From 061d44feff54c0b1bf746fa7d51710340a39c9e7 Mon Sep 17 00:00:00 2001 From: Robin Gareus Date: Thu, 13 Oct 2022 17:39:55 +0200 Subject: [PATCH] PortInsert: remove old API to query latency --- libs/ardour/ardour/port_insert.h | 1 - libs/ardour/port_insert.cc | 17 ----------------- 2 files changed, 18 deletions(-) diff --git a/libs/ardour/ardour/port_insert.h b/libs/ardour/ardour/port_insert.h index 9fb7131853..375c4a04d9 100644 --- a/libs/ardour/ardour/port_insert.h +++ b/libs/ardour/ardour/port_insert.h @@ -79,7 +79,6 @@ public: MTDM* mtdm () const { return _mtdm; } void set_measured_latency (samplecnt_t); - samplecnt_t latency () const; samplecnt_t measured_latency () const { return _measured_latency; diff --git a/libs/ardour/port_insert.cc b/libs/ardour/port_insert.cc index d1ac24bbab..2e597b692e 100644 --- a/libs/ardour/port_insert.cc +++ b/libs/ardour/port_insert.cc @@ -130,23 +130,6 @@ PortInsert::set_measured_latency (samplecnt_t n) _measured_latency = n; } -samplecnt_t -PortInsert::latency() const -{ - /* because we deliver and collect within the same cycle, - all I/O is necessarily delayed by at least samples_per_cycle(). - - if the return port for insert has its own latency, we - need to take that into account too. - */ - - if (_measured_latency == 0) { - return _session.engine().samples_per_cycle() + _input->latency(); - } else { - return _measured_latency; - } -} - void PortInsert::run (BufferSet& bufs, samplepos_t start_sample, samplepos_t end_sample, double speed, pframes_t nframes, bool) {