aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorPaul Adenot <[email protected]>2023-11-21 10:28:36 +0100
committerPaul Adenot <[email protected]>2023-11-21 11:08:34 +0100
commit5707d0e4477a29e990c90efc2cc41cc186e6fe69 (patch)
tree9aeb809b050d22b9244eccd991a02762390a6428
parent30efcd1cdf8a794e918fe2c6e9b74c8ea8bbcdd6 (diff)
downloadcubeb-5707d0e4477a29e990c90efc2cc41cc186e6fe69.tar.gz
cubeb-5707d0e4477a29e990c90efc2cc41cc186e6fe69.zip
Fix latency reporting on OpenSL
-rw-r--r--src/cubeb_opensl.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/cubeb_opensl.cpp b/src/cubeb_opensl.cpp
index 916d7da..8725173 100644
--- a/src/cubeb_opensl.cpp
+++ b/src/cubeb_opensl.cpp
@@ -1891,8 +1891,10 @@ opensl_stream_get_latency(cubeb_stream * stm, uint32_t * latency)
uint32_t stream_latency_frames =
stm->user_output_rate * stm->output_latency_ms / 1000;
- return static_cast<int>(stream_latency_frames +
- cubeb_resampler_latency(stm->resampler));
+ *latency = static_cast<int>(stream_latency_frames +
+ cubeb_resampler_latency(stm->resampler));
+
+ return CUBEB_OK;
}
int