avformat/flvenc: add extract_extradata bsf for new video codecs
When encoders don't support global header like MediaCodec, FLV muxer needs to add extract_extradata bsf automatically. The codec list doesn't include VP9 since it's not supported by extract_extradata. Signed-off-by: Zhao Zhili <zhilizhao@tencent.com>
This commit is contained in:
parent
f27fce0c0c
commit
e1d6b3cb5a
@ -1072,6 +1072,8 @@ static int flv_check_bitstream(AVFormatContext *s, AVStream *st,
|
|||||||
}
|
}
|
||||||
if (!st->codecpar->extradata_size &&
|
if (!st->codecpar->extradata_size &&
|
||||||
(st->codecpar->codec_id == AV_CODEC_ID_H264 ||
|
(st->codecpar->codec_id == AV_CODEC_ID_H264 ||
|
||||||
|
st->codecpar->codec_id == AV_CODEC_ID_HEVC ||
|
||||||
|
st->codecpar->codec_id == AV_CODEC_ID_AV1 ||
|
||||||
st->codecpar->codec_id == AV_CODEC_ID_MPEG4))
|
st->codecpar->codec_id == AV_CODEC_ID_MPEG4))
|
||||||
return ff_stream_add_bitstream_filter(st, "extract_extradata", NULL);
|
return ff_stream_add_bitstream_filter(st, "extract_extradata", NULL);
|
||||||
return 1;
|
return 1;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user