24 #define SLICE_MAX_START_CODE 0x000001af
26 #define ISPIC(x) ((x) == 0xB3 || (x) == 0xB6)
27 #define ISUNIT(x) ((x) == 0xB0 || (x) == 0xB1 || (x) == 0xB2 || ISPIC(x))
36 for (; cur < buf_size; ++cur) {
37 state = (state<<8) | buf[cur];
49 for (; cur < buf_size; ++cur) {
50 state = (state << 8) | buf[cur];
66 const uint8_t **poutbuf,
int *poutbuf_size,
84 *poutbuf_size = buf_size;
int ff_mpeg4video_split(AVCodecContext *avctx, const uint8_t *buf, int buf_size)
#define SLICE_MAX_START_CODE
AVCodecParser ff_avs2_parser
int ff_combine_frame(ParseContext *pc, int next, const uint8_t **buf, int *buf_size)
Combine the (truncated) bitstream to a complete frame.
static char * split(char *message, char delim)
void ff_parse_close(AVCodecParserContext *s)
main external API structure.
uint32_t state
contains the last few bytes in MSB order
static int avs2_find_frame_end(ParseContext *pc, const uint8_t *buf, int buf_size)
static int avs2_parse(AVCodecParserContext *s, AVCodecContext *avctx, const uint8_t **poutbuf, int *poutbuf_size, const uint8_t *buf, int buf_size)
#define PARSER_FLAG_COMPLETE_FRAMES