Make it support both single- and multi-layer ARF GOP structure.
Change-Id: I760a95804d1b583b057120f6d6be65195a0e6c19
}
void vp9_estimate_qp_gop(VP9_COMP *cpi) {
- int gop_length = cpi->rc.baseline_gf_interval;
+ int gop_length = cpi->twopass.gf_group.gf_group_size;
int bottom_index, top_index;
int idx;
const int gf_index = cpi->twopass.gf_group.index;
- for (idx = 1; idx <= gop_length + 1 && idx < MAX_LAG_BUFFERS; ++idx) {
+ for (idx = 1; idx < gop_length; ++idx) {
TplDepFrame *tpl_frame = &cpi->tpl_stats[idx];
int target_rate = cpi->twopass.gf_group.bit_allocation[idx];
cpi->twopass.gf_group.index = idx;