mpv-player / mpv-player/mpv

toggling vavpp=deint during playback doesn't work on AMD

Open
#7,388 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

down-upstream:amd down-upstream:mesa
Dominant language
C
Stars
37k
Forks
3.5k
Avg merge
1d 10h
Merged PRs (30d)
22

Description

Important Information

mpv 0.31.0-83-ge666546910
self-compiled build
Arch vanilla kernel 5.4.14
mesa git-master eb7cd575da02f3ae60d05112ca86ce6c2cd27e3c
RX 570

Reproduction steps

In input.conf, set up d vf toggle vavpp=deint=auto. Open the interlaced sample file via mpv --hwdec=vaapi sample.mkv and press d to toggle vavpp deinterlacing.

Expected behavior

It should enable vavpp deinterlacing, like it does on Intel.

Actual behavior

On AMD, it fails with

[vavpp] vaRenderPicture() failed (invalid VASurfaceID)
[vavpp] failed to output frame
Disabling filter vavpp.00 because it has failed.

Note: Unlike before, there shouldn't be no driver crashes anymore with AMD GPU, Linux 5.4.14 and recent mesa git-master. At least I couldn't make it crash once. It likely still crashes with older versions though, especially mesa.

Workaround:
Reload the file when toggling vavpp, then it works for some reason:
d loadfile "${path}" ; vf toggle vavpp=deint=auto

Plan is to report it to mesa if it's really a driver bug.

Log file

output.txt

Sample files

https://0x0.st/irt-.mkv

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce with input.conf, mpv --hwdec=vaapi, the linked interlaced sample, and the output.txt log; compare toggling during playback with the reload workaround. Trace the vavpp filter and VA-API path around the invalid VASurfaceID failure, and confirm that toggling enables deinterlacing without disabling the filter or requiring a reload.

Written by the indexing model from the issue text.

Assessment

Tech stack
c, linux
Domain
backend, cli
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.