ref: 134072dbd37e0adac154fecf0a5434d538d5d096
parent: 0623526872f0420178c5cbf960bd04ba609e5d63
author: Jingning Han <[email protected]>
date: Mon Nov 12 11:22:46 EST 2018
Rescale arf bit budget calculation To compute the total budget for a depth layer, exclude the count of frames that have been allocated the bit budget. This improves the avg PSNR by 0.15% and overall PSNR by 0.25% for lowres and midres test sets. Change-Id: I5115e33e1422dc930179142cd29aeebe97425283
--- a/vp9/encoder/vp9_firstpass.c
+++ b/vp9/encoder/vp9_firstpass.c
@@ -2301,8 +2301,9 @@
for (idx = 2; idx < MAX_ARF_LAYERS; ++idx) {
if (arf_depth_boost[idx] == 0) break;
- arf_depth_bits[idx] = calculate_boost_bits(
- rc->baseline_gf_interval, arf_depth_boost[idx], total_group_bits);
+ arf_depth_bits[idx] =
+ calculate_boost_bits(rc->baseline_gf_interval - total_arfs,
+ arf_depth_boost[idx], total_group_bits);
total_group_bits -= arf_depth_bits[idx];
total_arfs += arf_depth_count[idx];