mpv icon indicating copy to clipboard operation
mpv copied to clipboard

Audio passthrough only works after switching audio tracks

Open Tjoma96 opened this issue 3 months ago • 1 comments

mpv Information

mpv v0.40.0-465-gf6c116491 Copyright © 2000-2025 mpv/MPlayer/mplayer2 projects
 built on Nov 22 2025 12:10:06
libplacebo version: v7.357.0 (v7.351.0-90-g2e5a392-dirty)
FFmpeg version: N-121825-g3cc1dc335
FFmpeg library versions:
   libavcodec      62.19.100
   libavdevice     62.2.100
   libavfilter     11.9.100
   libavformat     62.6.103
   libavutil       60.18.100
   libswresample   6.2.100
   libswscale      9.3.100

Other Information

- Windows version: [Version 10.0.26100.7171]
- GPU model, driver and version: NVIDIA RTX 3060, driver ver. 581.80
- Source of mpv: https://github.com/zhongfly/mpv-winbuild/releases
- Latest known working version: N/A
- Issue started after the following happened: Enabling audio passthrough in MPV

Reproduction Steps

Add to config: audio-exclusive=yes audio-spdif=ac3,eac3,dts-hd,truehd audio-channels=7.1,5.1,stereo

And play any file containing those formats. MPV will ignore the audio-spdif command and output PCM instead. Switch audio tracks and only then will it recognize the command and correctly output the passthrough format.

Expected Behavior

MPV shows "AO: [wasapi] 192000Hz 7.1 8ch spdif-truehd" and does passthrough.

Actual Behavior

MPV shows "AO: [wasapi] 48000Hz 7.1 8ch s32" and doesn't do passthrough.

Log File

output.txt

Log contains test with TrueHD but I've also confirmed this happens with AC3 & EAC3.

Sample Files

https://www.demolandia.net/downloads.html?id=236762

Contains TrueHD, AC3 & EAC3 audio tracks.

I carefully read all instruction and confirm that I did the following:

  • [x] I tested with the latest mpv version to validate that the issue is not already fixed.
  • [x] I provided all required information including system and mpv version.
  • [x] I produced the log file with the exact same set of files, parameters, and conditions used in "Reproduction Steps", with the addition of --log-file=output.txt.
  • [x] I produced the log file while the behaviors described in "Actual Behavior" were actively observed.
  • [x] I attached the full, untruncated log file.
  • [x] I attached the backtrace in the case of a crash.

Tjoma96 avatar Nov 23 '25 01:11 Tjoma96

Would like to add that I also tested other video players like VLC and MPC-HC and they didn't have this issue, audio passthrough was working as it should there. Only MPV has this issue.

Please fix this. It is very annoying having to switch audio tracks everytime I start playing a video to get the audio passthrough working.

Tjoma96 avatar Dec 02 '25 07:12 Tjoma96

I figured out what the problem was, I had the command "audio-spdif=ac3,eac3,dts-hd,truehd" set inside an auto profile and that was causing the problem. even though the profile was being loaded. Weird. Moving it outside the profile solved the issue and it's now doing audio passthrough as it should right from the start.

If I had to guess its because profiles are loaded last and by the time it happens, MPV had already chosen another audio format.

Tjoma96 avatar Dec 15 '25 02:12 Tjoma96

https://github.com/mpv-player/mpv/pull/17135 should fix this.

kasper93 avatar Dec 15 '25 02:12 kasper93