summaryrefslogtreecommitdiff
path: root/drumgizmo/output/jackaudio.h
diff options
context:
space:
mode:
authorBent Bisballe Nyeng <deva@aasimon.org>2016-07-13 11:25:59 +0200
committerBent Bisballe Nyeng <deva@aasimon.org>2016-07-13 11:25:59 +0200
commit633bac9e82aef192a803666aaf3d3dcff920ac0c (patch)
treeb4b253162c0dcdbace27807e11e5915ebce1cfab /drumgizmo/output/jackaudio.h
parent7557e5d1713337f4acc3f531e5b88a1195476eec (diff)
Use the latency reported by the engine in the jack and wavfile output modules.
Diffstat (limited to 'drumgizmo/output/jackaudio.h')
-rw-r--r--drumgizmo/output/jackaudio.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/drumgizmo/output/jackaudio.h b/drumgizmo/output/jackaudio.h
index 324e95a..b8fbcab 100644
--- a/drumgizmo/output/jackaudio.h
+++ b/drumgizmo/output/jackaudio.h
@@ -49,11 +49,14 @@ public:
void post(size_t nsamples) override;
size_t getBufferSize() const override;
size_t getSamplerate() const override;
+ void onLatencyChange(std::size_t latency) override;
// based on JackProcess
void process(jack_nframes_t num_frames) override;
+ void jackLatencyCallback(jack_latency_callback_mode_t mode) override;
private:
+
struct Channel
{
JackPort port;
@@ -66,4 +69,5 @@ private:
JackClient& client;
std::vector<Channel> channels;
Semaphore sema;
+ std::size_t latency{0};
};