Set AVSTREAM_PARSE_HEADERS flag for AV1 MP4 streams
It help initialize chroma format and other info properly Chroma format wasn't correct if I use below code: avformat_find_stream_info(fmtc, NULL); iVideoStream = av_find_best_stream(fmtc, AVMEDIA_TYPE_VIDEO, -1, -1, NULL, 0); eChromaFormat = (AVPixelFormat)fmtc->streams[iVideoStream]->codecpar->format; Signed-off-by: James Almer <jamrial@gmail.com>
This commit is contained in:
committed by
James Almer
parent
7969551a22
commit
026fea827d
@ -2423,6 +2423,9 @@ static int mov_finalize_stsd_codec(MOVContext *c, AVIOContext *pb,
|
|||||||
case AV_CODEC_ID_VP9:
|
case AV_CODEC_ID_VP9:
|
||||||
st->need_parsing = AVSTREAM_PARSE_FULL;
|
st->need_parsing = AVSTREAM_PARSE_FULL;
|
||||||
break;
|
break;
|
||||||
|
case AV_CODEC_ID_AV1:
|
||||||
|
st->need_parsing = AVSTREAM_PARSE_HEADERS;
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user