Commit 2f42d778 authored by Jingning Han's avatar Jingning Han
Browse files

Make var-tx context update support lv-map context sets

Properly update the inter transform block context model used by
the level-map coding in the recursive transform block partition

Change-Id: Ib647ead8f6778189b6098bf5e6d691144e899c4b
parent 1643a0ac
......@@ -4384,7 +4384,12 @@ static void select_tx_block(const AV1_COMP *cpi, MACROBLOCK *x, int blk_row,
rd_stats->rate +=
av1_cost_bit(cpi->common.fc->txfm_partition_prob[ctx], 0);
this_rd = RDCOST(x->rdmult, rd_stats->rate, rd_stats->dist);
tmp_eob = p->txb_entropy_ctx[block];
tmp_eob = p->eobs[block];
best_tx_type = mbmi->txk_type[txk_idx];
......@@ -4529,8 +4534,15 @@ static void select_tx_block(const AV1_COMP *cpi, MACROBLOCK *x, int blk_row,
if (this_rd < sum_rd) {
int idx, idy;
for (i = 0; i < tx_size_wide_unit[tx_size]; ++i) pta[i] = !(tmp_eob == 0);
for (i = 0; i < tx_size_high_unit[tx_size]; ++i) ptl[i] = !(tmp_eob == 0);
p->txb_entropy_ctx[block] = tmp_eob;
p->eobs[block] = tmp_eob;
av1_set_txb_context(x, plane, block, tx_size, pta, ptl);
txfm_partition_update(tx_above + blk_col, tx_left + blk_row, tx_size,
inter_tx_size[0][0] = tx_size;
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment