mpv icon indicating copy to clipboard operation
mpv copied to clipboard

HDMI audio passthrough, alsa errors

Open safdemonte opened this issue 4 years ago • 2 comments

Important Information

Provide following Information:

  • mpv version

mpv 0.33.0 Copyright © 2000-2020 mpv/MPlayer/mplayer2 projects built on Tue Nov 24 01:50:41 UTC 2020 FFmpeg library versions: libavutil 56.60.100 libavcodec 58.112.103 libavformat 58.64.100 libswscale 5.8.100 libavfilter 7.90.100 libswresample 3.8.100 FFmpeg version: git-2020-11-22-9208b72

  • Linux Distribution and Version

Linux Mint 19.3 cinnamon

  • Source of the mpv binary Ubuntu PPA - https://launchpad.net/~mc3man/+archive/ubuntu/mpv-tests

  • If known which version of mpv introduced the problem

the issue begin with current version when switch from SPDIF audio to HDMI audio

  • Window Manager and version

Cinnamon 4.4.8

  • GPU driver and version

Nvidia GT1030 - 460.91.03

Reproduction steps

open a file with mpv with following options

mpv -vo=gpu --gpu-context=x11 --hwdec=auto --ao=alsa --audio-spdif=ac3,eac3,dts-hd,truehd --audio-channels=auto

no sound, if remove --audio-spdif get two channel audio.

Expected behavior

get multichannel audio on AV receiver when playing movie with AC3, EAC3, DTS, etc, audio streams over HDMI the issue arise when change AV receiver and switch audio from SPDIF coaxial to HDMI. before that AC3 and DTS works as it should. if take a look at log file, there's two lines that catch my attention ALSA lib conf.c:4974:(snd_config_expand) Unknown parameters AES0=6,AES1=130,AES2=0,AES3=2 ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM default:AES0=6,AES1=130,AES2=0,AES3=2 when audio works this lines are gone.

Actual behavior

no sound when playing movies, if I remove --audio-spdif=..... get stereo sound

Log file

mpv.log

I have no config file, I use SMPLAYER as front end but the issue appear anyway using mpv from command line. multichannels sound works randomly but never for EAC3 audio stream. VLC play multichannels audio track fine.

Thanks

safdemonte avatar Sep 09 '21 02:09 safdemonte

Did you ever manage to resolve this? I have the exact same issue. Stereo when not specifying spdif (as you'd expect, the PCM output is stereo) but that at least tells us that the alsa is sending the output to to the correct device, but no output at all when using spdif.

I'd love to get this working but whatever I try seems to result in the same thing: No audio when using spdif, it seems to be playing correctly.

TRPB avatar Sep 12 '22 17:09 TRPB

Hi, I could resolve the issue, seems it's not related to mpv. after several days trying different approach with no result and knowing that is something close to audio stack. I decide to install pipewire and disable pulseaudio following this https://salmorejogeek.com/2021/05/09/como-instalar-el-ultimo-pipewire-en-ubuntu-20-04-lts-21-04-y-basadas-y-ponerlo-como-server-de-audio-por-defecto/ is in Spanish as I'm from Argentina but you can find same instruction in English too. after install pipewire and find which audio device match HDMI output of my video card multichannel audio start working flawless, for the first time I could see my AV receiver play E-AC3, dolby trueHD, TDS master audio and so on. Take into account that this issue is related to HDMI pass-through, before that I was able to use spdif but only for ac3 and DTS, all other streams (E-AC3, DTS MA, Dolby HD, etc) has to be converted to ac3.

safdemonte avatar Sep 12 '22 23:09 safdemonte

Allegedly not our issue and was fixed.

Dudemanguy avatar Jan 09 '23 06:01 Dudemanguy

Can this be re-opened? I'm having this issue and I have no clue how to fix it.

mlindner avatar Mar 18 '23 01:03 mlindner

Hi Mlindner, I've started this thread long ago, and after wait for several months I've start digging and after several attempts the way got fixed was removing pulseaudio and installing pipewire, after that I could get all multichannel audio formats over HDMI on my AV receivers. zero issues ever since. Hope this helps. All of this assuming you are using linux.

Best regards

Sandro

El vie, 17 mar 2023 a la(s) 22:55, mlindner @.***) escribió:

Can this be re-opened? I'm having this issue and I have no clue how to fix it.

— Reply to this email directly, view it on GitHub https://github.com/mpv-player/mpv/issues/9197#issuecomment-1474579057, or unsubscribe https://github.com/notifications/unsubscribe-auth/AU6FRMHLNBSM4PA4I2IPWWDW4UIY5ANCNFSM5DWCTRVQ . You are receiving this because you authored the thread.Message ID: @.***>

safdemonte avatar Mar 18 '23 18:03 safdemonte