From 8fbc139e6143297b8f88bc5145778787b64f4381 Mon Sep 17 00:00:00 2001 From: Jan Ekström Date: Mon, 23 Nov 2020 17:36:20 +0200 Subject: avcodec/av1{dec,parser}: move to ff_cbs_read_extradata_from_codec This lets us re-utilize the extradata-related checks in the CBS to add support for passing the AV1CodecConfigurationRecord as extradata as-is without further filtering. --- libavcodec/av1_parser.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'libavcodec/av1_parser.c') diff --git a/libavcodec/av1_parser.c b/libavcodec/av1_parser.c index 14826d816e..181ff3a1be 100644 --- a/libavcodec/av1_parser.c +++ b/libavcodec/av1_parser.c @@ -73,7 +73,7 @@ static int av1_parser_parse(AVCodecParserContext *ctx, if (avctx->extradata_size && !s->parsed_extradata) { s->parsed_extradata = 1; - ret = ff_cbs_read(s->cbc, td, avctx->extradata, avctx->extradata_size); + ret = ff_cbs_read_extradata_from_codec(s->cbc, td, avctx); if (ret < 0) { av_log(avctx, AV_LOG_WARNING, "Failed to parse extradata.\n"); } -- cgit v1.2.3