WIP: lv_map_multi: make br multi symbol
The br_cdf and lps_cdf with a new 4-state symbol br_cdf.
The br symbol indicates whether the level is k, k+1, k+2 or >k+2
In the latter case, a new br symbol is read. Up to 4 br symbols are
read which will reach level 14 at most. Levels greater than 14 are
golomb coded.
The adapted symbol count is reduced further by this commit.
E.g. for the I-frame of ducks_take_off at cq=12, the number of adapted symbols
is reduced from 4.27M to 3.85M. About 10% reduction.
Gains seems about neutral on a limitied subset.
Change-Id: I294234dbd63fb0fa26aef297a371cba80bd67383
diff --git a/av1/encoder/block.h b/av1/encoder/block.h
index 9c90299..24987f8 100644
--- a/av1/encoder/block.h
+++ b/av1/encoder/block.h
@@ -75,7 +75,9 @@
int base_cost[NUM_BASE_LEVELS][COEFF_BASE_CONTEXTS][2];
#endif
int lps_cost[LEVEL_CONTEXTS][COEFF_BASE_RANGE + 1];
+#if !CONFIG_LV_MAP_MULTI
int br_cost[BASE_RANGE_SETS][LEVEL_CONTEXTS][2];
+#endif
#if CONFIG_CTX1D
int eob_mode_cost[TX_CLASSES][2];
int empty_line_cost[TX_CLASSES][EMPTY_LINE_CONTEXTS][2];