From 7416837cf55be2a12f3c943795bd149c64158e38 Mon Sep 17 00:00:00 2001 From: Guido Cella Date: Sat, 25 Jan 2025 16:38:13 +0100 Subject: [PATCH] vd_lavc: don't hardware decode VC-1 by default We have reports of VC-1 videos showing a green screen on both nvdec and vaapi, and new AMD GPUs don't support it all. Also there is no need to hardware decode VC-1 videos since nobody produces 4k VC-1 videos. So remove it from the default hwdec-codecs. Fixes #15715. --- DOCS/interface-changes/vc1.txt | 1 + DOCS/man/options.rst | 6 +++--- video/decode/vd_lavc.c | 2 +- 3 files changed, 5 insertions(+), 4 deletions(-) create mode 100644 DOCS/interface-changes/vc1.txt diff --git a/DOCS/interface-changes/vc1.txt b/DOCS/interface-changes/vc1.txt new file mode 100644 index 0000000000000..7fd09e00b1577 --- /dev/null +++ b/DOCS/interface-changes/vc1.txt @@ -0,0 +1 @@ +change `hwdec-codecs` default from `h264,vc1,hevc,vp8,vp9,av1,prores` to `h264,hevc,vp8,vp9,av1,prores` diff --git a/DOCS/man/options.rst b/DOCS/man/options.rst index 79576c736c3fd..475615812b29f 100644 --- a/DOCS/man/options.rst +++ b/DOCS/man/options.rst @@ -1787,9 +1787,9 @@ Video You can get the list of allowed codecs with ``mpv --vd=help``. Remove the prefix, e.g. instead of ``lavc:h264`` use ``h264``. - By default, this is set to ``h264,vc1,hevc,vp8,vp9,av1,prores``. Note that - the hardware acceleration special codecs like ``h264_vdpau`` are not - relevant anymore, and in fact have been removed from FFmpeg in this form. + By default, this is set to ``h264,hevc,vp8,vp9,av1,prores``. Note that the + hardware acceleration special codecs like ``h264_vdpau`` are not relevant + anymore, and in fact have been removed from FFmpeg in this form. This is usually only needed with broken GPUs, where a codec is reported as supported, but decoding causes more problems than it solves. diff --git a/video/decode/vd_lavc.c b/video/decode/vd_lavc.c index 0a69ba4f3ec17..3bcac450d8b53 100644 --- a/video/decode/vd_lavc.c +++ b/video/decode/vd_lavc.c @@ -140,7 +140,7 @@ const struct m_sub_options vd_lavc_conf = { .framedrop = AVDISCARD_NONREF, .dr = -1, .hwdec_api = (char *[]){"no", NULL,}, - .hwdec_codecs = "h264,vc1,hevc,vp8,vp9,av1,prores", + .hwdec_codecs = "h264,hevc,vp8,vp9,av1,prores", // Maximum number of surfaces the player wants to buffer. This number // might require adjustment depending on whatever the player does; // for example, if vo_gpu increases the number of reference surfaces for