mgba-emu / mgba

mGBA Game Boy Advance Emulator
https://mgba.io/
Mozilla Public License 2.0
5.38k stars 744 forks source link

fix hang in AudioDevice #3174

Closed oltolm closed 1 month ago

oltolm commented 1 month ago

So I tried the latest version e3edca1f4168c1eee36cd213ef8d5e91fd35e400 and games do not boot they just hang. This is my attempt to fix it. I don't know if it is correct, but it actually works. Games boot and are playable.

endrift commented 1 month ago

Unfortunately it does not seem to work on my machine and hangs instead.

endrift commented 1 month ago

I think I forgot to mention that this doesn't work if I revert my hack. It looks like I only said that your version doesn't break the hack if the hack is left in place.

Which audio backend are you using for Qt Multimedia? I think your change may only fix it in some. In the build I have for Linux it uses PulseAudio, which seems like it will just stall out regardless and doesn't care about if it's sequential or not, hence why I added the hack initially. Your fix may fix other backends I didn't test with.

oltolm commented 1 month ago

I use the Qt6 FFMPEG backend on Windows. On Linux there are two backends: FFMPEG and gstreamer. You are probably using gstreamer.

I re-reverted the hack and with my change it works for me.