1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2025-08-04 22:03:09 +02:00

avcodec/decode: Fix avcodec parameters when bsfs are enable by decoder

BSF can update extradata, e.g., vvc_mp4toannexb. If we don't copy
bsf->par_out back to avcodec context, decoder can get extradata in
mp4 format, while packets are in annexb format.
This commit is contained in:
Zhao Zhili
2025-03-06 15:56:27 +08:00
parent c05ed36b56
commit 1c17061397

View File

@ -202,6 +202,9 @@ static int decode_bsfs_init(AVCodecContext *avctx)
goto fail; goto fail;
ret = av_bsf_init(avci->bsf); ret = av_bsf_init(avci->bsf);
if (ret < 0)
goto fail;
ret = avcodec_parameters_to_context(avctx, avci->bsf->par_out);
if (ret < 0) if (ret < 0)
goto fail; goto fail;