Commit 9b75e210 authored by David Barker's avatar David Barker Committed by Debargha Mukherjee

A few fixes for ext-inter

* When wedge and compound-segment are disabled, we don't use
  compound_type_cdf, but it still gets copied around, averaged, etc.
  It's slightly nicer to avoid that when it isn't necessary.

* Fix an anomaly with cb4x4: We had (schematically)
  'if (bsize < 8X8 && CB4X4)', which is backwards when compared to
  other similar conditions elsewhere in the code.
  Change this to 'if (bsize < 8X8 && !CB4X4)" to match other code.

Change-Id: If802cf4f305c30cd642d0d5dd6610b547b52a027
parent ef125a07
......@@ -3065,7 +3065,9 @@ void av1_average_tile_inter_cdfs(AV1_COMMON *cm, FRAME_CONTEXT *fc,
#if CONFIG_EXT_INTER
AVERAGE_TILE_CDFS(inter_compound_mode_cdf)
#if CONFIG_WEDGE || CONFIG_COMPOUND_SEGMENT
AVERAGE_TILE_CDFS(compound_type_cdf)
#endif // CONFIG_WEDGE || CONFIG_COMPOUND_SEGMENT
#if CONFIG_COMPOUND_SINGLEREF
AVERAGE_TILE_CDFS(inter_singleref_comp_mode_cdf)
#endif
......
......@@ -649,9 +649,6 @@ static const aom_cdf_prob
{ AOM_ICDF(32640), AOM_ICDF(32768), 0 },
{ AOM_ICDF(32640), AOM_ICDF(32768), 0 },
};
#else
static const aom_cdf_prob default_compound_type_cdf[BLOCK_SIZES_ALL]
[CDF_SIZE(COMPOUND_TYPES)];
#endif // CONFIG_COMPOUND_SEGMENT && CONFIG_WEDGE
#if CONFIG_INTERINTRA
......@@ -4710,7 +4707,9 @@ static void init_mode_probs(FRAME_CONTEXT *fc) {
default_inter_singleref_comp_mode_cdf);
#endif // CONFIG_COMPOUND_SINGLEREF
av1_copy(fc->compound_type_prob, default_compound_type_probs);
#if CONFIG_WEDGE || CONFIG_COMPOUND_SEGMENT
av1_copy(fc->compound_type_cdf, default_compound_type_cdf);
#endif // CONFIG_WEDGE || CONFIG_COMPOUND_SEGMENT
#if CONFIG_INTERINTRA
av1_copy(fc->interintra_prob, default_interintra_prob);
av1_copy(fc->wedge_interintra_prob, default_wedge_interintra_prob);
......
......@@ -202,7 +202,9 @@ typedef struct frame_contexts {
INTER_SINGLEREF_COMP_MODES)];
#endif // CONFIG_COMPOUND_SINGLEREF
aom_prob compound_type_prob[BLOCK_SIZES_ALL][COMPOUND_TYPES - 1];
#if CONFIG_WEDGE || CONFIG_COMPOUND_SEGMENT
aom_cdf_prob compound_type_cdf[BLOCK_SIZES_ALL][CDF_SIZE(COMPOUND_TYPES)];
#endif // CONFIG_WEDGE || CONFIG_COMPOUND_SEGMENT
#if CONFIG_INTERINTRA
aom_prob interintra_prob[BLOCK_SIZE_GROUPS];
aom_prob wedge_interintra_prob[BLOCK_SIZES_ALL];
......
......@@ -2347,7 +2347,7 @@ static void read_inter_block_mode_info(AV1Decoder *const pbi,
}
#if CONFIG_EXT_INTER
if ((bsize < BLOCK_8X8 && unify_bsize) ||
if ((bsize < BLOCK_8X8 && !unify_bsize) ||
(mbmi->mode != ZEROMV && mbmi->mode != ZERO_ZEROMV))
#else
if ((bsize < BLOCK_8X8 && !unify_bsize) || mbmi->mode != ZEROMV)
......
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