[FFmpeg-cvslog] avcodec/decode: copy the output parameters from the last bsf in the chain back to the AVCodecContext
James Almer
git at videolan.org
Fri Aug 17 06:07:25 EEST 2018
ffmpeg | branch: master | James Almer <jamrial at gmail.com> | Thu Jul 26 20:43:19 2018 -0300| [f631c328e680a3dd491936b92f69970c20cdcfc7] | committer: James Almer
avcodec/decode: copy the output parameters from the last bsf in the chain back to the AVCodecContext
Certain AVCodecParameters, like the contents of the extradata, may be changed
by the init() function of any of the bitstream filters in the chain.
Signed-off-by: James Almer <jamrial at gmail.com>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=f631c328e680a3dd491936b92f69970c20cdcfc7
---
libavcodec/decode.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/libavcodec/decode.c b/libavcodec/decode.c
index 2e82f6b506..4607e9f318 100644
--- a/libavcodec/decode.c
+++ b/libavcodec/decode.c
@@ -281,6 +281,10 @@ int ff_decode_bsfs_init(AVCodecContext *avctx)
bsfs_str++;
}
+ ret = avcodec_parameters_to_context(avctx, s->bsfs[s->nb_bsfs - 1]->par_out);
+ if (ret < 0)
+ return ret;
+
return 0;
fail:
ff_decode_bsfs_uninit(avctx);
More information about the ffmpeg-cvslog
mailing list