diff options
author | James Almer <jamrial@gmail.com> | 2021-08-16 12:39:19 -0300 |
---|---|---|
committer | James Almer <jamrial@gmail.com> | 2021-08-24 10:00:20 -0300 |
commit | 9b05263ac166924f28a2f4a65883629219fa6689 (patch) | |
tree | bc3d298f233a6a85033cecbf1f468591cc4f9962 /libavcodec/av1dec.c | |
parent | 651fed3860328e5c4eb3191ffc00b3a18074f90d (diff) | |
download | ffmpeg-9b05263ac166924f28a2f4a65883629219fa6689.tar.gz |
avcodec/av1: signal the presence of Film Grain in the decoder context
Signed-off-by: James Almer <jamrial@gmail.com>
Diffstat (limited to 'libavcodec/av1dec.c')
-rw-r--r-- | libavcodec/av1dec.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/libavcodec/av1dec.c b/libavcodec/av1dec.c index 1dda0f9160..a69808f7b6 100644 --- a/libavcodec/av1dec.c +++ b/libavcodec/av1dec.c @@ -575,6 +575,11 @@ static int set_context_with_sequence(AVCodecContext *avctx, break; } + if (seq->film_grain_params_present) + avctx->properties |= FF_CODEC_PROPERTY_FILM_GRAIN; + else + avctx->properties &= ~FF_CODEC_PROPERTY_FILM_GRAIN; + if (avctx->width != width || avctx->height != height) { int ret = ff_set_dimensions(avctx, width, height); if (ret < 0) |