Move daala_fdst4() / daala_idst4() into daala_tx.c. This commit has no impact on metrics. Change-Id: I85007ef966b9aab4545499016ed68ab5c96a417a
diff --git a/aom_dsp/inv_txfm.c b/aom_dsp/inv_txfm.c index c6c2f64..65913fb 100644 --- a/aom_dsp/inv_txfm.c +++ b/aom_dsp/inv_txfm.c
@@ -264,16 +264,6 @@ } } -#if CONFIG_DAALA_DCT4 -void aom_iadst4_c(const tran_low_t *input, tran_low_t *output) { - int i; - od_coeff x[4]; - od_coeff y[4]; - for (i = 0; i < 4; i++) y[i] = input[i]; - od_bin_idst4(x, 1, y); - for (i = 0; i < 4; i++) output[i] = (tran_low_t)x[i]; -} -#else void aom_iadst4_c(const tran_low_t *input, tran_low_t *output) { tran_high_t s0, s1, s2, s3, s4, s5, s6, s7; @@ -310,7 +300,6 @@ output[2] = WRAPLOW(dct_const_round_shift(s2)); output[3] = WRAPLOW(dct_const_round_shift(s0 + s1 - s3)); } -#endif #if CONFIG_DAALA_DCT8 void aom_iadst8_c(const tran_low_t *input, tran_low_t *output) {
diff --git a/av1/common/daala_tx.c b/av1/common/daala_tx.c index 9ad6388..8f93645 100644 --- a/av1/common/daala_tx.c +++ b/av1/common/daala_tx.c
@@ -4124,3 +4124,21 @@ od_bin_idct4(x, 1, y); for (i = 0; i < 4; i++) output[i] = (tran_low_t)x[i]; } + +void daala_fdst4(const tran_low_t *input, tran_low_t *output) { + int i; + od_coeff x[4]; + od_coeff y[4]; + for (i = 0; i < 4; i++) x[i] = (od_coeff)input[i]; + od_bin_fdst4(y, x, 1); + for (i = 0; i < 4; i++) output[i] = (tran_low_t)y[i]; +} + +void daala_idst4(const tran_low_t *input, tran_low_t *output) { + int i; + od_coeff x[4]; + od_coeff y[4]; + for (i = 0; i < 4; i++) y[i] = input[i]; + od_bin_idst4(x, 1, y); + for (i = 0; i < 4; i++) output[i] = (tran_low_t)x[i]; +}
diff --git a/av1/common/daala_tx.h b/av1/common/daala_tx.h index 061876f..59f88b2 100644 --- a/av1/common/daala_tx.h +++ b/av1/common/daala_tx.h
@@ -6,6 +6,8 @@ void daala_fdct4(const tran_low_t *input, tran_low_t *output); void daala_idct4(const tran_low_t *input, tran_low_t *output); +void daala_fdst4(const tran_low_t *input, tran_low_t *output); +void daala_idst4(const tran_low_t *input, tran_low_t *output); void od_bin_fdct4(od_coeff y[4], const od_coeff *x, int xstride); void od_bin_idct4(od_coeff *x, int xstride, const od_coeff y[4]);
diff --git a/av1/common/idct.c b/av1/common/idct.c index a9bfb9a..b4e3f04 100644 --- a/av1/common/idct.c +++ b/av1/common/idct.c
@@ -331,23 +331,23 @@ #endif static const transform_2d IHT_4[] = { #if CONFIG_DAALA_DCT4 - { daala_idct4, daala_idct4 }, // DCT_DCT = 0 - { aom_iadst4_c, daala_idct4 }, // ADST_DCT = 1 - { daala_idct4, aom_iadst4_c }, // DCT_ADST = 2 - { aom_iadst4_c, aom_iadst4_c }, // ADST_ADST = 3 + { daala_idct4, daala_idct4 }, // DCT_DCT = 0 + { daala_idst4, daala_idct4 }, // ADST_DCT = 1 + { daala_idct4, daala_idst4 }, // DCT_ADST = 2 + { daala_idst4, daala_idst4 }, // ADST_ADST = 3 #if CONFIG_EXT_TX - { aom_iadst4_c, daala_idct4 }, // FLIPADST_DCT - { daala_idct4, aom_iadst4_c }, // DCT_FLIPADST - { aom_iadst4_c, aom_iadst4_c }, // FLIPADST_FLIPADST - { aom_iadst4_c, aom_iadst4_c }, // ADST_FLIPADST - { aom_iadst4_c, aom_iadst4_c }, // FLIPADST_ADST - { iidtx4_c, iidtx4_c }, // IDTX - { daala_idct4, iidtx4_c }, // V_DCT - { iidtx4_c, daala_idct4 }, // H_DCT - { aom_iadst4_c, iidtx4_c }, // V_ADST - { iidtx4_c, aom_iadst4_c }, // H_ADST - { aom_iadst4_c, iidtx4_c }, // V_FLIPADST - { iidtx4_c, aom_iadst4_c }, // H_FLIPADST + { daala_idst4, daala_idct4 }, // FLIPADST_DCT + { daala_idct4, daala_idst4 }, // DCT_FLIPADST + { daala_idst4, daala_idst4 }, // FLIPADST_FLIPADST + { daala_idst4, daala_idst4 }, // ADST_FLIPADST + { daala_idst4, daala_idst4 }, // FLIPADST_ADST + { iidtx4_c, iidtx4_c }, // IDTX + { daala_idct4, iidtx4_c }, // V_DCT + { iidtx4_c, daala_idct4 }, // H_DCT + { daala_idst4, iidtx4_c }, // V_ADST + { iidtx4_c, daala_idst4 }, // H_ADST + { daala_idst4, iidtx4_c }, // V_FLIPADST + { iidtx4_c, daala_idst4 }, // H_FLIPADST #endif #else { aom_idct4_c, aom_idct4_c }, // DCT_DCT = 0
diff --git a/av1/encoder/dct.c b/av1/encoder/dct.c index 8027c9a..7cbe0d0 100644 --- a/av1/encoder/dct.c +++ b/av1/encoder/dct.c
@@ -780,18 +780,6 @@ } #endif -#if CONFIG_DAALA_DCT4 -static void fadst4(const tran_low_t *input, tran_low_t *output) { - int i; - od_coeff x[4]; - od_coeff y[4]; - for (i = 0; i < 4; i++) x[i] = (od_coeff)input[i]; - od_bin_fdst4(y, x, 1); - for (i = 0; i < 4; i++) output[i] = (tran_low_t)y[i]; -} - -#else - static void fadst4(const tran_low_t *input, tran_low_t *output) { tran_high_t x0, x1, x2, x3; tran_high_t s0, s1, s2, s3, s4, s5, s6, s7; @@ -831,7 +819,6 @@ output[2] = (tran_low_t)fdct_round_shift(s2); output[3] = (tran_low_t)fdct_round_shift(s3); } -#endif #if CONFIG_DAALA_DCT8 static void fadst8(const tran_low_t *input, tran_low_t *output) { @@ -1366,22 +1353,22 @@ static const transform_2d FHT[] = { #if CONFIG_DAALA_DCT4 { daala_fdct4, daala_fdct4 }, // DCT_DCT - { fadst4, daala_fdct4 }, // ADST_DCT - { daala_fdct4, fadst4 }, // DCT_ADST - { fadst4, fadst4 }, // ADST_ADST + { daala_fdst4, daala_fdct4 }, // ADST_DCT + { daala_fdct4, daala_fdst4 }, // DCT_ADST + { daala_fdst4, daala_fdst4 }, // ADST_ADST #if CONFIG_EXT_TX - { fadst4, daala_fdct4 }, // FLIPADST_DCT - { daala_fdct4, fadst4 }, // DCT_FLIPADST - { fadst4, fadst4 }, // FLIPADST_FLIPADST - { fadst4, fadst4 }, // ADST_FLIPADST - { fadst4, fadst4 }, // FLIPADST_ADST - { fidtx4, fidtx4 }, // IDTX - { daala_fdct4, fidtx4 }, // V_DCT - { fidtx4, daala_fdct4 }, // H_DCT - { fadst4, fidtx4 }, // V_ADST - { fidtx4, fadst4 }, // H_ADST - { fadst4, fidtx4 }, // V_FLIPADST - { fidtx4, fadst4 }, // H_FLIPADST + { daala_fdst4, daala_fdct4 }, // FLIPADST_DCT + { daala_fdct4, daala_fdst4 }, // DCT_FLIPADST + { daala_fdst4, daala_fdst4 }, // FLIPADST_FLIPADST + { daala_fdst4, daala_fdst4 }, // ADST_FLIPADST + { daala_fdst4, daala_fdst4 }, // FLIPADST_ADST + { fidtx4, fidtx4 }, // IDTX + { daala_fdct4, fidtx4 }, // V_DCT + { fidtx4, daala_fdct4 }, // H_DCT + { daala_fdst4, fidtx4 }, // V_ADST + { fidtx4, daala_fdst4 }, // H_ADST + { daala_fdst4, fidtx4 }, // V_FLIPADST + { fidtx4, daala_fdst4 }, // H_FLIPADST #endif #else { fdct4, fdct4 }, // DCT_DCT