Changeset f611fef3 in ffmpeg
- Timestamp:
-
Feb 19, 2018, 2:27:34 PM
(7 years ago)
- Author:
- Matthieu Bouron <matthieu.bouron@gmail.com>
- Branches:
- master
- Children:
- 6d8bef8c
- Parents:
- 56f77b0f
- git-author:
- Aman Gupta <aman@tmm1.net> (02/16/18 03:52:14)
- git-committer:
- Matthieu Bouron <matthieu.bouron@gmail.com> (02/19/18 14:27:34)
- Message:
-
avcodec/mediacodecdec: refactor to take advantage of new decoding api
This refactor splits up the main mediacodec decode loop into two
send/receive helpers, which are then used to rewrite the receive_frame
callback and take full advantage of the new decoding api. Since we
can now request packets on demand with ff_decode_get_packet(), the
fifo buffer is no longer necessary and has been removed.
This change was motivated by behavior observed on certain Android TV
devices, featuring hardware mpeg2/h264 decoders which also deinterlace
content (to produce multiple frames per field). Previously, this code
caused buffering issues because queueInputBuffer() was always invoked
before each dequeueOutputBuffer(), even though twice as many output
buffers were being generated.
With this patch, the decoder will always attempt to drain new frames
first before sending more data into the underlying codec.
Signed-off-by: Matthieu Bouron <matthieu.bouron@gmail.com>
-
(No files)
-