[FFmpeg-cvslog] vp9: clip intermediates in dequant calculations.
Ronald S. Bultje
git at videolan.org
Fri Sep 4 16:07:47 CEST 2015
ffmpeg | branch: master | Ronald S. Bultje <rsbultje at gmail.com> | Wed Sep 2 13:47:22 2015 -0400| [48f641a18b841c8704b741b59ae71e4bc129e07f] | committer: Ronald S. Bultje
vp9: clip intermediates in dequant calculations.
This makes values consistent with libvpx.
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=48f641a18b841c8704b741b59ae71e4bc129e07f
---
libavcodec/vp9.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/libavcodec/vp9.c b/libavcodec/vp9.c
index 3eff1f1..95af94b 100644
--- a/libavcodec/vp9.c
+++ b/libavcodec/vp9.c
@@ -785,9 +785,9 @@ static int decode_frame_header(AVCodecContext *ctx,
if (s->segmentation.feat[i].q_enabled) {
if (s->segmentation.absolute_vals)
- qyac = s->segmentation.feat[i].q_val;
+ qyac = av_clip_uintp2(s->segmentation.feat[i].q_val, 8);
else
- qyac = s->yac_qi + s->segmentation.feat[i].q_val;
+ qyac = av_clip_uintp2(s->yac_qi + s->segmentation.feat[i].q_val, 8);
} else {
qyac = s->yac_qi;
}
More information about the ffmpeg-cvslog
mailing list