Remove duplicate macros
For the tool of ext-comp-refs
Change-Id: I5a64b2206b34b3b18ca897b1d711533a4525a7f0
diff --git a/av1/common/pred_common.c b/av1/common/pred_common.c
index cd1d126..872a207 100644
--- a/av1/common/pred_common.c
+++ b/av1/common/pred_common.c
@@ -314,8 +314,6 @@
}
#if CONFIG_EXT_COMP_REFS
-#define CHECK_BWDREF_OR_ALTREF(ref_frame) \
- ((ref_frame) == BWDREF_FRAME || (ref_frame) == ALTREF_FRAME)
// TODO(zoeliu): To try on the design of 3 contexts, instead of 5:
// COMP_REF_TYPE_CONTEXTS = 3
int av1_get_comp_reference_type_context(const MACROBLOCKD *xd) {
@@ -345,9 +343,9 @@
const MV_REFERENCE_FRAME frfl = left_mbmi->ref_frame[0];
if (a_sg && l_sg) { // single/single
- pred_context = 1 +
- 2 * (!(CHECK_BWDREF_OR_ALTREF(frfa) ^
- CHECK_BWDREF_OR_ALTREF(frfl)));
+ pred_context =
+ 1 +
+ 2 * (!(IS_BACKWARD_REF_FRAME(frfa) ^ IS_BACKWARD_REF_FRAME(frfl)));
} else if (l_sg || a_sg) { // single/comp
const int uni_rfc =
a_sg ? has_uni_comp_refs(left_mbmi) : has_uni_comp_refs(above_mbmi);
@@ -355,8 +353,8 @@
if (!uni_rfc) // comp bidir
pred_context = 1;
else // comp unidir
- pred_context = 3 + (!(CHECK_BWDREF_OR_ALTREF(frfa) ^
- CHECK_BWDREF_OR_ALTREF(frfl)));
+ pred_context = 3 + (!(IS_BACKWARD_REF_FRAME(frfa) ^
+ IS_BACKWARD_REF_FRAME(frfl)));
} else { // comp/comp
const int a_uni_rfc = has_uni_comp_refs(above_mbmi);
const int l_uni_rfc = has_uni_comp_refs(left_mbmi);