Commit 56686b45 authored by Geza Lore's avatar Geza Lore
Browse files

Initalize mbmi->tx_size during rdopt.

This is necessary when using SUPERTX, as the bitstream packer relies on
tx_size being set correctly to decide whether to output the block using
supertx or not.

Change-Id: I79e776b3b810f4a15b9dbc6afdd6fc90c73c8934
parent e7c0e157
...@@ -1527,6 +1527,14 @@ static void rd_pick_sb_modes(VP10_COMP *cpi, ...@@ -1527,6 +1527,14 @@ static void rd_pick_sb_modes(VP10_COMP *cpi,
set_offsets(cpi, tile_info, x, mi_row, mi_col, bsize); set_offsets(cpi, tile_info, x, mi_row, mi_col, bsize);
mbmi = &xd->mi[0]->mbmi; mbmi = &xd->mi[0]->mbmi;
mbmi->sb_type = bsize; mbmi->sb_type = bsize;
// We set tx_size here as skip blocks would otherwise not set it.
// tx_size needs to be set at this point as supertx_enable in
// write_modes_sb is computed based on this, and if the garbage in memory
// just happens to be the supertx_size, then the packer will code this
// block as a supertx block, even if rdopt did not pick it as such.
mbmi->tx_size = max_txsize_lookup[bsize];
for (i = 0; i < MAX_MB_PLANE; ++i) { for (i = 0; i < MAX_MB_PLANE; ++i) {
p[i].coeff = ctx->coeff_pbuf[i][0]; p[i].coeff = ctx->coeff_pbuf[i][0];
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