提交 b704e742 编写于 作者: M Michael Niedermayer

mpeg4 header parser clenup (needed for parsing of VOL header in avctx->extradata)

Originally committed as revision 1032 to svn://svn.ffmpeg.org/ffmpeg/trunk
上级 26893f6b
......@@ -180,6 +180,7 @@ typedef struct AVCodecContext {
* some codecs need / can use extra-data like huffman tables
* mjpeg: huffman tables
* rv10: additional flags
* mpeg4: global headers (they can be in the bitstream or here)
* encoding: set/allocated/freed by lavc.
* decoding: set/allocated/freed by user.
*/
......
此差异已折叠。
......@@ -40,8 +40,6 @@ static inline long long rdtsc()
}
#endif
const UINT16 ff_mpeg4_resync_prefix[8];
static int h263_decode_init(AVCodecContext *avctx)
{
MpegEncContext *s = avctx->priv_data;
......@@ -313,7 +311,14 @@ uint64_t time= rdtsc();
if (s->h263_msmpeg4) {
ret = msmpeg4_decode_picture_header(s);
} else if (s->h263_pred) {
ret = mpeg4_decode_picture_header(s);
if(s->avctx->extradata_size && s->picture_number==0){
GetBitContext gb;
init_get_bits(&gb, s->avctx->extradata, s->avctx->extradata_size);
ret = ff_mpeg4_decode_picture_header(s, &gb);
}
ret = ff_mpeg4_decode_picture_header(s, &s->gb);
s->has_b_frames= !s->low_delay;
} else if (s->h263_intel) {
ret = intel_h263_decode_picture_header(s);
......
......@@ -624,7 +624,9 @@ void h263_encode_init(MpegEncContext *s);
void h263_decode_init_vlc(MpegEncContext *s);
int h263_decode_picture_header(MpegEncContext *s);
int ff_h263_decode_gob_header(MpegEncContext *s);
int mpeg4_decode_picture_header(MpegEncContext * s);
int ff_mpeg4_decode_picture_header(MpegEncContext * s, GetBitContext *gb);
int intel_h263_decode_picture_header(MpegEncContext *s);
int ff_h263_decode_mb(MpegEncContext *s,
DCTELEM block[6][64]);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册