FFMPEG plugin: Tell the FFMPEG library to handle incomplete data.

- It is just one flag that needs to be set, so that streaming video data can be
  handled by the FFMPEG library.

- For reference: This flag is based on FFMPEG's 0.10.2 video decode example
  (doc/example/decoding_encoding.c).

- The _DecodeNextVideoFrame() method needs to be adjusted (still to come), to
  take streamed data into account. So the flag on its own doesn't help, but it
  is a reasonable step in that direction.

Signed-off-by: Colin Günther <coling@gmx.de>
This commit is contained in:
Colin Günther 2014-07-15 23:31:54 +02:00
parent 0adda4f68f
commit 70a9edbb11

View File

@ -430,6 +430,11 @@ AVCodecDecoder::_NegotiateVideoOutputFormat(media_format* inOutFormat)
fContext->extradata = (uint8_t*)fExtraData;
fContext->extradata_size = fExtraDataSize;
if (fCodec->capabilities & CODEC_CAP_TRUNCATED)
// Expect and handle video frames to be splitted across consecutive
// data chunks.
fContext->flags |= CODEC_FLAG_TRUNCATED;
TRACE(" requested video format 0x%x\n",
inOutFormat->u.raw_video.display.format);