wasapisrc - does not drain devices of buffers when reading leading to dropped audio
Submitted by Florian Nierhaus
Link to original bug (#797345)
Description
Created attachment 374068
patch for wasapi against master
There are a few issues with the buffer handling:
- we sometimes get notified when smaller number of frames are provided by the driver - in this case we need to buffer and wait so gstreamer gets the expected size
- we sometimes get multiple buffers with one notification and we need to save that and return that the next cycle as to not have audio gaps - https://blogs.msdn.microsoft.com/matthew_van_eerde/2014/11/05/draining-the-wasapi-capture-buffer-fully/
- not clearing the audio buffer on some devices on the notification / partial sizes confuses some devices
Patch 374068, "patch for wasapi against master":
wasapi_buffers.patch