Go to the documentation of this file.
   23 #define UNCHECKED_BITSTREAM_READER 1 
   51         for (
i = 0; 
i < buf_size; 
i++) {
 
   65         for (; 
i < buf_size; 
i++) {
 
   67             if ((
state & 0xFFFFFF00) == 0x100) {
 
   83                                const uint8_t *buf, 
int buf_size)
 
  117     pc->first_picture = 0;
 
  125     pc->first_picture           = 1;
 
  126     pc->dec_ctx.quant_precision       = 5;
 
  127     pc->dec_ctx.h.c.slice_context_count = 1;
 
  128     pc->dec_ctx.showed_packed_warning = 1;
 
  134                             const uint8_t **poutbuf, 
int *poutbuf_size,
 
  135                             const uint8_t *buf, 
int buf_size)
 
  154     *poutbuf_size = buf_size;
 
  
#define AV_LOG_WARNING
Something somehow does not look correct.
static AVCodecContext * dec_ctx
av_cold void ff_parse_close(AVCodecParserContext *s)
static int mpeg4_find_frame_end(ParseContext *pc, const uint8_t *buf, int buf_size)
Find the end of the current frame in the bitstream.
int ff_set_dimensions(AVCodecContext *s, int width, int height)
Check that the provided frame dimensions are valid and set them on the codec context.
uint32_t state
contains the last few bytes in MSB order
static int init_get_bits(GetBitContext *s, const uint8_t *buffer, int bit_size)
Initialize GetBitContext.
static int mpeg4video_parse(AVCodecParserContext *s, AVCodecContext *avctx, const uint8_t **poutbuf, int *poutbuf_size, const uint8_t *buf, int buf_size)
int has_b_frames
Size of the frame reordering buffer in the decoder.
int64_t av_rescale_q(int64_t a, AVRational bq, AVRational cq)
Rescale a 64-bit integer by 2 rational numbers.
static int mpeg4_decode_header(AVCodecParserContext *s1, AVCodecContext *avctx, const uint8_t *buf, int buf_size)
Rational number (pair of numerator and denominator).
#define AV_NOPTS_VALUE
Undefined timestamp value.
int ff_mpeg4_parse_picture_header(Mpeg4DecContext *ctx, GetBitContext *gb, int header, int parse_only)
Decode MPEG-4 headers.
int ff_combine_frame(ParseContext *pc, int next, const uint8_t **buf, int *buf_size)
Combine the (truncated) bitstream to a complete frame.
#define PARSER_FLAG_COMPLETE_FRAMES
static av_cold int mpeg4video_parse_init(AVCodecParserContext *s)
#define i(width, name, range_min, range_max)
uint8_t * extradata
Out-of-band global headers that may be used by some codecs.
#define av_assert1(cond)
assert() equivalent, that does not lie in speed critical code.
main external API structure.
const AVCodecParser ff_mpeg4video_parser
#define PARSER_FLAG_USE_CODEC_TS
int coded_width
Bitstream width / height, may be different from width/height e.g.
int width
picture width / height.