Commit ab68ddb3 authored by Debargha Mukherjee's avatar Debargha Mukherjee

Re-enable 16x4 and 4x16 partitons,

Disable corresponding 2x8 and 8x2 chroma inter predicitons for
chroma temporarily.

Change-Id: I7caf8da303d9231534e960fde1a5639cf9820635
parent edced25a
......@@ -901,7 +901,7 @@ static INLINE int is_chroma_reference(int mi_row, int mi_col, BLOCK_SIZE bsize,
int ref_pos = !(((mi_row & 0x01) && subsampling_y) ||
((mi_col & 0x01) && subsampling_x));
if (bsize >= BLOCK_8X8) ref_pos = 1;
if (AOMMIN(block_size_wide[bsize], block_size_high[bsize]) >= 8) ref_pos = 1;
return ref_pos;
#endif
......@@ -910,7 +910,6 @@ static INLINE int is_chroma_reference(int mi_row, int mi_col, BLOCK_SIZE bsize,
static INLINE BLOCK_SIZE scale_chroma_bsize(BLOCK_SIZE bsize, int subsampling_x,
int subsampling_y) {
BLOCK_SIZE bs = bsize;
if (bs < BLOCK_8X8) {
if (subsampling_x == 1 && subsampling_y == 1)
bs = BLOCK_8X8;
......@@ -919,7 +918,6 @@ static INLINE BLOCK_SIZE scale_chroma_bsize(BLOCK_SIZE bsize, int subsampling_x,
else if (subsampling_y == 1)
bs = BLOCK_4X8;
}
return bs;
}
......
......@@ -1142,7 +1142,17 @@ static INLINE void build_inter_predictors(
const BLOCK_SIZE bsize = mi->mbmi.sb_type;
const int ss_x = pd->subsampling_x;
const int ss_y = pd->subsampling_y;
int sub8x8_inter = bsize < BLOCK_8X8 && (ss_x || ss_y);
int sub8x8_inter =
AOMMIN(block_size_wide[bsize], block_size_high[bsize]) < 8 &&
(ss_x || ss_y);
#if CONFIG_EXT_PARTITION_TYPES
// Temporarily turn off sub8x8_inter for 16x4 and 4x16 blocks based on
// color subsampling until 8x2 and 2x8 block sizes are properly supported.
if (sub8x8_inter)
if ((bsize == BLOCK_4X16 && ss_x) || (bsize == BLOCK_16X4 && ss_y))
sub8x8_inter = 0;
#endif // CONFIG_EXT_PARTITION_TYPES
#if CONFIG_INTRABC
if (is_intrabc) {
......
......@@ -3153,12 +3153,10 @@ static void rd_pick_partition(const AV1_COMP *const cpi, ThreadData *td,
// subsample to 16x2, which doesn't have an enum. Also, there's no BLOCK_8X2
// or BLOCK_2X8, so we can't do 4:1 or 1:4 partitions for BLOCK_16X16 if there
// is any subsampling.
const int horz4_partition_allowed = ext_partition_allowed &&
partition_horz_allowed && yss <= xss &&
(xss == 0 || bsize > BLOCK_16X16);
const int vert4_partition_allowed = ext_partition_allowed &&
partition_vert_allowed && xss <= yss &&
(yss == 0 || bsize > BLOCK_16X16);
const int horz4_partition_allowed =
ext_partition_allowed && partition_horz_allowed;
const int vert4_partition_allowed =
ext_partition_allowed && partition_vert_allowed;
#if CONFIG_EXT_PARTITION_TYPES_AB
// The alternative AB partitions are allowed iff the corresponding 4:1
......
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