X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;ds=inline;f=libavcodec%2Fmpegvideo_parser.c;h=78642246434433455f165df0decfbab3ec61fd54;hb=1ab74bc19354aedfb9afe71515952254753a75cc;hp=7a3c7abdb24e58b14dcc5f788b1e70b4b3a0a89a;hpb=ace96d2e693d804a0ed16aebc1b1027cfff2c527;p=ffmpeg diff --git a/libavcodec/mpegvideo_parser.c b/libavcodec/mpegvideo_parser.c index 7a3c7abdb24..78642246434 100644 --- a/libavcodec/mpegvideo_parser.c +++ b/libavcodec/mpegvideo_parser.c @@ -154,7 +154,7 @@ static void mpegvideo_extract_headers(AVCodecParserContext *s, break; } } - the_end: ; + the_end: if (set_dim_ret < 0) av_log(avctx, AV_LOG_ERROR, "Failed to set dimensions\n"); @@ -213,34 +213,16 @@ static int mpegvideo_parse(AVCodecParserContext *s, return next; } -static int mpegvideo_split(AVCodecContext *avctx, - const uint8_t *buf, int buf_size) -{ - int i; - uint32_t state= -1; - int found=0; - - for(i=0; i= 0x100) - return i-3; - } - return 0; -} - static int mpegvideo_parse_init(AVCodecParserContext *s) { s->pict_type = AV_PICTURE_TYPE_NONE; // first frame might be partial return 0; } -AVCodecParser ff_mpegvideo_parser = { +const AVCodecParser ff_mpegvideo_parser = { .codec_ids = { AV_CODEC_ID_MPEG1VIDEO, AV_CODEC_ID_MPEG2VIDEO }, .priv_data_size = sizeof(struct MpvParseContext), .parser_init = mpegvideo_parse_init, .parser_parse = mpegvideo_parse, .parser_close = ff_parse_close, - .split = mpegvideo_split, };