Mercurial > libavcodec.hg
comparison txd.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 | 2acf0ae7b041 |
children | 6cd9e789dd9e |
comparison
equal
deleted
inserted
replaced
9354:174309386512 | 9355:54bc8a2727b0 |
---|---|
37 | 37 |
38 return 0; | 38 return 0; |
39 } | 39 } |
40 | 40 |
41 static int txd_decode_frame(AVCodecContext *avctx, void *data, int *data_size, | 41 static int txd_decode_frame(AVCodecContext *avctx, void *data, int *data_size, |
42 const uint8_t *buf, int buf_size) { | 42 AVPacket *avpkt) { |
43 const uint8_t *buf = avpkt->data; | |
44 int buf_size = avpkt->size; | |
43 TXDContext * const s = avctx->priv_data; | 45 TXDContext * const s = avctx->priv_data; |
44 AVFrame *picture = data; | 46 AVFrame *picture = data; |
45 AVFrame * const p = &s->picture; | 47 AVFrame * const p = &s->picture; |
46 unsigned int version, w, h, d3d_format, depth, stride, mipmap_count, flags; | 48 unsigned int version, w, h, d3d_format, depth, stride, mipmap_count, flags; |
47 unsigned int y, v; | 49 unsigned int y, v; |