Open dmitrykos opened 1 week ago
Confirming, this fixes the issue with the buggy? Realtek driver.
@arkadijs thank you very much for testing. Now let's wait for a review from @RossBencina and @philburk to get this PR approved.
I have not tested it, but it looks OK. my main concern would be whether this could introduce a regression on other drivers. is it passing the PortAudio
pa_loopback
tests?
Great that you mentioned it! I modified workaround to exclude Input mode as this driver bug is related to Output only.
As to pa_loopback
- it fails for WASAPI on [Loopback] device because of this #935 issue - when there is no audio sent to WASAPI internal mixer from some opened audio streams the attempt to read data from [Loopback] device will timeout i.e. PaQa_RunInputOnly()
fails. But it has nothing to do with workaround of this PR - tested.
I propose to discuss the timeout of [Loopback] WASAPI device in #935, there we can also discuss whether a workaround needed in pa_loopback
implementation for loopback devices which timeout without audio data collected from other opened audio streams, or perhaps PA WASAPI needs some workaround for this specific behavior.
This PR looks ok for me to commit.
Workaround for the Realtek driver bug when driver mistakenly accepts Mono format with
IAudioClient_IsFormatSupported()
while subsequently fails inIAudioClient_Initialize()
.It is a long-lasting issue #875 which was resolved with a kind debugging help by @arkadijs.
Closes #875.