#6513 closed defect (fixed)

FFmpeg VAAPI hwaccel decode -> hwupload/hwdownload -> x264 will block

Reported by: mypopy Owned by:
Priority: important Component: avfilter
Version: git-master Keywords:
Cc: sw@jkqxz.net Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no


Summary of the bug:
How to reproduce:

% ffmpeg -vaapi_device /dev/dri/renderD128 -hwaccel vaapi -hwaccel_output_format vaapi -i input.mp4 -vf 'format=nv12|vaapi,hwupload,scale_vaapi=w=1280:h=720:format=yuv420p,hwdownload' -c:v libx264 output.mp4
ffmpeg version : master branch (f1baafa)

Patches should be submitted to the ffmpeg-devel mailing list and not this bug tracker.

Change History (3)

comment:1 Changed 13 months ago by jkqxz

I've seen this too a few times - seems to be something in libavfilter to do with format negotiation around the hw* filters, but I've never pursued it beyond that. You can work around it by specifying the formats explicitly (i.e. add 'format=yuv420p' to the end of your filter graph).

comment:2 Changed 13 months ago by mypopy

The work around is working, tks, Mark. BTW: libav is ok in this case.

comment:3 Changed 12 months ago by jkqxz

  • Resolution set to fixed
  • Status changed from new to closed

The hang is fixed by 8a442d7a8a687a469ca502a18a0c68f5302b15e0. The command line above works sensibly with that, but there are still cases where additional format filters are necessary to stop it making bad choices (though they do at least fail immediately now rather than hanging).

Note: See TracTickets for help on using tickets.