xsquawkbox / AFV-Native

AFV-Native client library
Other
9 stars 2 forks source link

pulseaudio via libsoundio buffer underruns and fails to produce sound #1

Closed kuroneko closed 4 years ago

kuroneko commented 4 years ago

Debugging I've just added has revealed that the no audio problem with pulse is being caused by buffer underruns - despite accepting our 20ms buffer and not demanding a longer write, pulse underruns, and underruns even with our SineSource which is a really bad sign.

Need to implement dynamic buffer scaling so we can coalesce the 20ms buffers into longer write groups when we have an output underflow just to deal with PulseAudio and potentially also for slower machines.

kuroneko commented 4 years ago

Turned out I miscalculated the buffer size which was causing the underruns.