comparison vc1.c @ 9355:54bc8a2727b0 libavcodec

Implement avcodec_decode_video2(), _audio3() and _subtitle2() which takes an AVPacket argument rather than a const uint8_t *buf + int buf_size. This allows passing of packet-specific flags from demuxer to decoder, such as the keyframe flag, which appears necessary to playback corePNG P-frames. Patch by Thilo Borgmann thilo.borgmann googlemail com, see also the thread "Google Summer of Code participation" on the mailinglist.
author rbultje
date Tue, 07 Apr 2009 15:59:50 +0000
parents 5c14ea3f8950
children 25b3650b4db5
comparison
equal deleted inserted replaced
9354:174309386512 9355:54bc8a2727b0
4134 /** Decode a VC1/WMV3 frame 4134 /** Decode a VC1/WMV3 frame
4135 * @todo TODO: Handle VC-1 IDUs (Transport level?) 4135 * @todo TODO: Handle VC-1 IDUs (Transport level?)
4136 */ 4136 */
4137 static int vc1_decode_frame(AVCodecContext *avctx, 4137 static int vc1_decode_frame(AVCodecContext *avctx,
4138 void *data, int *data_size, 4138 void *data, int *data_size,
4139 const uint8_t *buf, int buf_size) 4139 AVPacket *avpkt)
4140 { 4140 {
4141 const uint8_t *buf = avpkt->data;
4142 int buf_size = avpkt->size;
4141 VC1Context *v = avctx->priv_data; 4143 VC1Context *v = avctx->priv_data;
4142 MpegEncContext *s = &v->s; 4144 MpegEncContext *s = &v->s;
4143 AVFrame *pict = data; 4145 AVFrame *pict = data;
4144 uint8_t *buf2 = NULL; 4146 uint8_t *buf2 = NULL;
4145 const uint8_t *buf_start = buf; 4147 const uint8_t *buf_start = buf;