Skip to content

Commit

Permalink
vd_lavc: don't hardware decode VC-1 by default
Browse files Browse the repository at this point in the history
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.
  • Loading branch information
guidocella committed Jan 25, 2025
1 parent 04c328f commit 7416837
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
1 change: 1 addition & 0 deletions DOCS/interface-changes/vc1.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
change `hwdec-codecs` default from `h264,vc1,hevc,vp8,vp9,av1,prores` to `h264,hevc,vp8,vp9,av1,prores`
6 changes: 3 additions & 3 deletions DOCS/man/options.rst
Original file line number Diff line number Diff line change
Expand Up @@ -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.
Expand Down
2 changes: 1 addition & 1 deletion video/decode/vd_lavc.c
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down

0 comments on commit 7416837

Please sign in to comment.