mpv
mpv copied to clipboard
Profile "low-latency" don't play the audio track
Important Information
Provide following Information:
- mpv version : mpv-x86_64-20220710-git-0044c19
- Windows Version : 10 20H2
- If known which version of mpv introduced the problem. Suspect it happen after a security Windows update.
- Possible screenshot or video of visual glitches
Call : mpv udp://[email protected]:5000 --profile=low-latency --sub-create-cc-track=yes
- Only Video and EAI608 track appear
If i call without "--profile=low-latency". Audio track re-appear again !
VLC works just fine (but not "as fast" as MPV, in therm of delay".
See those message when start from CLI (+) Video --vid=1 (hevc) (+) Subs --sid=1 (*) (eia_608) [ffmpeg] NULL: PPS id out of range: 0 [ffmpeg] NULL: PPS id out of range: 0 [ffmpeg/video] hevc: PPS id out of range: 0 [ffmpeg/video] hevc: Error parsing NAL unit #3. Error while decoding frame! [ffmpeg] NULL: PPS id out of range: 0 [ffmpeg/video] hevc: PPS id out of range: 0 [ffmpeg/video] hevc: Error parsing NAL unit #3. Error while decoding frame! [ffmpeg] NULL: PPS id out of range: 0 [ffmpeg/video] hevc: PPS id out of range: 0 [ffmpeg/video] hevc: Error parsing NAL unit #3. Error while decoding frame! [ffmpeg] NULL: PPS id out of range: 0 [ffmpeg/video] hevc: PPS id out of range: 0 [ffmpeg/video] hevc: Error parsing NAL unit #3. Error while decoding frame! VO: [gpu] 1280x720 yuv420p V: 10:26:05 / 10:26:05 (100%) Cache: 0.1s/5KB
I'm seeing this same exact issue on a new install of Ubuntu 22.04. I was attempting to use a old laptop for a hacky temporary display with one of those cheap generic USB 2.0 HDMI capture cards that have been on the market.
I can get the capture card working at 60fps 1280x720 in obs and use the full screen option. But it seems clunky to use obs when I don't plan to stream anything.
mpv seems to playback the capture card input just fine with "--profile=low-latency" but it doesn't pull the audio I specify.
mpv av://v4l2:/dev/video2 --audio-file=av://pulse:alsa_input.usb-MACROSILICON_2109-02.analog-stereo --demuxer-lavf-o-add=input_format=mjpeg --untimed --profile=low-latency
This command fails to play audio until I omit "--profile=low-latency". But without low-latency the playback becomes slow and choppy.
System Ubuntu 22.04 Gnome 42.2 Wayland/Mutter
mpv 0.34.1
Same behaviour for me too.
The tag should be changed since this appears to affect both Windows and Linux builds
do mpv --show-profile=low-latency
and figure out which option causes issues.
--audio-buffer=0 --vd-lavc-threads=1 --cache-pause=no *** audio start *** but also force the player to start caching (got 1.2 sec buffer at begening) --demuxer-lavf-o-add=fflags=+nobuffer --demuxer-lavf-probe-info=nostreams  *** audio start *** --demuxer-lavf-analyzeduration=0.1 --video-sync=audio  --interpolation=no  --video-latency-hacks=yes --stream-buffer-size=4kÂ
Looking at the manual, it doesn't seem to do anything besides avoiding an avformat_find_stream_info() call. It's probably fine to just set it back to default after applying profile=low-latency.
mpv --profile=low-latency --demuxer-lavf-probe-info=auto
Maybe you could try using a different audio/container format or protocol if you have control over the stream you're trying to watch.
In our case, hard to acheive, as we are using a physical "broadcast" encoder (Haivison Makito X4), where we have not a hudge variety of Codec here. But this card is a low-latency streamer. Typical delay mesured with VLC was approx 230 ms between the input of the card, and the computerscreen of the user
Also noticed that if my stream only contain "black" video sources... MPV can't open it (i notice network activity... same bandwith as the stream ... but MPV can'T open it in low-latency profile). VLC no issue to open it (but the version i'm using doesn't contain any agressive low-latency profile)
Still a problem, and a very annoying one.