diff options
author | konablend <[email protected]> | 2012-09-10 17:39:20 +0000 |
---|---|---|
committer | konablend <[email protected]> | 2012-09-10 17:39:20 +0000 |
commit | 438f63486268526dea56410a5e5a31f04b0bdaa2 (patch) | |
tree | 72ab2d45a853a395b709906995685c15f4e4a946 /libhb/stream.c | |
parent | 0f39e0706350385b4260a58fa9273e716d61d663 (diff) |
Remove contrib/ffmpeg/A02-png-sequences.patch.
Set AVPacket flags indicating key-frame for avcodec_decode_video2() call. Specifically, libav documentation states:
* @param[in] avpkt The input AVpacket containing the input buffer.
* You can create such packet with av_init_packet() and by then setting
* data and size, some decoders might in addition need other fields like
* flags&AV_PKT_FLAG_KEY. All decoders are designed to use the least
* fields possible.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@4950 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'libhb/stream.c')
-rw-r--r-- | libhb/stream.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/libhb/stream.c b/libhb/stream.c index 27e753f0f..4dd4a4e2a 100644 --- a/libhb/stream.c +++ b/libhb/stream.c @@ -5712,6 +5712,14 @@ hb_buffer_t * hb_ffmpeg_read( hb_stream_t *stream ) { case AVMEDIA_TYPE_VIDEO: buf->s.type = VIDEO_BUF; + /* + * libav avcodec_decode_video2() needs AVPacket flagged with AV_PKT_FLAG_KEY + * for some codecs. For example, sequence of PNG in a mov container. + */ + if ( stream->ffmpeg_pkt->flags & AV_PKT_FLAG_KEY ) + { + buf->s.frametype |= HB_FRAME_KEY; + } break; case AVMEDIA_TYPE_AUDIO: |