diff --git a/av1/decoder/decodeframe.c b/av1/decoder/decodeframe.c index 594141c82efb14d5fdee443254cfd32e1c8f49e9..ceb9bbf95704630cfa3dc280e2d6d834b0094b92 100644 --- a/av1/decoder/decodeframe.c +++ b/av1/decoder/decodeframe.c @@ -507,7 +507,7 @@ static void decode_block(AV1Decoder *const pbi, MACROBLOCKD *const xd, : mbmi->tx_size; const int num_4x4_w = pd->n4_w; const int num_4x4_h = pd->n4_h; - const int step = (1 << tx_size); + const int step = tx_size_1d_in_unit[tx_size]; int row, col; const int max_blocks_wide = num_4x4_w + (xd->mb_to_right_edge >= 0 @@ -542,7 +542,7 @@ static void decode_block(AV1Decoder *const pbi, MACROBLOCKD *const xd, : mbmi->tx_size; const int num_4x4_w = pd->n4_w; const int num_4x4_h = pd->n4_h; - const int step = (1 << tx_size); + const int step = tx_size_1d_in_unit[tx_size]; int row, col; const int max_blocks_wide = num_4x4_w + (xd->mb_to_right_edge >= 0 diff --git a/av1/decoder/detokenize.c b/av1/decoder/detokenize.c index abf6199270f47bdca0c88b150bdaebdc7ef489c7..1a43596c749647b13f9a0cc9bb8124f1860a2e45 100644 --- a/av1/decoder/detokenize.c +++ b/av1/decoder/detokenize.c @@ -57,7 +57,7 @@ static int decode_coefs(const MACROBLOCKD *xd, PLANE_TYPE type, #endif { FRAME_COUNTS *counts = xd->counts; - const int max_eob = 16 << (tx_size << 1); + const int max_eob = 1 << (tx_size_1d_log2[tx_size] * 2); const FRAME_CONTEXT *const fc = xd->fc; const int ref = is_inter_block(&xd->mi[0]->mbmi); #if CONFIG_AOM_QM