[vlc-devel] [PATCH 0/4] Asynchronous decoder Queue functions and MediaCodec
thomas at gllm.fr
Thu Dec 3 10:51:22 CET 2015
* About Decoder:
Last time I proposed an asynchronous decoder patch (see
there were few issues on the core:
The 2/ issue about changing fmt_in is fixed: fmt_in won't change during the
decoder module life.
The 1/ issue about fmt_out being the format of following buffer allocations, or
the format of following output buffers is still not fixed. This need to be
fixed but I don't think it's related to decoder_QueueVideo or MediaCodec.
Indeed, Contrary to avcodec-MT, MediaCodec won't keep a decoder picture
internally and will return it directly via decoder_QueueVideo (or was returned
via pf_decode_video before). Therefore, in MediaCodec case, if fmt_out changes,
only the vout will own the pictures that will be reseted.
There is also an issue with input_DecoderFrameNext, FrameNext won't work
properly when using decoder_QueueVideo. input_DecoderFrameNext need to be
rewritten completely to handle asynchronous decoder and input not feed (since
decoder is paused).
decoder_QueueVideo and decoder_QueueAudio will be used by MediaCodec (and
lately by omx and mmal?), but I don't know if decoder_QueueSub is very
useful. I don't know if there will be an asynchronous subtitle decoder one day.
* About MediaCodec:
The fourth commit improves performance on few devices (it depends on the number
of input/output buffers allocated by the OMX Codec) and allows to remove the
following hack in android:
Thomas Guillem (4):
decoder: add decoder_QueueVideo
decoder: add decoder_QueueAudio
decoder: add decoder_QueueSub
mediacodec: add an output thread, remove polling
include/vlc_codec.h | 56 +++++
modules/codec/omxil/mediacodec.c | 526 ++++++++++++++++++++++++---------------
src/input/decoder.c | 239 ++++++++++++------
3 files changed, 541 insertions(+), 280 deletions(-)
More information about the vlc-devel