ref: 9416e222e0ad9bf2c740bafb6fb043a8364da9d5
parent: 6ef6268387babad406380260147a878b4830fa29
parent: fc47d1489251e03221aac229107b5eab612d919e
author: Marco Paniconi <marpan@google.com>
date: Tue Jul 24 23:55:51 EDT 2018
Merge "vp9: Fix to the segment weight for cyclic refresh."
--- a/vp9/encoder/vp9_aq_cyclicrefresh.c
+++ b/vp9/encoder/vp9_aq_cyclicrefresh.c
@@ -507,13 +507,12 @@
num8x8bl;
if (weight_segment_target < 7 * weight_segment / 8)
weight_segment = weight_segment_target;
- // For screen-content: don't include target for the weight segment, since
- // all for all flat areas the segment is reset, so its more accurate to
- // just use the previous actual number of seg blocks for the weight.
+ // For screen-content: don't include target for the weight segment,
+ // since for all flat areas the segment is reset, so its more accurate
+ // to just use the previous actual number of seg blocks for the weight.
if (cpi->oxcf.content == VP9E_CONTENT_SCREEN)
weight_segment =
- (double)((cr->actual_num_seg1_blocks + cr->actual_num_seg2_blocks) >>
- 1) /
+ (double)(cr->actual_num_seg1_blocks + cr->actual_num_seg2_blocks) /
num8x8bl;
cr->weight_segment = weight_segment;
}