[FFmpeg-devel] [PATCH] videotoolbox: allow to enable the async decoding.

Hendrik Leppkes h.leppkes at gmail.com
Sun Aug 9 13:19:04 CEST 2015


On Sun, Aug 9, 2015 at 1:11 PM, Sebastien Zwickert <dilaroga at gmail.com> wrote:
> This patch allows to use the Videotoolbox API in asynchonous mode.
> Note that when using async decoding the user is responsible for
> releasing the async frame.
> Moreover, an option called videotoolbox_async was added to enable
> async decoding with ffmpeg CLI.
>

I'm not sure about your approach. I can already see you getting loads
of problems with frame order. pts is not guaranteed to be present or
reliable, and using it for re-ordering your async frames is probably
unreliable at best.
avcodec does proper re-ordering, and the only reliable way would be to
somehow manage to associate the AVFrame avcodec is going to output
with your async frame, so that you can trust avcodecs re-ordering.

Isnt there a way to put a "handle" to the async frame into the AVFrame
somehow, which can then be used by the user code to get it from VT?

- Hendrik


More information about the ffmpeg-devel mailing list