mpv-player / mpv-examples

📚
224 stars 77 forks source link

Audio output initialization failed... #12

Closed FlyingCircus- closed 4 years ago

FlyingCircus- commented 6 years ago

Hello. I had some problems while running a C# implementation of libmpv in some systems with no audio output deviced connected (no internal or external speakers/headphones). The videos weren't playing and I got the following log: [ 0.171][e][ao/wasapi] There are no playback devices available ... [ 0.177][v][cplayer] finished playback, audio output initialization failed (reason 4)

This issue could be avoided by running the player with the sound disabled ("audio" option set to "no"). However, I find strange that the expected behaviour when the player doesn't find any audio output device is to stop the playback instead of playing it without sound. In fact that's what happens if you use the "mpv.exe" instead of the libmpv implementation. I guess this is more of a suggestion than an actual issue.

ghost commented 6 years ago

This is because libmpv has the stop-playback-on-init-failure option enabled by default. You can disable it. Feel free to suggest changing the default on the mpv issue tracker.