diff --git a/av1/common/common_data.h b/av1/common/common_data.h index 4165e3577..f068ee7e9 100644 --- a/av1/common/common_data.h +++ b/av1/common/common_data.h @@ -444,7 +444,12 @@ static const TX_SIZE txsize_vert_map[TX_SIZES_ALL] = { static const int tx_size_1d[TX_SIZES] = { 4, 8, 16, 32 }; -static const int tx_size_2d[TX_SIZES] = { 16, 64, 256, 1024 }; +static const int tx_size_2d[TX_SIZES_ALL] = { + 16, 64, 256, 1024, +#if CONFIG_EXT_TX + 32, 32, 128, 128, 512, 512, +#endif +}; static const uint8_t tx_size_1d_log2[TX_SIZES] = { 2, 3, 4, 5 }; diff --git a/av1/decoder/decodeframe.c b/av1/decoder/decodeframe.c index 7e73f8f89..146ca237e 100644 --- a/av1/decoder/decodeframe.c +++ b/av1/decoder/decodeframe.c @@ -253,22 +253,12 @@ static void inverse_transform_block(MACROBLOCKD *xd, int plane, } #endif // CONFIG_AOM_HIGHBITDEPTH - if (eob == 1) { + // TODO(jingning): This cleans up different reset requests from various + // experiments, but incurs unnecessary memset size. + if (eob == 1) dqcoeff[0] = 0; - } else { - if (tx_type == DCT_DCT && tx_size <= TX_16X16 && eob <= 10) - memset(dqcoeff, 0, 4 * 4 * num_4x4_blocks_wide_txsize_lookup[tx_size] * - sizeof(dqcoeff[0])); -#if CONFIG_EXT_TX - else - memset(dqcoeff, 0, get_tx2d_size(tx_size) * sizeof(dqcoeff[0])); -#else - else if (tx_size == TX_32X32 && eob <= 34) - memset(dqcoeff, 0, 256 * sizeof(dqcoeff[0])); - else - memset(dqcoeff, 0, get_tx2d_size(tx_size) * sizeof(dqcoeff[0])); -#endif - } + else + memset(dqcoeff, 0, tx_size_2d[tx_size] * sizeof(dqcoeff[0])); } }