Commit 784e0866 authored by Yue Chen's avatar Yue Chen

Use 6-bit mask in interintra

Change-Id: I9bfe5caed45e56b5f4efdc5276672938f4e4c2ec
parent aa5ae7e2
......@@ -2497,13 +2497,13 @@ void av1_build_ncobmc_inter_predictors_sb(const AV1_COMMON *cm, MACROBLOCKD *xd,
/* clang-format off */
#if CONFIG_EXT_PARTITION
static const int ii_weights1d[MAX_SB_SIZE] = {
102, 100, 97, 95, 92, 90, 88, 86, 84, 82, 80, 78, 76, 74, 73, 71, 69, 68, 67,
65, 64, 62, 61, 60, 59, 58, 57, 55, 54, 53, 52, 52, 51, 50, 49, 48, 47, 47,
46, 45, 45, 44, 43, 43, 42, 41, 41, 40, 40, 39, 39, 38, 38, 38, 37, 37, 36,
36, 36, 35, 35, 35, 34, 34, 34, 33, 33, 33, 33, 32, 32, 32, 32, 32, 31, 31,
31, 31, 31, 30, 30, 30, 30, 30, 30, 30, 29, 29, 29, 29, 29, 29, 29, 29, 28,
28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 28, 27, 27, 27, 27, 27, 27, 27, 27,
27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27, 27,
26, 25, 24, 24, 23, 23, 22, 22, 21, 21, 20, 20, 19, 19, 18, 18, 17, 17, 17,
16, 16, 16, 15, 15, 15, 15, 14, 14, 14, 13, 13, 13, 13, 13, 12, 12, 12, 12,
12, 11, 11, 11, 11, 11, 11, 10, 10, 10, 10, 10, 10, 10, 10, 10, 9, 9, 9,
9, 9, 9, 9, 9, 9, 9, 9, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8,
8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 7, 7, 7, 7, 7, 7, 7, 7, 7,
7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7
};
static int ii_size_scales[BLOCK_SIZES] = {
#if CONFIG_CB4X4
......@@ -2514,10 +2514,10 @@ static int ii_size_scales[BLOCK_SIZES] = {
};
#else
static const int ii_weights1d[MAX_SB_SIZE] = {
102, 100, 97, 95, 92, 90, 88, 86, 84, 82, 80, 78, 76, 74, 73, 71,
69, 68, 67, 65, 64, 62, 61, 60, 59, 58, 57, 55, 54, 53, 52, 52,
51, 50, 49, 48, 47, 47, 46, 45, 45, 44, 43, 43, 42, 41, 41, 40,
40, 39, 39, 38, 38, 38, 37, 37, 36, 36, 36, 35, 35, 35, 34, 34,
26, 25, 24, 24, 23, 23, 22, 22, 21, 21, 20, 20, 19, 19, 18, 18,
17, 17, 17, 16, 16, 16, 15, 15, 15, 15, 14, 14, 14, 13, 13, 13,
13, 13, 12, 12, 12, 12, 12, 11, 11, 11, 11, 11, 11, 10, 10, 10,
10, 10, 10, 10, 10, 10, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9
};
static int ii_size_scales[BLOCK_SIZES] = {
#if CONFIG_CB4X4
......@@ -2559,8 +2559,8 @@ static void combine_interintra(INTERINTRA_MODE mode, int use_wedge_interintra,
for (j = 0; j < bw; ++j) {
int scale = ii_weights1d[i * size_scale];
comppred[i * compstride + j] =
AOM_BLEND_A256(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
AOM_BLEND_A64(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
}
}
break;
......@@ -2570,8 +2570,8 @@ static void combine_interintra(INTERINTRA_MODE mode, int use_wedge_interintra,
for (j = 0; j < bw; ++j) {
int scale = ii_weights1d[j * size_scale];
comppred[i * compstride + j] =
AOM_BLEND_A256(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
AOM_BLEND_A64(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
}
}
break;
......@@ -2584,8 +2584,8 @@ static void combine_interintra(INTERINTRA_MODE mode, int use_wedge_interintra,
ii_weights1d[j * size_scale]) >>
2;
comppred[i * compstride + j] =
AOM_BLEND_A256(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
AOM_BLEND_A64(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
}
}
break;
......@@ -2598,8 +2598,8 @@ static void combine_interintra(INTERINTRA_MODE mode, int use_wedge_interintra,
ii_weights1d[i * size_scale]) >>
2;
comppred[i * compstride + j] =
AOM_BLEND_A256(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
AOM_BLEND_A64(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
}
}
break;
......@@ -2609,8 +2609,8 @@ static void combine_interintra(INTERINTRA_MODE mode, int use_wedge_interintra,
for (j = 0; j < bw; ++j) {
int scale = ii_weights1d[(i < j ? i : j) * size_scale];
comppred[i * compstride + j] =
AOM_BLEND_A256(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
AOM_BLEND_A64(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
}
}
break;
......@@ -2622,8 +2622,8 @@ static void combine_interintra(INTERINTRA_MODE mode, int use_wedge_interintra,
(ii_weights1d[i * size_scale] + ii_weights1d[j * size_scale]) >>
1;
comppred[i * compstride + j] =
AOM_BLEND_A256(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
AOM_BLEND_A64(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
}
}
break;
......@@ -2675,8 +2675,8 @@ static void combine_interintra_highbd(
for (j = 0; j < bw; ++j) {
int scale = ii_weights1d[i * size_scale];
comppred[i * compstride + j] =
AOM_BLEND_A256(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
AOM_BLEND_A64(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
}
}
break;
......@@ -2686,8 +2686,8 @@ static void combine_interintra_highbd(
for (j = 0; j < bw; ++j) {
int scale = ii_weights1d[j * size_scale];
comppred[i * compstride + j] =
AOM_BLEND_A256(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
AOM_BLEND_A64(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
}
}
break;
......@@ -2700,8 +2700,8 @@ static void combine_interintra_highbd(
ii_weights1d[j * size_scale]) >>
2;
comppred[i * compstride + j] =
AOM_BLEND_A256(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
AOM_BLEND_A64(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
}
}
break;
......@@ -2714,8 +2714,8 @@ static void combine_interintra_highbd(
ii_weights1d[i * size_scale]) >>
2;
comppred[i * compstride + j] =
AOM_BLEND_A256(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
AOM_BLEND_A64(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
}
}
break;
......@@ -2725,8 +2725,8 @@ static void combine_interintra_highbd(
for (j = 0; j < bw; ++j) {
int scale = ii_weights1d[(i < j ? i : j) * size_scale];
comppred[i * compstride + j] =
AOM_BLEND_A256(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
AOM_BLEND_A64(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
}
}
break;
......@@ -2738,8 +2738,8 @@ static void combine_interintra_highbd(
(ii_weights1d[i * size_scale] + ii_weights1d[j * size_scale]) >>
1;
comppred[i * compstride + j] =
AOM_BLEND_A256(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
AOM_BLEND_A64(scale, intrapred[i * intrastride + j],
interpred[i * interstride + j]);
}
}
break;
......
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