Combine CONFIG_ATC_COEFCODING and CONFIG_ATC_NEWTXSETS
Combine macros CONFIG_ATC_COEFCODING and CONFIG_ATC_NEWTXSETS for issue #227
diff --git a/av1/common/av1_rtcd_defs.pl b/av1/common/av1_rtcd_defs.pl
index ae7abee..e0efb4e 100644
--- a/av1/common/av1_rtcd_defs.pl
+++ b/av1/common/av1_rtcd_defs.pl
@@ -350,7 +350,7 @@
specialize qw/av1_get_nz_map_contexts_skip sse2/;
}
- if (aom_config("CONFIG_ATC_COEFCODING") eq "yes") {
+ if (aom_config("CONFIG_ATC") eq "yes") {
add_proto qw/void av1_get_nz_map_contexts/, "const uint8_t *const levels, const int16_t *const scan, const uint16_t eob, const TX_SIZE tx_size, const TX_CLASS tx_class, int8_t *const coeff_contexts, const int plane";
} else {
add_proto qw/void av1_get_nz_map_contexts/, "const uint8_t *const levels, const int16_t *const scan, const uint16_t eob, const TX_SIZE tx_size, const TX_CLASS tx_class, int8_t *const coeff_contexts";
diff --git a/av1/common/blockd.h b/av1/common/blockd.h
index 78316b4..98ed1c5 100644
--- a/av1/common/blockd.h
+++ b/av1/common/blockd.h
@@ -2328,14 +2328,14 @@
// Number of transform types in each set type for intra blocks
static const int av1_num_ext_tx_set_intra[EXT_TX_SET_TYPES] = { 1, 1, 4,
6, 11, 15,
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
7
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
};
-#if CONFIG_ATC_NEWTXSETS && CONFIG_ATC_REDUCED_TXSET
+#if CONFIG_ATC && CONFIG_ATC_REDUCED_TXSET
static const int av1_num_reduced_tx_set = 2;
-#endif // CONFIG_ATC_NEWTXSETS && CONFIG_ATC_REDUCED_TXSET
+#endif // CONFIG_ATC && CONFIG_ATC_REDUCED_TXSET
// Number of transform types in each set type
static const int av1_num_ext_tx_set[EXT_TX_SET_TYPES] = {
@@ -2349,12 +2349,12 @@
{ 1, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0 },
{ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0 },
{ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 },
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
{ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 },
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
};
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
static const int av1_mdtx_used_flag[EXT_TX_SIZES][INTRA_MODES][TX_TYPES] = {
{
{ 1, 1, 1, 1, 0, 0, 0, 1, 1, 1, 0, 0, 0, 1, 0, 0 },
@@ -2417,7 +2417,7 @@
{ 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0 },
}, // size_class: 3
};
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
static const uint16_t av1_reduced_intra_tx_used_flag[INTRA_MODES] = {
0x080F, // DC_PRED: 0000 1000 0000 1111
@@ -2442,12 +2442,12 @@
0x0E0F, // 0000 1110 0000 1111
0x0FFF, // 0000 1111 1111 1111
0xFFFF, // 1111 1111 1111 1111
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
0xFFFF,
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
};
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
static const uint16_t av1_md_trfm_used_flag[EXT_TX_SIZES][INTRA_MODES] = {
{
0x218F,
@@ -2510,7 +2510,7 @@
0x0000,
}, // size_class: 3
};
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
static const TxSetType av1_ext_tx_set_lookup[2][2] = {
{ EXT_TX_SET_DTT4_IDTX_1DDCT, EXT_TX_SET_DTT4_IDTX },
@@ -2533,7 +2533,7 @@
if (use_reduced_set)
return is_inter ? EXT_TX_SET_DCT_IDTX : EXT_TX_SET_DTT4_IDTX;
#endif // CONFIG_ATC_REDUCED_TXSET
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
if (is_inter) {
const TX_SIZE tx_size_sqr = txsize_sqr_map[tx_size];
return av1_ext_tx_set_lookup[is_inter][tx_size_sqr == TX_16X16];
@@ -2543,17 +2543,17 @@
#else
const TX_SIZE tx_size_sqr = txsize_sqr_map[tx_size];
return av1_ext_tx_set_lookup[is_inter][tx_size_sqr == TX_16X16];
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
}
// Maps tx set types to the indices.
static const int ext_tx_set_index[2][EXT_TX_SET_TYPES] = {
{ // Intra
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
0, -1, -1, -1, -1, -1, 1 },
#else
0, -1, 2, 1, -1, -1 },
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
{ // Inter
0, 3, -1, -1, 2, 1 },
};
diff --git a/av1/common/common_data.h b/av1/common/common_data.h
index 6cd3d1b..81400a2 100644
--- a/av1/common/common_data.h
+++ b/av1/common/common_data.h
@@ -653,7 +653,7 @@
{ 13, 3 },
};
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
// Mapping of mode dependent TX based on intra modes.
static const int av1_md_class[INTRA_MODES] = {
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12,
@@ -663,7 +663,7 @@
static const int av1_size_class[TX_SIZES_ALL] = {
0, 1, 2, 3, 3, 0, 0, 1, 1, 3, 3, 3, 3, 0, 0, 3, 3, 3, 3,
};
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
static AOM_INLINE bool is_bsize_geq(BLOCK_SIZE bsize1, BLOCK_SIZE bsize2) {
if (bsize1 == BLOCK_INVALID || bsize2 == BLOCK_INVALID) {
diff --git a/av1/common/entropy.c b/av1/common/entropy.c
index 4b9ec47..176a37b 100644
--- a/av1/common/entropy.c
+++ b/av1/common/entropy.c
@@ -45,13 +45,13 @@
av1_copy(cm->fc->v_dc_sign_cdf, av1_default_v_dc_sign_cdfs[index]);
av1_copy(cm->fc->v_ac_sign_cdf, av1_default_v_ac_sign_cdfs[index]);
#endif // CONFIG_CONTEXT_DERIVATION
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
av1_copy(cm->fc->coeff_base_lf_cdf,
av1_default_coeff_base_lf_multi_cdfs[index]);
av1_copy(cm->fc->coeff_base_lf_eob_cdf,
av1_default_coeff_base_lf_eob_multi_cdfs[index]);
av1_copy(cm->fc->coeff_br_lf_cdf, av1_default_coeff_lps_lf_multi_cdfs[index]);
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
av1_copy(cm->fc->coeff_br_cdf, av1_default_coeff_lps_multi_cdfs[index]);
av1_copy(cm->fc->coeff_base_cdf, av1_default_coeff_base_multi_cdfs[index]);
av1_copy(cm->fc->idtx_sign_cdf, av1_default_idtx_sign_cdfs[index]);
@@ -144,11 +144,11 @@
#if CONFIG_ATC_DCTX_ALIGNED
RESET_CDF_COUNTER(fc->coeff_base_bob_cdf, 3);
#endif // CONFIG_ATC_DCTX_ALIGNED
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
RESET_CDF_COUNTER(fc->coeff_base_lf_cdf, LF_BASE_SYMBOLS);
RESET_CDF_COUNTER(fc->coeff_base_lf_eob_cdf, LF_BASE_SYMBOLS - 1);
RESET_CDF_COUNTER(fc->coeff_br_lf_cdf, BR_CDF_SIZE);
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
RESET_CDF_COUNTER(fc->coeff_base_cdf, 4);
RESET_CDF_COUNTER(fc->idtx_sign_cdf, 2);
RESET_CDF_COUNTER(fc->coeff_base_cdf_idtx, 4);
@@ -382,10 +382,10 @@
}
RESET_CDF_COUNTER_STRIDE(fc->intra_ext_tx_cdf[1], INTRA_TX_SET1,
CDF_SIZE(TX_TYPES));
-#if !(CONFIG_ATC_NEWTXSETS && !CONFIG_ATC_REDUCED_TXSET)
+#if !(CONFIG_ATC && !CONFIG_ATC_REDUCED_TXSET)
RESET_CDF_COUNTER_STRIDE(fc->intra_ext_tx_cdf[2], INTRA_TX_SET2,
CDF_SIZE(TX_TYPES));
-#endif // !(CONFIG_ATC_NEWTXSETS && !CONFIG_ATC_REDUCED_TXSET)
+#endif // !(CONFIG_ATC && !CONFIG_ATC_REDUCED_TXSET)
RESET_CDF_COUNTER_STRIDE(fc->inter_ext_tx_cdf[1], 16, CDF_SIZE(TX_TYPES));
RESET_CDF_COUNTER_STRIDE(fc->inter_ext_tx_cdf[2], 12, CDF_SIZE(TX_TYPES));
RESET_CDF_COUNTER_STRIDE(fc->inter_ext_tx_cdf[3], 2, CDF_SIZE(TX_TYPES));
diff --git a/av1/common/entropy.h b/av1/common/entropy.h
index 6838d0f..8efd218 100644
--- a/av1/common/entropy.h
+++ b/av1/common/entropy.h
@@ -52,7 +52,7 @@
#define COEFF_BR_PH_CONTEXTS 7
#endif // CONFIG_PAR_HIDING
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
// Number of coefficient coding contexts for the low-frequency region
// for 2D and 1D transforms
#define LF_SIG_COEF_CONTEXTS_2D 21
@@ -84,7 +84,7 @@
#define SIG_COEF_CONTEXTS_1D 16
#define SIG_COEF_CONTEXTS_EOB 4
#define SIG_COEF_CONTEXTS (SIG_COEF_CONTEXTS_2D + SIG_COEF_CONTEXTS_1D)
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
#define COEFF_BASE_CONTEXTS (SIG_COEF_CONTEXTS)
#define DC_SIGN_CONTEXTS 3
diff --git a/av1/common/entropymode.c b/av1/common/entropymode.c
index 8d4100c..f36f742 100644
--- a/av1/common/entropymode.c
+++ b/av1/common/entropymode.c
@@ -1040,7 +1040,7 @@
{ 0 },
},
},
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
{
{
{ AOM_CDF7(3368, 14670, 18533, 22660, 26441, 30407) },
@@ -1292,7 +1292,7 @@
{ AOM_CDF4(8192, 16384, 24576) },
},
}
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
};
#if CONFIG_ATC_DCTX_ALIGNED
diff --git a/av1/common/entropymode.h b/av1/common/entropymode.h
index 3301366..501c648 100644
--- a/av1/common/entropymode.h
+++ b/av1/common/entropymode.h
@@ -171,7 +171,7 @@
aom_cdf_prob idtx_sign_cdf[IDTX_SIGN_CONTEXTS][CDF_SIZE(2)];
aom_cdf_prob coeff_base_cdf_idtx[IDTX_SIG_COEF_CONTEXTS][CDF_SIZE(4)];
aom_cdf_prob coeff_br_cdf_idtx[IDTX_LEVEL_CONTEXTS][CDF_SIZE(BR_CDF_SIZE)];
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
aom_cdf_prob coeff_base_lf_cdf[TX_SIZES][PLANE_TYPES][LF_SIG_COEF_CONTEXTS]
[CDF_SIZE(LF_BASE_SYMBOLS)];
aom_cdf_prob coeff_base_lf_eob_cdf[TX_SIZES][PLANE_TYPES]
@@ -183,7 +183,7 @@
#else
aom_cdf_prob coeff_br_cdf[TX_SIZES][PLANE_TYPES][LEVEL_CONTEXTS]
[CDF_SIZE(BR_CDF_SIZE)];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
#if CONFIG_PAR_HIDING
aom_cdf_prob coeff_base_ph_cdf[COEFF_BASE_PH_CONTEXTS]
[CDF_SIZE(NUM_BASE_LEVELS + 2)];
@@ -484,7 +484,7 @@
{ 9, 10, 11, 12, 13, 14, 15, 0, 1, 2, 4, 5, 3, 6, 7, 8 },
};
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
static const int av1_md_type2idx[EXT_TX_SIZES][INTRA_MODES][TX_TYPES] = {
{
{ 0, 2, 3, 1, 0, 0, 0, 4, 5, 0, 0, 0, 0, 6, 0, 0 }, // mode_class: 0
@@ -624,7 +624,7 @@
? av1_md_idx2type[size_idx][av1_md_class[intra_mode]][tx_idx]
: av1_ext_tx_inv[tx_set_type][tx_idx];
}
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
void av1_set_default_ref_deltas(int8_t *ref_deltas);
void av1_set_default_mode_deltas(int8_t *mode_deltas);
diff --git a/av1/common/enums.h b/av1/common/enums.h
index 670d03b..e412cf9 100644
--- a/av1/common/enums.h
+++ b/av1/common/enums.h
@@ -616,9 +616,9 @@
EXT_TX_SET_DTT9_IDTX_1DDCT,
// Discrete Trig transforms w/ flip (9) + Identity (1) + 1D Hor/Ver (6)
EXT_TX_SET_ALL16,
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
EXT_NEW_TX_SET,
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
EXT_TX_SET_TYPES
} UENUM1BYTE(TxSetType);
@@ -627,13 +627,13 @@
#endif // CONFIG_ATC_DCTX_ALIGNED
#define EXT_TX_SIZES 4 // number of sizes that use extended transforms
#define EXT_TX_SETS_INTER 4 // Sets of transform selections for INTER
-#if CONFIG_ATC_NEWTXSETS && !CONFIG_ATC_REDUCED_TXSET
+#if CONFIG_ATC && !CONFIG_ATC_REDUCED_TXSET
#define EXT_TX_SETS_INTRA 2 // Sets of transform selections for INTRA
#else
#define EXT_TX_SETS_INTRA 3 // Sets of transform selections for INTRA
-#endif // CONFIG_ATC_NEWTXSETS && !CONFIG_ATC_REDUCED_TXSET
+#endif // CONFIG_ATC && !CONFIG_ATC_REDUCED_TXSET
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
#define INTRA_TX_SET1 7
#if CONFIG_ATC_REDUCED_TXSET
#define INTRA_TX_SET2 2
@@ -641,7 +641,7 @@
#else
#define INTRA_TX_SET1 6
#define INTRA_TX_SET2 4
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
enum {
UNIDIR_COMP_REFERENCE,
diff --git a/av1/common/scan.c b/av1/common/scan.c
index af2d30e..96bae5e 100644
--- a/av1/common/scan.c
+++ b/av1/common/scan.c
@@ -15,7 +15,7 @@
#include "av1/common/common_data.h"
#include "av1/common/scan.h"
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, default_scan_4x4[16]) = {
0, 4, 1, 8, 5, 2, 12, 9, 6, 3, 13, 10, 7, 14, 11, 15,
};
@@ -23,7 +23,7 @@
DECLARE_ALIGNED(16, static const int16_t,
default_scan_4x4[16]) = { 0, 1, 4, 8, 5, 2, 3, 6,
9, 12, 13, 10, 7, 11, 14, 15 };
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, mcol_scan_4x4[16]) = {
0, 4, 8, 12, 1, 5, 9, 13, 2, 6, 10, 14, 3, 7, 11, 15,
@@ -33,7 +33,7 @@
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
};
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, default_scan_4x8[32]) = {
0, 4, 1, 8, 5, 2, 12, 9, 6, 3, 16, 13, 10, 7, 20, 17,
14, 11, 24, 21, 18, 15, 28, 25, 22, 19, 29, 26, 23, 30, 27, 31,
@@ -43,7 +43,7 @@
0, 1, 4, 2, 5, 8, 3, 6, 9, 12, 7, 10, 13, 16, 11, 14,
17, 20, 15, 18, 21, 24, 19, 22, 25, 28, 23, 26, 29, 27, 30, 31,
};
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, mcol_scan_4x8[32]) = {
0, 4, 8, 12, 16, 20, 24, 28, 1, 5, 9, 13, 17, 21, 25, 29,
@@ -70,7 +70,7 @@
16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
};
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, default_scan_4x16[64]) = {
0, 4, 1, 8, 5, 2, 12, 9, 6, 3, 16, 13, 10, 7, 20, 17,
14, 11, 24, 21, 18, 15, 28, 25, 22, 19, 32, 29, 26, 23, 36, 33,
@@ -84,7 +84,7 @@
33, 36, 31, 34, 37, 40, 35, 38, 41, 44, 39, 42, 45, 48, 43, 46,
49, 52, 47, 50, 53, 56, 51, 54, 57, 60, 55, 58, 61, 59, 62, 63,
};
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, default_scan_16x4[64]) = {
0, 16, 1, 32, 17, 2, 48, 33, 18, 3, 49, 34, 19, 4, 50, 35,
@@ -121,7 +121,7 @@
12, 28, 44, 60, 13, 29, 45, 61, 14, 30, 46, 62, 15, 31, 47, 63,
};
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, default_scan_8x32[256]) = {
0, 8, 1, 16, 9, 2, 24, 17, 10, 3, 32, 25, 18, 11, 4,
40, 33, 26, 19, 12, 5, 48, 41, 34, 27, 20, 13, 6, 56, 49,
@@ -163,7 +163,7 @@
250, 223, 230, 237, 244, 251, 231, 238, 245, 252, 239, 246, 253, 247, 254,
255,
};
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, default_scan_32x8[256]) = {
0, 32, 1, 64, 33, 2, 96, 65, 34, 3, 128, 97, 66, 35, 4,
@@ -268,7 +268,7 @@
30, 62, 94, 126, 158, 190, 222, 254, 31, 63, 95, 127, 159, 191, 223, 255,
};
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, default_scan_8x8[64]) = {
0, 8, 1, 16, 9, 2, 24, 17, 10, 3, 32, 25, 18, 11, 4, 40,
33, 26, 19, 12, 5, 48, 41, 34, 27, 20, 13, 6, 56, 49, 42, 35,
@@ -282,7 +282,7 @@
35, 42, 49, 56, 57, 50, 43, 36, 29, 22, 15, 23, 30, 37, 44, 51,
58, 59, 52, 45, 38, 31, 39, 46, 53, 60, 61, 54, 47, 55, 62, 63
};
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, mcol_scan_8x8[64]) = {
0, 8, 16, 24, 32, 40, 48, 56, 1, 9, 17, 25, 33, 41, 49, 57,
@@ -298,7 +298,7 @@
48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
};
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, default_scan_8x16[128]) = {
0, 8, 1, 16, 9, 2, 24, 17, 10, 3, 32, 25, 18, 11, 4, 40,
33, 26, 19, 12, 5, 48, 41, 34, 27, 20, 13, 6, 56, 49, 42, 35,
@@ -321,7 +321,7 @@
114, 121, 87, 94, 101, 108, 115, 122, 95, 102, 109, 116, 123, 103, 110,
117, 124, 111, 118, 125, 119, 126, 127,
};
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, default_scan_16x8[128]) = {
0, 16, 1, 32, 17, 2, 48, 33, 18, 3, 64, 49, 34, 19, 4, 80,
@@ -380,7 +380,7 @@
120, 121, 122, 123, 124, 125, 126, 127,
};
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, default_scan_16x32[512]) = {
0, 16, 1, 32, 17, 2, 48, 33, 18, 3, 64, 49, 34, 19, 4,
80, 65, 50, 35, 20, 5, 96, 81, 66, 51, 36, 21, 6, 112, 97,
@@ -456,7 +456,7 @@
491, 506, 447, 462, 477, 492, 507, 463, 478, 493, 508, 479, 494, 509, 495,
510, 511,
};
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, default_scan_32x16[512]) = {
0, 32, 1, 64, 33, 2, 96, 65, 34, 3, 128, 97, 66, 35, 4,
@@ -645,7 +645,7 @@
510, 511,
};
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, default_scan_16x16[256]) = {
0, 16, 1, 32, 17, 2, 48, 33, 18, 3, 64, 49, 34, 19, 4,
80, 65, 50, 35, 20, 5, 96, 81, 66, 51, 36, 21, 6, 112, 97,
@@ -687,7 +687,7 @@
250, 251, 236, 221, 206, 191, 207, 222, 237, 252, 253, 238, 223, 239, 254,
255
};
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, mcol_scan_16x16[256]) = {
0, 16, 32, 48, 64, 80, 96, 112, 128, 144, 160, 176, 192, 208, 224, 240,
@@ -888,7 +888,7 @@
1014, 1015, 1016, 1017, 1018, 1019, 1020, 1021, 1022, 1023,
};
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, default_scan_32x32[1024]) = {
0, 32, 1, 64, 33, 2, 96, 65, 34, 3, 128, 97, 66, 35,
4, 160, 129, 98, 67, 36, 5, 192, 161, 130, 99, 68, 37, 6,
@@ -1047,9 +1047,9 @@
862, 831, 863, 894, 925, 956, 987, 1018, 1019, 988, 957, 926, 895,
927, 958, 989, 1020, 1021, 990, 959, 991, 1022, 1023
};
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t,
av1_default_iscan_4x4[16]) = { 0, 2, 5, 9, 1, 4, 8, 12,
3, 7, 11, 14, 6, 10, 13, 15 };
@@ -1057,7 +1057,7 @@
DECLARE_ALIGNED(16, static const int16_t,
av1_default_iscan_4x4[16]) = { 0, 1, 5, 6, 2, 4, 7, 12,
3, 8, 11, 13, 9, 10, 14, 15 };
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, av1_mcol_iscan_4x4[16]) = {
0, 4, 8, 12, 1, 5, 9, 13, 2, 6, 10, 14, 3, 7, 11, 15,
@@ -1067,7 +1067,7 @@
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
};
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, av1_default_iscan_4x8[32]) = {
0, 2, 5, 9, 1, 4, 8, 13, 3, 7, 12, 17, 6, 11, 16, 21,
10, 15, 20, 25, 14, 19, 24, 28, 18, 23, 27, 30, 22, 26, 29, 31
@@ -1077,7 +1077,7 @@
0, 1, 3, 6, 2, 4, 7, 10, 5, 8, 11, 14, 9, 12, 15, 18,
13, 16, 19, 22, 17, 20, 23, 26, 21, 24, 27, 29, 25, 28, 30, 31,
};
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, av1_mcol_iscan_4x8[32]) = {
0, 8, 16, 24, 1, 9, 17, 25, 2, 10, 18, 26, 3, 11, 19, 27,
@@ -1104,7 +1104,7 @@
16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
};
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, av1_default_iscan_4x16[64]) = {
0, 2, 5, 9, 1, 4, 8, 13, 3, 7, 12, 17, 6, 11, 16, 21,
10, 15, 20, 25, 14, 19, 24, 29, 18, 23, 28, 33, 22, 27, 32, 37,
@@ -1118,7 +1118,7 @@
29, 32, 35, 38, 33, 36, 39, 42, 37, 40, 43, 46, 41, 44, 47, 50,
45, 48, 51, 54, 49, 52, 55, 58, 53, 56, 59, 61, 57, 60, 62, 63,
};
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, av1_default_iscan_16x4[64]) = {
0, 2, 5, 9, 13, 17, 21, 25, 29, 33, 37, 41, 45, 49, 53, 57,
@@ -1155,7 +1155,7 @@
3, 7, 11, 15, 19, 23, 27, 31, 35, 39, 43, 47, 51, 55, 59, 63,
};
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, av1_default_iscan_8x32[256]) = {
0, 2, 5, 9, 14, 20, 27, 35, 1, 4, 8, 13, 19, 26, 34,
43, 3, 7, 12, 18, 25, 33, 42, 51, 6, 11, 17, 24, 32, 41,
@@ -1197,7 +1197,7 @@
219, 226, 233, 239, 244, 248, 251, 253, 227, 234, 240, 245, 249, 252, 254,
255,
};
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, av1_default_iscan_32x8[256]) = {
0, 2, 5, 9, 14, 20, 27, 35, 43, 51, 59, 67, 75, 83, 91,
@@ -1316,7 +1316,7 @@
48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63,
};
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, av1_default_iscan_8x8[64]) = {
0, 2, 5, 9, 14, 20, 27, 35, 1, 4, 8, 13, 19, 26, 34, 42,
3, 7, 12, 18, 25, 33, 41, 48, 6, 11, 17, 24, 32, 40, 47, 53,
@@ -1330,9 +1330,9 @@
10, 19, 23, 32, 39, 45, 52, 54, 20, 22, 33, 38, 46, 51, 55, 60,
21, 34, 37, 47, 50, 56, 59, 61, 35, 36, 48, 49, 57, 58, 62, 63
};
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, av1_default_iscan_8x16[128]) = {
0, 2, 5, 9, 14, 20, 27, 35, 1, 4, 8, 13, 19, 26, 34, 43,
3, 7, 12, 18, 25, 33, 42, 51, 6, 11, 17, 24, 32, 41, 50, 59,
@@ -1354,7 +1354,7 @@
75, 82, 89, 96, 103, 109, 114, 118, 83, 90, 97, 104, 110, 115, 119, 122,
91, 98, 105, 111, 116, 120, 123, 125, 99, 106, 112, 117, 121, 124, 126, 127,
};
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, av1_default_iscan_16x8[128]) = {
0, 2, 5, 9, 14, 20, 27, 35, 43, 51, 59, 67, 75, 83, 91, 99,
@@ -1413,7 +1413,7 @@
120, 121, 122, 123, 124, 125, 126, 127,
};
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, av1_default_iscan_16x32[512]) = {
0, 2, 5, 9, 14, 20, 27, 35, 44, 54, 65, 77, 90, 104, 119,
135, 1, 4, 8, 13, 19, 26, 34, 43, 53, 64, 76, 89, 103, 118,
@@ -1489,7 +1489,7 @@
509, 391, 406, 420, 433, 445, 456, 466, 475, 483, 490, 496, 501, 505, 508,
510, 511,
};
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, av1_default_iscan_32x16[512]) = {
0, 2, 5, 9, 14, 20, 27, 35, 44, 54, 65, 77, 90, 104, 119,
@@ -1718,7 +1718,7 @@
255,
};
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, av1_default_iscan_16x16[256]) = {
0, 2, 5, 9, 14, 20, 27, 35, 44, 54, 65, 77, 90, 104, 119,
135, 1, 4, 8, 13, 19, 26, 34, 43, 53, 64, 76, 89, 103, 118,
@@ -1760,7 +1760,7 @@
135, 136, 164, 165, 189, 190, 210, 211, 227, 228, 240, 241, 249, 250, 254,
255
};
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, av1_mcol_iscan_32x32[1024]) = {
0, 32, 64, 96, 128, 160, 192, 224, 256, 288, 320, 352, 384, 416,
@@ -1921,7 +1921,7 @@
1014, 1015, 1016, 1017, 1018, 1019, 1020, 1021, 1022, 1023,
};
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
DECLARE_ALIGNED(16, static const int16_t, av1_default_iscan_32x32[1024]) = {
0, 2, 5, 9, 14, 20, 27, 35, 44, 54, 65, 77, 90,
104, 119, 135, 152, 170, 189, 209, 230, 252, 275, 299, 324, 350,
@@ -2085,7 +2085,7 @@
748, 792, 793, 833, 834, 870, 871, 903, 904, 932, 933, 957, 958,
978, 979, 995, 996, 1008, 1009, 1017, 1018, 1022, 1023
};
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
const SCAN_ORDER av1_default_scan_orders[TX_SIZES] = {
{ default_scan_4x4, av1_default_iscan_4x4 },
diff --git a/av1/common/token_cdfs.h b/av1/common/token_cdfs.h
index 5a21ffb..b70a2dd 100644
--- a/av1/common/token_cdfs.h
+++ b/av1/common/token_cdfs.h
@@ -1198,7 +1198,7 @@
{ AOM_CDF4(13384, 20248, 26029) } }
};
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
static const aom_cdf_prob
av1_default_coeff_lps_multi_cdfs[TOKEN_CDF_Q_CTXS][PLANE_TYPES]
[LEVEL_CONTEXTS][CDF_SIZE(BR_CDF_SIZE)] = {
@@ -2024,7 +2024,7 @@
{ AOM_CDF4(8192, 16384, 24576) }, { AOM_CDF4(8192, 16384, 24576) },
{ AOM_CDF4(8192, 16384, 24576) } } } }
};
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
static const aom_cdf_prob av1_default_coeff_base_multi_cdfs_idtx
[TOKEN_CDF_Q_CTXS][IDTX_SIG_COEF_CONTEXTS]
@@ -2085,7 +2085,7 @@
{ AOM_CDF4(2674, 5476, 12215) },
{ AOM_CDF4(1568, 3054, 5228) } } };
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
static const aom_cdf_prob av1_default_coeff_base_lf_multi_cdfs
[TOKEN_CDF_Q_CTXS][TX_SIZES][PLANE_TYPES][LF_SIG_COEF_CONTEXTS]
[CDF_SIZE(LF_BASE_SYMBOLS)] = {
@@ -6584,7 +6584,7 @@
{ AOM_CDF3(10923, 21845) },
{ AOM_CDF3(10923, 21845) },
{ AOM_CDF3(10923, 21845) } } } } };
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
#if CONFIG_PAR_HIDING
static const aom_cdf_prob
av1_default_coeff_base_ph_cdfs[TOKEN_CDF_Q_CTXS][COEFF_BASE_PH_CONTEXTS]
diff --git a/av1/common/txb_common.h b/av1/common/txb_common.h
index 0c4df1b..0b82352 100644
--- a/av1/common/txb_common.h
+++ b/av1/common/txb_common.h
@@ -109,16 +109,16 @@
AOMMIN(levels[pos + stride], MAX_BASE_BR_RANGE) +
AOMMIN(levels[pos + 1 + stride], MAX_BASE_BR_RANGE);
mag = AOMMIN((mag + 1) >> 1, 6);
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
return mag;
#else
//((row | col) < 2) is equivalent to ((row < 2) && (col < 2))
if ((row | col) < 2) return mag + 7;
return mag + 14;
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
// This function returns the low range context index for
// the low-frequency region for the EOB coefficient.
static AOM_FORCE_INLINE int get_br_ctx_lf_eob(const int c, // raster order
@@ -139,9 +139,9 @@
return 7;
return 14;
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
// This function returns the low range context index/increment for the
// coefficients residing in the low-frequency region for 2D transforms.
// Not used for the DC term.
@@ -251,9 +251,9 @@
return mag + 14;
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
static const uint8_t clip_max5[256] = {
0, 1, 2, 3, 4, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
@@ -266,7 +266,7 @@
5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5
};
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
static const uint8_t clip_max3[256] = {
0, 1, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
@@ -321,7 +321,7 @@
return sign_ctx;
}
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
// This function returns the template sum of absolute values
// for coefficient coding for the low-frequency region.
static AOM_FORCE_INLINE int get_nz_mag_lf(const uint8_t *const levels,
@@ -346,7 +346,7 @@
}
return mag;
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
// This function returns the template sum of absolute values
// for coefficient coding for the higher-frequency default region.
@@ -399,7 +399,7 @@
return ctx + 7;
}
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
// This function returns the base range context index/increment for the
// coefficients residing in the low-frequency region for 1D/2D transforms.
static AOM_FORCE_INLINE int get_nz_map_ctx_from_stats_lf(
@@ -449,7 +449,7 @@
}
return 0;
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
// This function returns the base range context index/increment for the
// coefficients residing in the higher-frequency region for 1D/2D transforms.
@@ -457,9 +457,9 @@
const int stats,
const int coeff_idx, // raster order
const int bwl,
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
const TX_SIZE tx_size,
-#endif // !CONFIG_ATC_COEFCODING
+#endif // !CONFIG_ATC
const TX_CLASS tx_class) {
// tx_class == 0(TX_CLASS_2D)
if ((tx_class | coeff_idx) == 0) return 0;
@@ -467,7 +467,7 @@
ctx = AOMMIN(ctx, 4);
switch (tx_class) {
case TX_CLASS_2D: {
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = coeff_idx >> bwl;
const int col = coeff_idx - (row << bwl);
if (row + col < 6) return ctx;
@@ -486,33 +486,33 @@
// if (row + col < 4) return 5 + ctx + 1;
// return 21 + ctx;
return ctx + av1_nz_map_ctx_offset[tx_size][coeff_idx];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
case TX_CLASS_HORIZ: {
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
return ctx + 15;
#else
const int row = coeff_idx >> bwl;
const int col = coeff_idx - (row << bwl);
return ctx + nz_map_ctx_offset_1d[col];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
case TX_CLASS_VERT: {
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
return ctx + 15;
#else
const int row = coeff_idx >> bwl;
return ctx + nz_map_ctx_offset_1d[row];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
default: break;
}
return 0;
}
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
typedef aom_cdf_prob (*base_lf_cdf_arr)[CDF_SIZE(LF_BASE_SYMBOLS)];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
typedef aom_cdf_prob (*base_cdf_arr)[CDF_SIZE(4)];
typedef aom_cdf_prob (*br_cdf_arr)[CDF_SIZE(BR_CDF_SIZE)];
#if CONFIG_PAR_HIDING
@@ -585,7 +585,7 @@
return ctx + 7;
}
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
// This function returns the base range context index/increment for the
// coefficients residing in the low-frequency region for 2D transforms.
static INLINE int get_lower_levels_ctx_lf_2d(const uint8_t *levels,
@@ -621,14 +621,14 @@
get_nz_mag_lf(levels + get_padded_idx(coeff_idx, bwl), bwl, tx_class);
return get_nz_map_ctx_from_stats_lf(stats, coeff_idx, bwl, tx_class);
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
static INLINE int get_lower_levels_ctx_2d(const uint8_t *levels, int coeff_idx,
int bwl
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
,
TX_SIZE tx_size
-#endif // !CONFIG_ATC_COEFCODING
+#endif // !CONFIG_ATC
) {
assert(coeff_idx > 0);
int mag;
@@ -641,7 +641,7 @@
mag += AOMMIN(levels[(2 << bwl) + (2 << TX_PAD_HOR_LOG2)], 3); // { 2, 0 }
const int ctx = AOMMIN((mag + 1) >> 1, 4);
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = coeff_idx >> bwl;
const int col = coeff_idx - (row << bwl);
if (row + col < 6) return ctx;
@@ -649,10 +649,10 @@
return ctx + 10;
#else
return ctx + av1_nz_map_ctx_offset[tx_size][coeff_idx];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
// This function determines the limits to separate the low-frequency
// coefficient coding region from the higher-frequency default
// region. It is based on the diagonal sum (row+col) or row, columns
@@ -670,35 +670,35 @@
}
return limits;
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
static AOM_FORCE_INLINE int get_lower_levels_ctx(const uint8_t *levels,
int coeff_idx, int bwl,
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
TX_SIZE tx_size,
-#endif // !CONFIG_ATC_COEFCODING
+#endif // !CONFIG_ATC
TX_CLASS tx_class) {
const int stats =
get_nz_mag(levels + get_padded_idx(coeff_idx, bwl), bwl, tx_class);
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
return get_nz_map_ctx_from_stats(stats, coeff_idx, bwl, tx_class);
#else
return get_nz_map_ctx_from_stats(stats, coeff_idx, bwl, tx_size, tx_class);
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
static INLINE int get_lower_levels_ctx_general(int is_last, int scan_idx,
int bwl, int height,
const uint8_t *levels,
int coeff_idx,
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
TX_SIZE tx_size,
-#endif // !CONFIG_ATC_COEFCODING
+#endif // !CONFIG_ATC
TX_CLASS tx_class
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
,
int plane
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
) {
if (is_last) {
if (scan_idx == 0) return 0;
@@ -706,7 +706,7 @@
if (scan_idx <= (height << bwl) >> 2) return 2;
return 3;
}
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = coeff_idx >> bwl;
const int col = coeff_idx - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -717,7 +717,7 @@
}
#else
return get_lower_levels_ctx(levels, coeff_idx, bwl, tx_size, tx_class);
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
static INLINE void set_dc_sign(int *cul_level, int dc_val) {
diff --git a/av1/common/x86/av1_inv_txfm_ssse3.h b/av1/common/x86/av1_inv_txfm_ssse3.h
index 25b45bd..7704498 100644
--- a/av1/common/x86/av1_inv_txfm_ssse3.h
+++ b/av1/common/x86/av1_inv_txfm_ssse3.h
@@ -68,11 +68,11 @@
};
DECLARE_ALIGNED(16, static const int16_t, av1_eob_to_eobxy_8x16_default[16]) = {
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
0x0707, 0x0707, 0x0707, 0x0707, 0x0f07, 0x0f07, 0x0f07, 0x0f07,
#else
0x0707, 0x0707, 0x0707, 0x0707, 0x0707, 0x0f07, 0x0f07, 0x0f07,
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
0x0f07, 0x0f07, 0x0f07, 0x0f07, 0x0f07, 0x0f07, 0x0f07, 0x0f07,
};
@@ -83,11 +83,11 @@
DECLARE_ALIGNED(16, static const int16_t,
av1_eob_to_eobxy_16x32_default[32]) = {
0x0707, 0x0707, 0x0f0f, 0x0f0f, 0x0f0f, 0x0f0f, 0x0f0f, 0x0f0f,
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
0x1f0f, 0x1f0f, 0x1f0f, 0x1f0f, 0x1f0f, 0x1f0f, 0x1f0f, 0x1f0f,
#else
0x0f0f, 0x1f0f, 0x1f0f, 0x1f0f, 0x1f0f, 0x1f0f, 0x1f0f, 0x1f0f,
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
0x1f0f, 0x1f0f, 0x1f0f, 0x1f0f, 0x1f0f, 0x1f0f, 0x1f0f, 0x1f0f,
0x1f0f, 0x1f0f, 0x1f0f, 0x1f0f, 0x1f0f, 0x1f0f, 0x1f0f, 0x1f0f,
};
@@ -99,13 +99,13 @@
};
DECLARE_ALIGNED(16, static const int16_t, av1_eob_to_eobxy_8x32_default[32]) = {
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
0x0707, 0x0707, 0x0707, 0x0707, 0x0f07, 0x0f07, 0x0f07, 0x0f07,
0x0f07, 0x0f07, 0x0f07, 0x0f07, 0x1f07, 0x1f07, 0x1f07, 0x1f07,
#else
0x0707, 0x0707, 0x0707, 0x0707, 0x0707, 0x0f07, 0x0f07, 0x0f07,
0x0f07, 0x0f07, 0x0f07, 0x0f07, 0x0f07, 0x1f07, 0x1f07, 0x1f07,
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
0x1f07, 0x1f07, 0x1f07, 0x1f07, 0x1f07, 0x1f07, 0x1f07, 0x1f07,
0x1f07, 0x1f07, 0x1f07, 0x1f07, 0x1f07, 0x1f07, 0x1f07, 0x1f07,
};
diff --git a/av1/decoder/decodemv.c b/av1/decoder/decodemv.c
index f736169..a0eaf64 100644
--- a/av1/decoder/decodemv.c
+++ b/av1/decoder/decodemv.c
@@ -1256,7 +1256,7 @@
? fimode_to_intradir[mbmi->filter_intra_mode_info
.filter_intra_mode]
: mbmi->mode;
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
#if CONFIG_ATC_REDUCED_TXSET
const int size_info = av1_size_class[tx_size];
*tx_type = av1_tx_idx_to_type(
@@ -1281,7 +1281,7 @@
*tx_type = av1_ext_tx_inv_intra[tx_set_type][aom_read_symbol(
r, ec_ctx->intra_ext_tx_cdf[eset][square_tx_size][intra_mode],
av1_num_ext_tx_set_intra[tx_set_type], ACCT_INFO("tx_type"))];
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
}
}
}
diff --git a/av1/decoder/decodetxb.c b/av1/decoder/decodetxb.c
index be37578..cb43098 100644
--- a/av1/decoder/decodetxb.c
+++ b/av1/decoder/decodetxb.c
@@ -71,17 +71,17 @@
static INLINE void read_coeffs_reverse_2d(
aom_reader *r,
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
TX_SIZE tx_size,
-#endif // !CONFIG_ATC_COEFCODING
+#endif // !CONFIG_ATC
int start_si, int end_si, const int16_t *scan, int bwl, uint8_t *levels,
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
base_lf_cdf_arr base_lf_cdf, br_cdf_arr br_lf_cdf, int plane,
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
base_cdf_arr base_cdf, br_cdf_arr br_cdf) {
for (int c = end_si; c >= start_si; --c) {
const int pos = scan[c];
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
int level = 0;
const int row = pos >> bwl;
const int col = pos - (row << bwl);
@@ -130,27 +130,27 @@
if (k < BR_CDF_SIZE - 1) break;
}
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
levels[get_padded_idx(pos, bwl)] = level;
}
}
static INLINE void read_coeffs_reverse(aom_reader *r,
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
TX_SIZE tx_size,
-#endif // !CONFIG_ATC_COEFCODING
+#endif // !CONFIG_ATC
TX_CLASS tx_class, int start_si,
int end_si, const int16_t *scan, int bwl,
uint8_t *levels,
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
base_lf_cdf_arr base_lf_cdf,
br_cdf_arr br_lf_cdf, int plane,
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
base_cdf_arr base_cdf,
br_cdf_arr br_cdf) {
for (int c = end_si; c >= start_si; --c) {
const int pos = scan[c];
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
int level = 0;
const int row = pos >> bwl;
const int col = pos - (row << bwl);
@@ -200,7 +200,7 @@
if (k < BR_CDF_SIZE - 1) break;
}
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
levels[get_padded_idx(pos, bwl)] = level;
}
}
@@ -773,7 +773,7 @@
const int c = *eob - 1;
const int pos = scan[c];
const int coeff_ctx = get_lower_levels_ctx_eob(bwl, height, c);
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
int level = 0;
const int row = pos >> bwl;
const int col = pos - (row << bwl);
@@ -828,7 +828,7 @@
if (k < BR_CDF_SIZE - 1) break;
}
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
levels[get_padded_idx(pos, bwl)] = level;
}
#if CONFIG_PAR_HIDING
@@ -839,21 +839,21 @@
bool is_hidden = false;
#endif // CONFIG_PAR_HIDING
if (*eob > 1) {
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
base_lf_cdf_arr base_lf_cdf =
ec_ctx->coeff_base_lf_cdf[txs_ctx][plane_type];
br_cdf_arr br_lf_cdf = ec_ctx->coeff_br_lf_cdf[plane_type];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
base_cdf_arr base_cdf = ec_ctx->coeff_base_cdf[txs_ctx][plane_type];
br_cdf_arr br_cdf =
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
ec_ctx->coeff_br_cdf[plane_type];
#else
ec_ctx->coeff_br_cdf[AOMMIN(txs_ctx, TX_32X32)][plane_type];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
#if CONFIG_PAR_HIDING
if (tx_class == TX_CLASS_2D) {
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
read_coeffs_reverse_2d(r, 1, *eob - 2, scan, bwl, levels, base_lf_cdf,
br_lf_cdf, plane, base_cdf, br_cdf);
if (enable_parity_hiding) {
@@ -897,9 +897,9 @@
read_coeffs_reverse(r, tx_size, tx_class, 0, 0, scan, bwl, levels,
base_cdf, br_cdf);
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
} else {
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
read_coeffs_reverse(r, tx_class, 1, *eob - 2, scan, bwl, levels,
base_lf_cdf, br_lf_cdf, plane, base_cdf, br_cdf);
if (enable_parity_hiding) {
@@ -943,11 +943,11 @@
read_coeffs_reverse(r, tx_size, tx_class, 0, 0, scan, bwl, levels,
base_cdf, br_cdf);
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
#else
if (tx_class == TX_CLASS_2D) {
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
read_coeffs_reverse_2d(r, 1, *eob - 2, scan, bwl, levels, base_lf_cdf,
br_lf_cdf, plane, base_cdf, br_cdf);
read_coeffs_reverse(r, tx_class, 0, 0, scan, bwl, levels, base_lf_cdf,
@@ -957,15 +957,15 @@
base_cdf, br_cdf);
read_coeffs_reverse(r, tx_size, tx_class, 0, 0, scan, bwl, levels,
base_cdf, br_cdf);
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
} else {
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
read_coeffs_reverse(r, tx_class, 0, *eob - 2, scan, bwl, levels,
base_lf_cdf, br_lf_cdf, plane, base_cdf, br_cdf);
#else
read_coeffs_reverse(r, tx_size, tx_class, 0, *eob - 2, scan, bwl, levels,
base_cdf, br_cdf);
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
#endif // CONFIG_PAR_HIDING
}
@@ -1016,7 +1016,7 @@
#endif // CONFIG_CONTEXT_DERIVATION
}
#if CONFIG_PAR_HIDING
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
if (is_hidden && c == 0) {
if (level >= (MAX_BASE_BR_RANGE << 1)) {
level += (read_golomb(xd, r) << 1);
@@ -1045,9 +1045,9 @@
level += read_golomb(xd, r);
}
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
#else
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = pos >> bwl;
const int col = pos - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -1064,7 +1064,7 @@
if (level >= MAX_BASE_BR_RANGE) {
level += read_golomb(xd, r);
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
#endif // CONFIG_PAR_HIDING
if (c == 0) dc_val = sign ? -level : level;
diff --git a/av1/encoder/bitstream.c b/av1/encoder/bitstream.c
index baa2f20..03de32b 100644
--- a/av1/encoder/bitstream.c
+++ b/av1/encoder/bitstream.c
@@ -1295,14 +1295,14 @@
) {
#endif // CONFIG_ATC_DCTX_ALIGNED
MB_MODE_INFO *mbmi = xd->mi[0];
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
PREDICTION_MODE intra_dir;
if (mbmi->filter_intra_mode_info.use_filter_intra)
intra_dir =
fimode_to_intradir[mbmi->filter_intra_mode_info.filter_intra_mode];
else
intra_dir = mbmi->mode;
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
const FeatureFlags *const features = &cm->features;
const int is_inter = is_inter_block(mbmi, xd->tree_type);
if (get_ext_tx_types(tx_size, is_inter, features->reduced_tx_set_used) > 1 &&
@@ -1319,7 +1319,7 @@
// eset == 0 should correspond to a set with only DCT_DCT and there
// is no need to send the tx_type
assert(eset > 0);
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
const int size_info = av1_size_class[tx_size];
if (!is_inter) {
const int mode_info = av1_md_class[intra_dir];
@@ -1331,7 +1331,7 @@
}
#else
assert(av1_ext_tx_used[tx_set_type][get_primary_tx_type(tx_type)]);
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
if (is_inter) {
#if CONFIG_ATC_DCTX_ALIGNED
const int eob_tx_ctx = get_lp2tx_ctx(tx_size, get_txb_bwl(tx_size), eob);
@@ -1348,16 +1348,16 @@
if (mbmi->fsc_mode[xd->tree_type == CHROMA_PART]) {
return;
}
-#if !CONFIG_ATC_NEWTXSETS
+#if !CONFIG_ATC
PREDICTION_MODE intra_dir;
if (mbmi->filter_intra_mode_info.use_filter_intra)
intra_dir =
fimode_to_intradir[mbmi->filter_intra_mode_info.filter_intra_mode];
else
intra_dir = mbmi->mode;
-#endif // !CONFIG_ATC_NEWTXSETS
+#endif // !CONFIG_ATC
aom_write_symbol(
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
w,
av1_tx_type_to_idx(get_primary_tx_type(tx_type), tx_set_type,
intra_dir, size_info),
@@ -1375,7 +1375,7 @@
w, av1_ext_tx_ind_intra[tx_set_type][get_primary_tx_type(tx_type)],
ec_ctx->intra_ext_tx_cdf[eset][square_tx_size][intra_dir],
av1_num_ext_tx_set_intra[tx_set_type]);
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
}
}
}
diff --git a/av1/encoder/block.h b/av1/encoder/block.h
index fa3dbce..f827fb2 100644
--- a/av1/encoder/block.h
+++ b/av1/encoder/block.h
@@ -158,7 +158,7 @@
//! Cost to skip txfm for the current AOM_PLANE_V txfm block.
int v_txb_skip_cost[V_TXB_SKIP_CONTEXTS][2];
#endif // CONFIG_CONTEXT_DERIVATION
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
//! Cost for encoding the base_eob level of a low-frequency coefficient
int base_lf_eob_cost[SIG_COEF_CONTEXTS_EOB][LF_BASE_SYMBOLS - 1];
//! Cost for encoding the base level of a low-frequency coefficient
@@ -166,7 +166,7 @@
//! Cost for encoding an increment to the low-frequency coefficient
int lps_lf_cost[LF_LEVEL_CONTEXTS]
[COEFF_BASE_RANGE + 1 + COEFF_BASE_RANGE + 1];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
#if CONFIG_PAR_HIDING
//! Cost for encoding the base level of a parity-hidden coefficient
int base_ph_cost[COEFF_BASE_PH_CONTEXTS][4];
diff --git a/av1/encoder/encodeframe_utils.c b/av1/encoder/encodeframe_utils.c
index 2791f2e..08949b2 100644
--- a/av1/encoder/encodeframe_utils.c
+++ b/av1/encoder/encodeframe_utils.c
@@ -1260,13 +1260,13 @@
#if CONFIG_ATC_DCTX_ALIGNED
AVERAGE_CDF(ctx_left->coeff_base_bob_cdf, ctx_tr->coeff_base_bob_cdf, 3);
#endif // CONFIG_ATC_DCTX_ALIGNED
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
AVERAGE_CDF(ctx_left->coeff_base_lf_cdf, ctx_tr->coeff_base_lf_cdf,
LF_BASE_SYMBOLS);
AVERAGE_CDF(ctx_left->coeff_base_lf_eob_cdf, ctx_tr->coeff_base_lf_eob_cdf,
LF_BASE_SYMBOLS - 1);
AVERAGE_CDF(ctx_left->coeff_br_lf_cdf, ctx_tr->coeff_br_lf_cdf, BR_CDF_SIZE);
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
AVERAGE_CDF(ctx_left->coeff_base_cdf, ctx_tr->coeff_base_cdf, 4);
AVERAGE_CDF(ctx_left->idtx_sign_cdf, ctx_tr->idtx_sign_cdf, 2);
AVERAGE_CDF(ctx_left->coeff_base_cdf_idtx, ctx_tr->coeff_base_cdf_idtx, 4);
@@ -1540,10 +1540,10 @@
}
AVG_CDF_STRIDE(ctx_left->intra_ext_tx_cdf[1], ctx_tr->intra_ext_tx_cdf[1],
INTRA_TX_SET1, CDF_SIZE(TX_TYPES));
-#if !(CONFIG_ATC_NEWTXSETS && !CONFIG_ATC_REDUCED_TXSET)
+#if !(CONFIG_ATC && !CONFIG_ATC_REDUCED_TXSET)
AVG_CDF_STRIDE(ctx_left->intra_ext_tx_cdf[2], ctx_tr->intra_ext_tx_cdf[2],
INTRA_TX_SET2, CDF_SIZE(TX_TYPES));
-#endif // !(CONFIG_ATC_NEWTXSETS && !CONFIG_ATC_REDUCED_TXSET)
+#endif // !(CONFIG_ATC && !CONFIG_ATC_REDUCED_TXSET)
AVG_CDF_STRIDE(ctx_left->inter_ext_tx_cdf[1], ctx_tr->inter_ext_tx_cdf[1], 16,
CDF_SIZE(TX_TYPES));
AVG_CDF_STRIDE(ctx_left->inter_ext_tx_cdf[2], ctx_tr->inter_ext_tx_cdf[2], 12,
diff --git a/av1/encoder/encoder.h b/av1/encoder/encoder.h
index b8212cb..e533bdc 100644
--- a/av1/encoder/encoder.h
+++ b/av1/encoder/encoder.h
@@ -1318,7 +1318,7 @@
unsigned int eob_multi512[TOKEN_CDF_Q_CTXS][PLANE_TYPES][2][10];
unsigned int eob_multi1024[TOKEN_CDF_Q_CTXS][PLANE_TYPES][2][11];
#endif // CONFIG_ATC_DCTX_ALIGNED
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
unsigned int coeff_lps_lf[PLANE_TYPES][BR_CDF_SIZE - 1][LF_LEVEL_CONTEXTS][2];
unsigned int coeff_base_lf_multi[TOKEN_CDF_Q_CTXS][TX_SIZES][PLANE_TYPES]
[LF_SIG_COEF_CONTEXTS][LF_BASE_SYMBOLS];
@@ -1332,7 +1332,7 @@
#else
unsigned int coeff_lps_multi[TOKEN_CDF_Q_CTXS][TX_SIZES][PLANE_TYPES]
[LEVEL_CONTEXTS][BR_CDF_SIZE];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
#if CONFIG_PAR_HIDING
unsigned int coeff_base_ph_multi[TOKEN_CDF_Q_CTXS][COEFF_BASE_PH_CONTEXTS]
[NUM_BASE_LEVELS + 2];
diff --git a/av1/encoder/encodetxb.c b/av1/encoder/encodetxb.c
index 71c814b..388a753 100644
--- a/av1/encoder/encodetxb.c
+++ b/av1/encoder/encodetxb.c
@@ -373,7 +373,7 @@
return 0;
}
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
// Golomb cost of coding bypass coded level values in the
// low-frequency region.
static INLINE int get_golomb_cost_lf(int abs_qc) {
@@ -414,7 +414,7 @@
}
return coeff_lps[base_range] + golomb_bits;
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
static INLINE int get_br_cost_with_diff(tran_low_t level, const int *coeff_lps,
int *diff) {
@@ -446,23 +446,23 @@
const int coeff_idx, const int bwl,
const int height, const int scan_idx,
const int is_eob,
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
const TX_SIZE tx_size,
-#endif // !CONFIG_ATC_COEFCODING
+#endif // !CONFIG_ATC
const TX_CLASS tx_class
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
,
const int plane) {
#else
) {
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
if (is_eob) {
if (scan_idx == 0) return 0;
if (scan_idx <= (height << bwl) / 8) return 1;
if (scan_idx <= (height << bwl) / 4) return 2;
return 3;
}
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
int stats = 0;
const int row = coeff_idx >> bwl;
const int col = coeff_idx - (row << bwl);
@@ -479,7 +479,7 @@
const int stats =
get_nz_mag(levels + get_padded_idx(coeff_idx, bwl), bwl, tx_class);
return get_nz_map_ctx_from_stats(stats, coeff_idx, bwl, tx_size, tx_class);
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
static INLINE int get_nz_map_ctx_skip(const uint8_t *const levels,
@@ -573,28 +573,28 @@
const int16_t *const scan, const uint16_t eob,
const TX_SIZE tx_size, const TX_CLASS tx_class,
int8_t *const coeff_contexts
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
,
const int plane) {
#else
) {
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
const int bwl = get_txb_bwl(tx_size);
const int height = get_txb_high(tx_size);
for (int i = 0; i < eob; ++i) {
const int pos = scan[i];
coeff_contexts[pos] =
get_nz_map_ctx(levels, pos, bwl, height, i, i == eob - 1,
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
tx_size,
-#endif // !CONFIG_ATC_COEFCODING
+#endif // !CONFIG_ATC
tx_class
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
,
plane);
#else
);
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
}
@@ -1015,10 +1015,10 @@
const int16_t *const scan = scan_order->scan;
DECLARE_ALIGNED(16, int8_t, coeff_contexts[MAX_TX_SQUARE]);
av1_get_nz_map_contexts(levels, scan, eob, tx_size, tx_class, coeff_contexts
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
,
plane
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
);
const int bwl = get_txb_bwl(tx_size);
@@ -1037,7 +1037,7 @@
const tran_low_t v = tcoeff[pos];
const tran_low_t level = abs(v);
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
if (c == eob - 1) {
const int row = pos >> bwl;
const int col = pos - (row << bwl);
@@ -1075,9 +1075,9 @@
aom_write_symbol(w, AOMMIN(level, 3),
ec_ctx->coeff_base_cdf[txs_ctx][plane_type][coeff_ctx],
4);
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = pos >> bwl;
const int col = pos - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -1118,7 +1118,7 @@
if (k < BR_CDF_SIZE - 1) break;
}
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
#if CONFIG_PAR_HIDING
@@ -1144,7 +1144,7 @@
const tran_low_t v = tcoeff[pos];
const tran_low_t level = abs(v);
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
if (c == eob - 1) {
const int row = pos >> bwl;
const int col = pos - (row << bwl);
@@ -1182,9 +1182,9 @@
aom_write_symbol(w, AOMMIN(level, 3),
ec_ctx->coeff_base_cdf[txs_ctx][plane_type][coeff_ctx],
4);
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = pos >> bwl;
const int col = pos - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -1225,7 +1225,7 @@
if (k < BR_CDF_SIZE - 1) break;
}
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
#endif // CONFIG_PAR_HIDING
@@ -1274,7 +1274,7 @@
#endif // CONFIG_CONTEXT_DERIVATION
}
#if CONFIG_PAR_HIDING
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
if (is_hidden && c == 0) {
int q_index = level >> 1;
if (q_index > COEFF_BASE_RANGE + NUM_BASE_LEVELS)
@@ -1301,9 +1301,9 @@
if (level > COEFF_BASE_RANGE + NUM_BASE_LEVELS)
write_golomb(w, level - COEFF_BASE_RANGE - 1 - NUM_BASE_LEVELS);
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
#else
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int pos = scan[c];
const int row = pos >> bwl;
const int col = pos - (row << bwl);
@@ -1318,7 +1318,7 @@
#else
if (level > COEFF_BASE_RANGE + NUM_BASE_LEVELS)
write_golomb(w, level - COEFF_BASE_RANGE - 1 - NUM_BASE_LEVELS);
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
#endif // CONFIG_PAR_HIDING
}
}
@@ -1739,18 +1739,18 @@
#endif // CONFIG_ATC_DCTX_ALIGNED
av1_get_nz_map_contexts(levels, scan, eob, tx_size, tx_class, coeff_contexts
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
,
plane
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
);
const int(*lps_cost)[COEFF_BASE_RANGE + 1 + COEFF_BASE_RANGE + 1] =
coeff_costs->lps_cost;
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int(*lps_lf_cost)[COEFF_BASE_RANGE + 1 + COEFF_BASE_RANGE + 1] =
coeff_costs->lps_lf_cost;
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
int c = eob - 1;
{
const int pos = scan[c];
@@ -1758,7 +1758,7 @@
const int sign = AOMSIGN(v);
const int level = (v ^ sign) - sign;
const int coeff_ctx = coeff_contexts[pos];
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = pos >> bwl;
const int col = pos - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -1771,11 +1771,11 @@
}
#else
cost += coeff_costs->base_eob_cost[coeff_ctx][AOMMIN(level, 3) - 1];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
if (v) {
// sign bit cost
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
if (limits) {
if (level > LF_NUM_BASE_LEVELS) {
const int ctx = get_br_ctx_lf_eob(pos, tx_class);
@@ -1792,7 +1792,7 @@
const int ctx = get_br_ctx_eob(pos, bwl, tx_class);
cost += get_br_cost(level, lps_cost[ctx]);
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
if (c) {
#if CONFIG_CONTEXT_DERIVATION
if (plane == AOM_PLANE_V) {
@@ -1821,16 +1821,16 @@
}
}
}
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int(*base_lf_cost)[LF_BASE_SYMBOLS * 2] = coeff_costs->base_lf_cost;
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
const int(*base_cost)[8] = coeff_costs->base_cost;
for (c = eob - 2; c >= 1; --c) {
const int pos = scan[c];
const int coeff_ctx = coeff_contexts[pos];
const tran_low_t v = qcoeff[pos];
const int level = abs(v);
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = pos >> bwl;
const int col = pos - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -1841,7 +1841,7 @@
}
#else
cost += base_cost[coeff_ctx][AOMMIN(level, 3)];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
if (v) {
// sign bit cost
#if CONFIG_CONTEXT_DERIVATION
@@ -1855,7 +1855,7 @@
#else
cost += av1_cost_literal(1);
#endif // CONFIG_CONTEXT_DERIVATION
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
if (limits) {
if (level > LF_NUM_BASE_LEVELS) {
const int ctx = get_br_lf_ctx(levels, pos, bwl, tx_class);
@@ -1872,7 +1872,7 @@
const int ctx = get_br_ctx(levels, pos, bwl, tx_class);
cost += get_br_cost(level, lps_cost[ctx]);
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
}
// c == 0 after previous loop
@@ -1908,7 +1908,7 @@
const int coeff_ctx = coeff_contexts[pos];
const int sign = AOMSIGN(v);
const int level = (v ^ sign) - sign;
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = pos >> bwl;
const int col = pos - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -1919,7 +1919,7 @@
}
#else
cost += base_cost[coeff_ctx][AOMMIN(level, 3)];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
if (v) {
// sign bit cost
@@ -1935,7 +1935,7 @@
#else
cost += coeff_costs->dc_sign_cost[dc_sign_ctx][sign01];
#endif // CONFIG_CONTEXT_DERIVATION
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
if (limits) {
if (level > LF_NUM_BASE_LEVELS) {
const int ctx = get_br_lf_ctx(levels, pos, bwl, tx_class);
@@ -1952,7 +1952,7 @@
const int ctx = get_br_ctx(levels, pos, bwl, tx_class);
cost += get_br_cost(level, lps_cost[ctx]);
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
}
return cost;
@@ -2242,16 +2242,16 @@
}
static AOM_FORCE_INLINE int get_two_coeff_cost_simple(
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
int plane,
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
int ci, tran_low_t abs_qc, int coeff_ctx,
const LV_MAP_COEFF_COST *txb_costs, int bwl, TX_CLASS tx_class,
const uint8_t *levels, int *cost_low) {
// this simple version assumes the coeff's scan_idx is not DC (scan_idx != 0)
// and not the last (scan_idx != eob - 1)
assert(ci > 0);
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = ci >> bwl;
const int col = ci - (row << bwl);
int cost = 0;
@@ -2264,9 +2264,9 @@
}
#else
int cost = txb_costs->base_cost[coeff_ctx][AOMMIN(abs_qc, 3)];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
int diff = 0;
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
if (limits) {
if (abs_qc <= (LF_BASE_SYMBOLS - 1)) {
if (abs_qc == 0) {
@@ -2306,10 +2306,10 @@
}
#else
if (abs_qc <= 3) diff = txb_costs->base_cost[coeff_ctx][abs_qc + 4];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
if (abs_qc) {
cost += av1_cost_literal(1);
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
if (limits) {
if (abs_qc > LF_NUM_BASE_LEVELS) {
const int br_ctx = get_br_lf_ctx(levels, ci, bwl, tx_class);
@@ -2335,7 +2335,7 @@
&brcost_diff);
diff += brcost_diff;
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
*cost_low = cost - diff;
@@ -2350,13 +2350,13 @@
,
int32_t *tmp_sign
#endif // CONFIG_CONTEXT_DERIVATION
-#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
,
int plane
-#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
) {
int cost = 0;
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = ci >> bwl;
const int col = ci - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -2369,7 +2369,7 @@
}
#else
cost += txb_costs->base_eob_cost[coeff_ctx][AOMMIN(abs_qc, 3) - 1];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
if (abs_qc != 0) {
if (ci == 0) {
#if CONFIG_CONTEXT_DERIVATION
@@ -2390,7 +2390,7 @@
cost += av1_cost_literal(1);
#endif // CONFIG_CONTEXT_DERIVATION
}
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
if (limits) {
if (abs_qc > LF_NUM_BASE_LEVELS) {
int br_ctx;
@@ -2409,7 +2409,7 @@
br_ctx = get_br_ctx_eob(ci, bwl, tx_class);
cost += get_br_cost(abs_qc, txb_costs->lps_cost[br_ctx]);
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
return cost;
}
@@ -2424,14 +2424,14 @@
,
int32_t *tmp_sign
#endif // CONFIG_CONTEXT_DERIVATION
-#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
,
int plane
-#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
) {
int cost = 0;
if (is_last) {
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = ci >> bwl;
const int col = ci - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -2444,9 +2444,9 @@
}
#else
cost += txb_costs->base_eob_cost[coeff_ctx][AOMMIN(abs_qc, 3) - 1];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
} else {
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = ci >> bwl;
const int col = ci - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -2459,7 +2459,7 @@
}
#else
cost += txb_costs->base_cost[coeff_ctx][AOMMIN(abs_qc, 3)];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
if (abs_qc != 0) {
if (ci == 0) {
@@ -2481,7 +2481,7 @@
cost += av1_cost_literal(1);
#endif // CONFIG_CONTEXT_DERIVATION
}
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = ci >> bwl;
const int col = ci - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -2513,7 +2513,7 @@
br_ctx = get_br_ctx(levels, ci, bwl, tx_class);
cost += get_br_cost(abs_qc, txb_costs->lps_cost[br_ctx]);
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
return cost;
}
@@ -2536,9 +2536,9 @@
static INLINE void update_coeff_general(
int *accu_rate, int64_t *accu_dist, int si, int eob,
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
TX_SIZE tx_size,
-#endif // !CONFIG_ATC_COEFCODING
+#endif // !CONFIG_ATC
TX_CLASS tx_class, int bwl, int height, int64_t rdmult, int shift,
int dc_sign_ctx, const int32_t *dequant, const int16_t *scan,
const LV_MAP_COEFF_COST *txb_costs, const tran_low_t *tcoeff,
@@ -2548,10 +2548,10 @@
,
int32_t *tmp_sign
#endif // CONFIG_CONTEXT_DERIVATION
-#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
,
int plane
-#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
#if CONFIG_PAR_HIDING
,
coeff_info *coef_info, bool enable_parity_hiding
@@ -2563,17 +2563,17 @@
const int is_last = si == (eob - 1);
const int coeff_ctx =
get_lower_levels_ctx_general(is_last, si, bwl, height, levels, ci,
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
tx_size,
-#endif // !CONFIG_ATC_COEFCODING
+#endif // !CONFIG_ATC
tx_class
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
,
plane
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
);
if (qc == 0) {
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = ci >> bwl;
const int col = ci - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -2584,7 +2584,7 @@
}
#else
*accu_rate += txb_costs->base_cost[coeff_ctx][0];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
} else {
const int sign = (qc < 0) ? 1 : 0;
const tran_low_t abs_qc = abs(qc);
@@ -2599,10 +2599,10 @@
,
tmp_sign
#endif // CONFIG_CONTEXT_DERIVATION
-#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
,
plane
-#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
);
const int64_t rd = RDCOST(rdmult, rate, dist);
@@ -2613,7 +2613,7 @@
if (abs_qc == 1) {
abs_qc_low = qc_low = dqc_low = 0;
dist_low = dist0;
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = ci >> bwl;
const int col = ci - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -2624,7 +2624,7 @@
}
#else
rate_low = txb_costs->base_cost[coeff_ctx][0];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
} else {
get_qc_dqc_low(abs_qc, sign, dqv, shift, &qc_low, &dqc_low);
abs_qc_low = abs_qc - 1;
@@ -2636,10 +2636,10 @@
,
tmp_sign
#endif // CONFIG_CONTEXT_DERIVATION
-#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
,
plane
-#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
);
}
@@ -2669,9 +2669,9 @@
static AOM_FORCE_INLINE void update_coeff_simple(
int *accu_rate, int si, int eob,
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
TX_SIZE tx_size,
-#endif // !CONFIG_ATC_COEFCODING
+#endif // !CONFIG_ATC
TX_CLASS tx_class, int bwl, int64_t rdmult, int shift,
const int32_t *dequant, const int16_t *scan,
const LV_MAP_COEFF_COST *txb_costs, const tran_low_t *tcoeff,
@@ -2681,12 +2681,12 @@
,
coeff_info *coef_info, bool enable_parity_hiding
#endif // CONFIG_PAR_HIDING
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
,
int plane) {
#else
) {
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
const int dqv = get_dqv(dequant, scan[si], iqmatrix);
(void)eob;
// this simple version assumes the coeff's scan_idx is not DC (scan_idx != 0)
@@ -2695,7 +2695,7 @@
assert(si > 0);
const int ci = scan[si];
const tran_low_t qc = qcoeff[ci];
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = ci >> bwl;
const int col = ci - (row << bwl);
@@ -2709,9 +2709,9 @@
#else
const int coeff_ctx =
get_lower_levels_ctx(levels, ci, bwl, tx_size, tx_class);
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
if (qc == 0) {
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
if (limits) {
*accu_rate += txb_costs->base_lf_cost[coeff_ctx][0];
} else {
@@ -2719,16 +2719,16 @@
}
#else
*accu_rate += txb_costs->base_cost[coeff_ctx][0];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
} else {
const tran_low_t abs_qc = abs(qc);
const tran_low_t abs_tqc = abs(tcoeff[ci]);
const tran_low_t abs_dqc = abs(dqcoeff[ci]);
int rate_low = 0;
const int rate = get_two_coeff_cost_simple(
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
plane,
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
ci, abs_qc, coeff_ctx, txb_costs, bwl, tx_class, levels, &rate_low);
if (abs_dqc < abs_tqc) {
*accu_rate += rate;
@@ -2778,9 +2778,9 @@
static AOM_FORCE_INLINE void update_coeff_eob(
int *accu_rate, int64_t *accu_dist, int *eob, int *nz_num, int *nz_ci,
int si,
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
TX_SIZE tx_size,
-#endif // !CONFIG_ATC_COEFCODING
+#endif // !CONFIG_ATC
TX_CLASS tx_class, int bwl, int height, int dc_sign_ctx, int64_t rdmult,
int shift, const int32_t *dequant, const int16_t *scan,
const LV_MAP_EOB_COST *txb_eob_costs, const LV_MAP_COEFF_COST *txb_costs,
@@ -2790,10 +2790,10 @@
,
int32_t *tmp_sign
#endif // CONFIG_CONTEXT_DERIVATION
-#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
,
int plane
-#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
#if CONFIG_PAR_HIDING
,
coeff_info *coef_info, bool enable_parity_hiding
@@ -2803,7 +2803,7 @@
assert(si != *eob - 1);
const int ci = scan[si];
const tran_low_t qc = qcoeff[ci];
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = ci >> bwl;
const int col = ci - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -2816,9 +2816,9 @@
#else
const int coeff_ctx =
get_lower_levels_ctx(levels, ci, bwl, tx_size, tx_class);
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
if (qc == 0) {
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
if (limits) {
*accu_rate += txb_costs->base_lf_cost[coeff_ctx][0];
} else {
@@ -2826,7 +2826,7 @@
}
#else
*accu_rate += txb_costs->base_cost[coeff_ctx][0];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
} else {
#if CONFIG_PAR_HIDING
int64_t rd_eob_low = INT64_MAX >> 1;
@@ -2846,10 +2846,10 @@
,
tmp_sign
#endif // CONFIG_CONTEXT_DERIVATION
-#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
,
plane
-#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
);
int64_t rd = RDCOST(rdmult, *accu_rate + rate, *accu_dist + dist);
@@ -2861,7 +2861,7 @@
abs_qc_low = 0;
dqc_low = qc_low = 0;
dist_low = 0;
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
if (limits) {
rate_low = txb_costs->base_lf_cost[coeff_ctx][0];
} else {
@@ -2869,7 +2869,7 @@
}
#else
rate_low = txb_costs->base_cost[coeff_ctx][0];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
rd_low = RDCOST(rdmult, *accu_rate + rate_low, *accu_dist);
} else {
get_qc_dqc_low(abs_qc, sign, dqv, shift, &qc_low, &dqc_low);
@@ -2882,10 +2882,10 @@
,
tmp_sign
#endif // CONFIG_CONTEXT_DERIVATION
-#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
,
plane
-#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
);
rd_low = RDCOST(rdmult, *accu_rate + rate_low, *accu_dist + dist_low);
}
@@ -2909,10 +2909,10 @@
,
tmp_sign
#endif // CONFIG_CONTEXT_DERIVATION
-#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
,
plane
-#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
);
int64_t dist_new_eob = dist;
int64_t rd_new_eob = RDCOST(rdmult, rate_coeff_eob, dist_new_eob);
@@ -2929,10 +2929,10 @@
,
tmp_sign
#endif // CONFIG_CONTEXT_DERIVATION
-#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
,
plane
-#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
);
const int64_t dist_new_eob_low = dist_low;
const int64_t rd_new_eob_low =
@@ -3024,14 +3024,14 @@
tran_low_t level, int bwl, int pos,
uint8_t *levels, int dc_sign_ctx,
TX_CLASS tx_class, int *rate
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
,
TX_SIZE tx_size
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
) {
tran_low_t abslevel = abs(level), q_index = abslevel >> 1;
int sign = level < 0;
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = pos >> bwl;
const int col = pos - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, 0);
@@ -3044,17 +3044,17 @@
#else
const int coeff_ctx =
get_lower_levels_ctx(levels, pos, bwl, tx_size, tx_class);
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
*rate = get_coeff_cost_general(0, pos, abslevel, level < 0, coeff_ctx,
dc_sign_ctx, txb_costs, bwl, tx_class, levels
#if CONFIG_CONTEXT_DERIVATION
,
0
#endif // CONFIG_CONTEXT_DERIVATION
-#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
,
0
-#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
);
const int base_ctx_ph = get_base_ctx_ph(levels, pos, bwl, tx_class);
@@ -3240,10 +3240,10 @@
const qm_val_t *iqmatrix, int dc_sign_ctx, const TX_CLASS tx_class,
tran_low_t *qcoeff, tran_low_t *dqcoeff, const tran_low_t *tcoeff,
coeff_info *coef_info, int *accu_rate
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
,
TX_SIZE tx_size
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
) {
int nzsbb = 0, sum_abs1 = 0;
for (int scan_idx = eob - 1; scan_idx > 0; --scan_idx) {
@@ -3264,10 +3264,10 @@
const int ratesaving =
rate_save(txb_costs, txb_costs_ph, qcoeff[hidepos], bwl, hidepos, levels,
dc_sign_ctx, tx_class, &rate_cur
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
,
tx_size
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
);
if (!needtune && nzsbb >= PHTHRESH) {
@@ -3433,9 +3433,9 @@
int nz_ci[3] = { ci, 0, 0 };
if (abs_qc >= 2) {
update_coeff_general(&accu_rate, &accu_dist, si, eob,
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
tx_size,
-#endif // !CONFIG_ATC_COEFCODING
+#endif // !CONFIG_ATC
tx_class, bwl, height, rdmult, shift,
txb_ctx->dc_sign_ctx, dequant, scan, txb_costs, tcoeff,
qcoeff, dqcoeff, levels, iqmatrix
@@ -3443,10 +3443,10 @@
,
xd->tmp_sign
#endif // CONFIG_CONTEXT_DERIVATION
-#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
,
plane
-#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
#if CONFIG_PAR_HIDING
,
coef_info, enable_parity_hiding
@@ -3463,10 +3463,10 @@
,
xd->tmp_sign
#endif // CONFIG_CONTEXT_DERIVATION
-#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
,
plane
-#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
);
const tran_low_t tqc = tcoeff[ci];
const tran_low_t dqc = dqcoeff[ci];
@@ -3478,9 +3478,9 @@
#if CONFIG_PAR_HIDING
for (; si >= 0 && nz_num <= max_nz_num; --si) {
update_coeff_eob(&accu_rate, &accu_dist, &eob, &nz_num, nz_ci, si,
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
tx_size,
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
tx_class, bwl, height, txb_ctx->dc_sign_ctx, rdmult, shift,
dequant, scan, txb_eob_costs, txb_costs, tcoeff, qcoeff,
dqcoeff, levels, sharpness, iqmatrix
@@ -3488,16 +3488,16 @@
,
xd->tmp_sign
#endif
-#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
,
plane
-#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
,
coef_info, enable_parity_hiding);
}
#else
#if CONFIG_CONTEXT_DERIVATION
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
#define UPDATE_COEFF_EOB_CASE(tx_class_literal) \
case tx_class_literal: \
for (; si >= 0 && nz_num <= max_nz_num; --si) { \
@@ -3519,7 +3519,7 @@
levels, sharpness, iqmatrix, xd->tmp_sign, plane); \
} \
break;
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
#else
#define UPDATE_COEFF_EOB_CASE(tx_class_literal) \
case tx_class_literal: \
@@ -3549,20 +3549,20 @@
#if CONFIG_PAR_HIDING
for (; si >= 1; --si) {
update_coeff_simple(&accu_rate, si, eob,
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
tx_size,
-#endif // !CONFIG_ATC_COEFCODING
+#endif // !CONFIG_ATC
tx_class, bwl, rdmult, shift, dequant, scan, txb_costs,
tcoeff, qcoeff, dqcoeff, levels, iqmatrix, coef_info,
enable_parity_hiding
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
,
plane
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
);
}
#else
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
#define UPDATE_COEFF_SIMPLE_CASE(tx_class_literal) \
case tx_class_literal: \
for (; si >= 1; --si) { \
@@ -3594,7 +3594,7 @@
#undef UPDATE_COEFF_SIMPLE_CASE
default: assert(false);
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
#endif // CONFIG_PAR_HIDING
// DC position
@@ -3602,9 +3602,9 @@
// no need to update accu_dist because it's not used after this point
int64_t dummy_dist = 0;
update_coeff_general(&accu_rate, &dummy_dist, si, eob,
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
tx_size,
-#endif // !CONFIG_ATC_COEFCODING
+#endif // !CONFIG_ATC
tx_class, bwl, height, rdmult, shift,
txb_ctx->dc_sign_ctx, dequant, scan, txb_costs, tcoeff,
qcoeff, dqcoeff, levels, iqmatrix
@@ -3612,10 +3612,10 @@
,
xd->tmp_sign
#endif // CONFIG_CONTEXT_DERIVATION
-#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#if CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
,
plane
-#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC_COEFCODING
+#endif // CONFIG_CONTEXT_DERIVATION || CONFIG_ATC
#if CONFIG_PAR_HIDING
,
coef_info, enable_parity_hiding
@@ -3628,10 +3628,10 @@
parity_hide_tb(eob, scan, levels, bwl, rdmult, shift, txb_costs,
txb_costs_ph, dequant, iqmatrix, txb_ctx->dc_sign_ctx,
tx_class, qcoeff, dqcoeff, tcoeff, coef_info, &accu_rate
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
,
tx_size
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
);
}
@@ -3810,7 +3810,7 @@
intra_dir = mbmi->mode;
#if CONFIG_ENTROPY_STATS
const TX_TYPE primary_tx_type = get_primary_tx_type(tx_type);
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
++counts->intra_ext_tx[eset][txsize_sqr_map[tx_size]][intra_dir]
[av1_tx_type_to_idx(primary_tx_type, tx_set_type,
intra_dir,
@@ -3819,7 +3819,7 @@
++counts->intra_ext_tx[eset][txsize_sqr_map[tx_size]][intra_dir]
[av1_ext_tx_ind_intra[tx_set_type]
[primary_tx_type]];
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
#endif // CONFIG_ENTROPY_STATS
if (allow_update_cdf) {
update_cdf(
@@ -3829,12 +3829,12 @@
#else
fc->intra_ext_tx_cdf[eset][txsize_sqr_map[tx_size]][intra_dir],
#endif // CONFIG_ATC_REDUCED_TXSET
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
av1_tx_type_to_idx(get_primary_tx_type(tx_type), tx_set_type,
intra_dir, av1_size_class[tx_size]),
#else
av1_ext_tx_ind_intra[tx_set_type][get_primary_tx_type(tx_type)],
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
#if CONFIG_ATC_REDUCED_TXSET
cm->features.reduced_tx_set_used
? av1_num_reduced_tx_set
@@ -4258,10 +4258,10 @@
DECLARE_ALIGNED(16, int8_t, coeff_contexts[MAX_TX_SQUARE]);
av1_get_nz_map_contexts(levels, scan, eob, tx_size, tx_class, coeff_contexts
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
,
plane
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
);
#if CONFIG_PAR_HIDING
bool enable_parity_hiding = cm->features.allow_parity_hiding &&
@@ -4280,7 +4280,7 @@
if (allow_update_cdf) {
if (c == eob - 1) {
assert(coeff_ctx < 4);
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = pos >> bwl;
const int col = pos - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -4299,9 +4299,9 @@
update_cdf(
ec_ctx->coeff_base_eob_cdf[txsize_ctx][plane_type][coeff_ctx],
AOMMIN(level, 3) - 1, 3);
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
} else {
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = pos >> bwl;
const int col = pos - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -4317,14 +4317,14 @@
#else
update_cdf(ec_ctx->coeff_base_cdf[txsize_ctx][plane_type][coeff_ctx],
AOMMIN(level, 3), 4);
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
}
if (c == eob - 1) {
assert(coeff_ctx < 4);
assert(level > 0);
#if CONFIG_ENTROPY_STATS
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = pos >> bwl;
const int col = pos - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -4339,9 +4339,9 @@
#else
++td->counts->coeff_base_eob_multi[cdf_idx][txsize_ctx][plane_type]
[coeff_ctx][AOMMIN(level, 3) - 1];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
} else {
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = pos >> bwl;
const int col = pos - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -4356,10 +4356,10 @@
#else
++td->counts->coeff_base_multi[cdf_idx][txsize_ctx][plane_type]
[coeff_ctx][AOMMIN(level, 3)];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
#endif
}
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = pos >> bwl;
const int col = pos - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -4434,7 +4434,7 @@
if (k < BR_CDF_SIZE - 1) break;
}
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
#if CONFIG_PAR_HIDING
@@ -4467,7 +4467,7 @@
if (allow_update_cdf) {
if (c == eob - 1) {
assert(coeff_ctx < 4);
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = pos >> bwl;
const int col = pos - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -4485,9 +4485,9 @@
update_cdf(
ec_ctx->coeff_base_eob_cdf[txsize_ctx][plane_type][coeff_ctx],
AOMMIN(level, 3) - 1, 3);
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
} else {
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = pos >> bwl;
const int col = pos - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -4503,13 +4503,13 @@
#else
update_cdf(ec_ctx->coeff_base_cdf[txsize_ctx][plane_type][coeff_ctx],
AOMMIN(level, 3), 4);
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
}
if (c == eob - 1) {
assert(coeff_ctx < 4);
#if CONFIG_ENTROPY_STATS
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = pos >> bwl;
const int col = pos - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -4524,9 +4524,9 @@
#else
++td->counts->coeff_base_eob_multi[cdf_idx][txsize_ctx][plane_type]
[coeff_ctx][AOMMIN(level, 3) - 1];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
} else {
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = pos >> bwl;
const int col = pos - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -4541,10 +4541,10 @@
#else
++td->counts->coeff_base_multi[cdf_idx][txsize_ctx][plane_type]
[coeff_ctx][AOMMIN(level, 3)];
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
#endif
}
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
const int row = pos >> bwl;
const int col = pos - (row << bwl);
int limits = get_lf_limits(row, col, tx_class, plane);
@@ -4619,7 +4619,7 @@
if (k < BR_CDF_SIZE - 1) break;
}
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
}
#endif // CONFIG_PAR_HIDING
diff --git a/av1/encoder/rd.c b/av1/encoder/rd.c
index b960606..a35933c 100644
--- a/av1/encoder/rd.c
+++ b/av1/encoder/rd.c
@@ -61,12 +61,12 @@
static const int use_intra_ext_tx_for_txsize[EXT_TX_SETS_INTRA]
[EXT_TX_SIZES] = {
{ 1, 1, 1, 1 }, // unused
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
{ 1, 1, 1, 0 },
#else
{ 1, 1, 0, 0 },
{ 0, 0, 1, 0 },
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
};
static const int use_inter_ext_tx_for_txsize[EXT_TX_SETS_INTER]
@@ -82,12 +82,12 @@
{
// Intra
EXT_TX_SET_DCTONLY,
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
EXT_NEW_TX_SET,
#else
EXT_TX_SET_DTT4_IDTX_1DDCT,
EXT_TX_SET_DTT4_IDTX,
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
},
{
// Inter
@@ -396,16 +396,16 @@
}
#endif // CONFIG_ATC_DCTX_ALIGNED
for (s = 1; s < EXT_TX_SETS_INTRA; ++s) {
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
int tx_set_type = av1_ext_tx_set_idx_to_type[0][s];
#if CONFIG_ATC_REDUCED_TXSET
const int cdf_offset = cm->features.reduced_tx_set_used ? 1 : 0;
#endif // CONFIG_ATC_REDUCED_TXSET
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
if (use_intra_ext_tx_for_txsize[s][i]) {
for (j = 0; j < INTRA_MODES; ++j) {
av1_cost_tokens_from_cdf(
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
mode_costs->intra_tx_type_costs[s][i][j],
#if CONFIG_ATC_REDUCED_TXSET
fc->intra_ext_tx_cdf[s + cdf_offset][i][j],
@@ -419,7 +419,7 @@
mode_costs->intra_tx_type_costs[s][i][j],
fc->intra_ext_tx_cdf[s][i][j],
av1_ext_tx_inv_intra[av1_ext_tx_set_idx_to_type[0][s]]);
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
}
}
}
@@ -976,7 +976,7 @@
av1_cost_tokens_from_cdf(pcost->base_eob_cost[ctx],
fc->coeff_base_eob_cdf[tx_size][plane][ctx],
NULL);
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
for (int ctx = 0; ctx < SIG_COEF_CONTEXTS_EOB; ++ctx)
av1_cost_tokens_from_cdf(pcost->base_lf_eob_cost[ctx],
fc->coeff_base_lf_eob_cdf[tx_size][plane][ctx],
@@ -1005,7 +1005,7 @@
pcost->base_cost[ctx][7] =
pcost->base_cost[ctx][3] - pcost->base_cost[ctx][2];
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
#if CONFIG_ATC_DCTX_ALIGNED
for (int ctx = 0; ctx < SIG_COEF_CONTEXTS_BOB; ++ctx)
av1_cost_tokens_from_cdf(pcost->base_bob_cost[ctx],
@@ -1030,7 +1030,7 @@
}
#endif // CONFIG_CONTEXT_DERIVATION
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
for (int ctx = 0; ctx < LF_LEVEL_CONTEXTS; ++ctx) {
int br_lf_rate[BR_CDF_SIZE];
int prev_cost_lf = 0;
@@ -1053,17 +1053,17 @@
pcost->lps_lf_cost[ctx][i] - pcost->lps_lf_cost[ctx][i - 1];
}
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
for (int ctx = 0; ctx < LEVEL_CONTEXTS; ++ctx) {
int br_rate[BR_CDF_SIZE];
int prev_cost = 0;
int i, j;
av1_cost_tokens_from_cdf(
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
br_rate, fc->coeff_br_cdf[plane][ctx],
#else
br_rate, fc->coeff_br_cdf[AOMMIN(tx_size, TX_32X32)][plane][ctx],
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
NULL);
// printf("br_rate: ");
// for(j = 0; j < BR_CDF_SIZE; j++)
diff --git a/av1/encoder/tx_search.c b/av1/encoder/tx_search.c
index c71c89d..9bfa060 100644
--- a/av1/encoder/tx_search.c
+++ b/av1/encoder/tx_search.c
@@ -1357,10 +1357,10 @@
static uint32_t get_intra_txb_hash(MACROBLOCK *x, int plane, int blk_row,
int blk_col, BLOCK_SIZE plane_bsize,
TX_SIZE tx_size
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
,
PREDICTION_MODE intra_dir
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
) {
int16_t tmp_data[64 * 64];
const int diff_stride = block_size_wide[plane_bsize];
@@ -1380,11 +1380,11 @@
}
CRC32C *crc = &x->txfm_search_info.mb_rd_record.crc_calculator;
const uint32_t hash = av1_get_crc32c_value(crc, hash_data, 2 * txb_w * txb_h);
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
return (hash << 9) + (tx_size << 4) + (intra_dir);
#else
return (hash << 5) + tx_size;
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
}
// pruning thresholds for prune_txk_type and prune_txk_type_separ
@@ -1404,7 +1404,7 @@
frame_is_intra_only(&cpi->common) &&
!is_inter_block(xd->mi[0], xd->tree_type) && plane == 0 &&
tx_size_wide[tx_size] == tx_size_high[tx_size]);
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
MB_MODE_INFO *mbmi = xd->mi[0];
PREDICTION_MODE intra_dir;
if (mbmi->filter_intra_mode_info.use_filter_intra)
@@ -1417,7 +1417,7 @@
#else
const uint32_t intra_hash =
get_intra_txb_hash(x, plane, blk_row, blk_col, plane_bsize, tx_size);
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
const int intra_hash_idx =
find_tx_size_rd_info(&txfm_info->txb_rd_record_intra, intra_hash);
*intra_txb_rd_info =
@@ -2087,14 +2087,14 @@
const AV1_COMMON *cm = &cpi->common;
MACROBLOCKD *xd = &x->e_mbd;
MB_MODE_INFO *mbmi = xd->mi[0];
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
PREDICTION_MODE intra_dir;
if (mbmi->filter_intra_mode_info.use_filter_intra)
intra_dir =
fimode_to_intradir[mbmi->filter_intra_mode_info.filter_intra_mode];
else
intra_dir = mbmi->mode;
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
const TxfmSearchParams *txfm_params = &x->txfm_search_params;
const int is_inter = is_inter_block(mbmi, xd->tree_type);
const int fast_tx_search = ftxs_mode & FTXS_DCT_AND_1D_DCT_ONLY;
@@ -2120,12 +2120,12 @@
av1_get_tx_type(xd, get_plane_type(plane), blk_row, blk_col, tx_size,
cm->features.reduced_tx_set_used);
}
-#if !CONFIG_ATC_NEWTXSETS
+#if !CONFIG_ATC
PREDICTION_MODE intra_dir =
mbmi->filter_intra_mode_info.use_filter_intra
? fimode_to_intradir[mbmi->filter_intra_mode_info.filter_intra_mode]
: mbmi->mode;
-#endif // !CONFIG_ATC_NEWTXSETS
+#endif // !CONFIG_ATC
uint16_t ext_tx_used_flag =
cpi->sf.tx_sf.tx_type_search.use_reduced_intra_txset &&
tx_set_type == EXT_TX_SET_DTT4_IDTX_1DDCT
@@ -2138,7 +2138,7 @@
txk_allowed = DCT_DCT;
}
-#if CONFIG_ATC_NEWTXSETS
+#if CONFIG_ATC
if (!is_inter) {
uint16_t mdtx_mask =
av1_md_trfm_used_flag[av1_size_class[tx_size]]
@@ -2161,7 +2161,7 @@
}
}
#endif // CONFIG_ATC_REDUCED_TXSET
-#endif // CONFIG_ATC_NEWTXSETS
+#endif // CONFIG_ATC
if (cpi->oxcf.txfm_cfg.enable_flip_idtx == 0)
ext_tx_used_flag &= DCT_ADST_TX_MASK;
diff --git a/build/cmake/aom_config_defaults.cmake b/build/cmake/aom_config_defaults.cmake
index 4d73cf2..529ba9f 100644
--- a/build/cmake/aom_config_defaults.cmake
+++ b/build/cmake/aom_config_defaults.cmake
@@ -137,11 +137,7 @@
"Use zero offset for non-normative bit upshift")
# AV2 experiment flags.
-set_aom_config_var(
- CONFIG_ATC_COEFCODING 1
- "AV2 enable adaptive transform coefficient coding improvement.")
-set_aom_config_var(CONFIG_ATC_NEWTXSETS 1
- "AV2 enable adaptive transform coding and new TX sets.")
+set_aom_config_var(CONFIG_ATC 1 "AV2 enable adaptive transform coding.")
set_aom_config_var(CONFIG_ATC_REDUCED_TXSET 1
"AV2 enable reduced transform set.")
set_aom_config_var(
diff --git a/build/cmake/aom_experiment_deps.cmake b/build/cmake/aom_experiment_deps.cmake
index 62017f2..e9460f2 100644
--- a/build/cmake/aom_experiment_deps.cmake
+++ b/build/cmake/aom_experiment_deps.cmake
@@ -37,11 +37,10 @@
change_config_and_warn(CONFIG_CCSO_EXT 0 !CONFIG_CCSO)
endif()
- # CONFIG_ATC_REDUCED_TXSET depends on CONFIG_ATC_NEWTXSETS. If
- # CONFIG_ATC_NEWTXSETS is off, then CONFIG_ATC_REDUCED_TXSET needs to be
- # disabled.
- if(NOT CONFIG_ATC_NEWTXSETS AND CONFIG_ATC_REDUCED_TXSET)
- change_config_and_warn(CONFIG_ATC_REDUCED_TXSET 0 !CONFIG_ATC_NEWTXSETS)
+ # CONFIG_ATC_REDUCED_TXSET depends on CONFIG_ATC. If CONFIG_ATC is off, then
+ # CONFIG_ATC_REDUCED_TXSET needs to be disabled.
+ if(NOT CONFIG_ATC AND CONFIG_ATC_REDUCED_TXSET)
+ change_config_and_warn(CONFIG_ATC_REDUCED_TXSET 0 !CONFIG_ATC)
endif()
# CONFIG_OPTFLOW_ON_TIP is dependent on CONFIG_OPTFLOW_REFINEMENT and
diff --git a/test/encodetxb_test.cc b/test/encodetxb_test.cc
index 58f1711..84ebbad 100644
--- a/test/encodetxb_test.cc
+++ b/test/encodetxb_test.cc
@@ -61,7 +61,7 @@
libaom_test::ClearSystemState();
}
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
void GetNzMapContextsRun() {
const int kNumTests = 10;
int result = 0;
@@ -149,7 +149,7 @@
(elapsed_time_ref * 1.0) / (elapsed_time * 1.0));
}
}
-#endif // !CONFIG_ATC_COEFCODING
+#endif // !CONFIG_ATC
private:
void InitDataWithEob(const int16_t *const scan, const int bwl,
@@ -193,7 +193,7 @@
};
GTEST_ALLOW_UNINSTANTIATED_PARAMETERIZED_TEST(EncodeTxbTest);
-#if !CONFIG_ATC_COEFCODING
+#if !CONFIG_ATC
TEST_P(EncodeTxbTest, GetNzMapContexts) { GetNzMapContextsRun(); }
TEST_P(EncodeTxbTest, DISABLED_SpeedTestGetNzMapContexts) {
@@ -209,7 +209,7 @@
INSTANTIATE_TEST_SUITE_P(NEON, EncodeTxbTest,
::testing::Values(av1_get_nz_map_contexts_neon));
#endif
-#endif // !CONFIG_ATC_COEFCODING
+#endif // !CONFIG_ATC
typedef void (*av1_txb_init_levels_func)(const tran_low_t *const coeff,
const int width, const int height,
diff --git a/test/scan_test.cc b/test/scan_test.cc
index cf3c317..e356c50 100644
--- a/test/scan_test.cc
+++ b/test/scan_test.cc
@@ -110,7 +110,7 @@
SCAN_MODE scan_mode;
TX_CLASS tx_class = tx_type_to_class[(TX_TYPE)tx_type];
if (tx_class == TX_CLASS_2D) {
-#if CONFIG_ATC_COEFCODING
+#if CONFIG_ATC
scan_mode = SCAN_MODE_COL_DIAG;
#else
if (rows == cols) {
@@ -120,7 +120,7 @@
} else {
scan_mode = SCAN_MODE_COL_DIAG;
}
-#endif // CONFIG_ATC_COEFCODING
+#endif // CONFIG_ATC
} else if (tx_class == TX_CLASS_VERT) {
scan_mode = SCAN_MODE_ROW_1D;
} else {