mpv-player / mpv-player/mpv

Audio playback does not return when the only audio device reappers

Open
#11,192 7 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

os:win
Dominant language
C
Stars
37k
Forks
3.5k
Avg merge
1d 10h
Merged PRs (30d)
22

Description

Important Information

Provide following Information:

  • mpv version: 0.35.0-111-g6cdce9e18e
  • Windows Version: Windows 10
  • Source of the mpv binary: Sourceforge downloads (exact directory)
  • If known which version of mpv introduced the problem: unknown
  • Possible screenshot or video of visual glitches: no visual glitches
Reproduction steps

The following steps are reproducible on my system with the --no-config option:

  1. Start mpv with a video file that has an audio track
  2. Make sure you hear the audio
  3. Disconnect or disable all of your audio devices
    You can see a list of available audio devices and disable them in the Sound utility of the old control panel. You can open it with exeting this in the shell: control mmsys.cpl sounds
  4. Connect an audio device
Expected behavior

Audio is playing through the connected device

Actual behavior

Audio is not playing through the connected device

Log file

https://gist.github.com/mpeter50/d19cb6fe940b5c3ba5229ef69d6c436a

Additional information

It does not matter if you pause playback before disconnecting the last device, and only resume it after connecting one.

If you start mpv without any media to be played and no available audio devices, but you connect an audio device before you drop a media file on the main window, audio playback will work as expected.

After executing the steps listed in reproduction steps, if I try to switch audio device with the help of this script and pressing Shift+A or Ctrl+A, I see the OSD printing the name of my primary audio playback device, but playback does not resume.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the issue on Windows 10 with mpv 0.35.0-111-g6cdce9e18e using --no-config, then inspect the linked log and the audio-device disconnect/reconnect path. Done means audio resumes through the reconnected device, including when playback was paused and when switching devices with the linked script.

Written by the indexing model from the issue text.

Assessment

Tech stack
c
Domain
audio-video-rtc
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.