@@ -2970,7 +2970,7 @@ h263i_decoder_select="h263_decoder"
h263p_decoder_select="h263_decoder"
h263p_encoder_select="h263_encoder"
h264_decoder_select="cabac golomb h264chroma h264dsp h264parse h264pred h264qpel h264_sei videodsp"
-h264_decoder_suggest="error_resilience"
+h264_decoder_suggest="error_resilience liblcevc_dec"
hap_decoder_select="snappy texturedsp"
hap_encoder_deps="libsnappy"
hap_encoder_select="texturedspenc"
@@ -518,6 +518,14 @@ static int h264_frame_start(H264Context *h)
pic->needs_fg = h->sei.common.film_grain_characteristics.present && !h->avctx->hwaccel &&
!(h->avctx->export_side_data & AV_CODEC_EXPORT_DATA_FILM_GRAIN);
+ if (CONFIG_LIBLCEVC_DEC && h->sei.common.lcevc.info && !h->avctx->hwaccel &&
+ !(h->avctx->export_side_data & AV_CODEC_EXPORT_DATA_ENHANCEMENTS)) {
+ HEVCSEILCEVC *lcevc = &h->sei.common.lcevc;
+ ret = ff_frame_new_side_data_from_buf(h->avctx, pic->f,
+ AV_FRAME_DATA_LCEVC, &lcevc->info);
+ if (ret < 0)
+ return ret;
+ }
if ((ret = alloc_picture(h, pic)) < 0)
return ret;
@@ -904,6 +904,8 @@ static int output_frame(H264Context *h, AVFrame *dst, H264Picture *srcp)
if (!(h->avctx->export_side_data & AV_CODEC_EXPORT_DATA_FILM_GRAIN))
av_frame_remove_side_data(dst, AV_FRAME_DATA_FILM_GRAIN_PARAMS);
+ if (!CONFIG_LIBLCEVC_DEC && !(h->avctx->export_side_data & AV_CODEC_EXPORT_DATA_ENHANCEMENTS))
+ av_frame_remove_side_data(dst, AV_FRAME_DATA_LCEVC);
return 0;
fail:
Signed-off-by: James Almer <jamrial@gmail.com> --- configure | 2 +- libavcodec/h264_slice.c | 8 ++++++++ libavcodec/h264dec.c | 2 ++ 3 files changed, 11 insertions(+), 1 deletion(-)