<div dir="ltr"><div><div>Hi everyone,<br><br></div>First, i am new to PulseAudio and the mailing list, so let me say it: Thank you all !<br><br>In the context of my application, it is important to accurately estimate the audio latency in order to synchronize the speaker output with some motor movements.<br><div><div><br>I used to query the audio latency using pa_stream_get_latency(), but the returned information does not seems to correspond to observed latency in the following situation:<br><br>When my application stops sending data (after the underflow event), the value returned by pa_stream_get_latency() stays constant and does not decrease.<br><br>When writing again data into the stream (long after the underflow event and without any cork/uncork operation), the sound is outputted to the speaker without the latency delay advertised by pa_stream_get_latency().<br><br>Since this is the first time i use the PulseAudio API, i might not understand correctly the purpose of pa_stream_get_latency() and I wonder what is the correct way to obtain the most accurate estimation of the latency ?</div><div><br></div><div><br></div><div>Thank you very much,</div><div><br></div><div><br></div><div>Ludovic<br></div></div></div></div>