Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

frames_queued and total_output_latency_frames may not update in a synchronized fashion #108

Open
mstange opened this issue Jul 29, 2020 · 0 comments

Comments

@mstange
Copy link
Contributor

mstange commented Jul 29, 2020

frames_queued is in the TripleBuffer, but total_output_latency_frames is not (it's a separate atomic), so position() might be using two values from different invocations to the audio output callback. This is probably not a big problem in practice, because total_output_latency_frames probably does not vary very much if the audio callback is called at consistent times. But it's probably still worth fixing, by moving total_output_latency_frames into the TripleBuffer.

@mstange mstange changed the title frames_queued and total_output_latency_frames may not update in a synchronized function frames_queued and total_output_latency_frames may not update in a synchronized fashion Jul 29, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant