Add macros to turn off inter and intra mrc_dct separately
This will aid in testing different masking methods for inter
and intra blocks.
Change-Id: Ic038da77e55405e3303177e6cd260bd5e19311c1
diff --git a/av1/encoder/encodemb.c b/av1/encoder/encodemb.c
index d78ec96..b28340a 100644
--- a/av1/encoder/encodemb.c
+++ b/av1/encoder/encodemb.c
@@ -628,11 +628,11 @@
txfm_param.tx_size = tx_size;
txfm_param.lossless = xd->lossless[mbmi->segment_id];
#if CONFIG_MRC_TX || CONFIG_LGT
+ txfm_param.is_inter = is_inter_block(mbmi);
txfm_param.dst = dst;
txfm_param.stride = dst_stride;
#endif // CONFIG_MRC_TX || CONFIG_LGT
#if CONFIG_LGT
- txfm_param.is_inter = is_inter_block(mbmi);
txfm_param.mode = get_prediction_mode(xd->mi[0], plane, tx_size, block);
#endif
diff --git a/av1/encoder/rdopt.c b/av1/encoder/rdopt.c
index 93c385d..a70259b 100644
--- a/av1/encoder/rdopt.c
+++ b/av1/encoder/rdopt.c
@@ -2451,7 +2451,10 @@
#if CONFIG_MRC_TX
// MRC_DCT only implemented for TX_32X32 so only include this tx in
// the search for TX_32X32
- if (tx_type == MRC_DCT && tx_size != TX_32X32) return 1;
+ if (tx_type == MRC_DCT &&
+ ((is_inter && !USE_MRC_INTER) || (!is_inter && !USE_MRC_INTRA) ||
+ tx_size != TX_32X32))
+ return 1;
#endif // CONFIG_MRC_TX
if (mbmi->ref_mv_idx > 0 && tx_type != DCT_DCT) return 1;
if (FIXED_TX_TYPE && tx_type != get_default_tx_type(0, xd, 0, tx_size))
@@ -5224,7 +5227,10 @@
#if CONFIG_MRC_TX
// MRC_DCT only implemented for TX_32X32 so only include this tx in
// the search for TX_32X32
- if (tx_type == MRC_DCT && max_tx_size != TX_32X32) continue;
+ if (tx_type == MRC_DCT &&
+ (max_tx_size != TX_32X32 || (is_inter && !USE_MRC_INTER) ||
+ (!is_inter && !USE_MRC_INTRA)))
+ continue;
#endif // CONFIG_MRC_TX
#if CONFIG_EXT_TX
if (is_inter) {