[FFmpeg-soc] [soc]: r5008 - in amr: amrnbdata.h amrnbdec.c
cmcq
subversion at mplayerhq.hu
Sun Aug 9 14:54:23 CEST 2009
Author: cmcq
Date: Sun Aug 9 14:54:23 2009
New Revision: 5008
Log:
Remove #define's not directly related to the data tables
Modified:
amr/amrnbdata.h
amr/amrnbdec.c
Modified: amr/amrnbdata.h
==============================================================================
--- amr/amrnbdata.h Sun Aug 9 14:52:57 2009 (r5007)
+++ amr/amrnbdata.h Sun Aug 9 14:54:23 2009 (r5008)
@@ -1533,8 +1533,6 @@ static const float pred_fac[LP_FILTER_OR
#define PRED_FAC_MODE_122 0.65
#define LSF_R_FAC (8000.0/32768.0) ///< LSF residual tables to Hertz
-#define FREQ_LSP_FAC (2.0*M_PI/8000.0) ///< Hertz to radians
-#define FREQ_LSF (1/8000.0) ///< Scale from Hertz to lsf_avg_init values
#define MIN_LSF_SPACING 50.0488 ///< Ensures stability of LPC filter
#define PITCH_LAG_MAX 143 ///< Upper bound on decoded lag search
#define PITCH_LAG_MIN 20 ///< Lower bound on decoded lag search
Modified: amr/amrnbdec.c
==============================================================================
--- amr/amrnbdec.c Sun Aug 9 14:52:57 2009 (r5007)
+++ amr/amrnbdec.c Sun Aug 9 14:54:23 2009 (r5008)
@@ -175,7 +175,7 @@ static void lsf2lsp(float *lsf, float *l
int i;
for (i = 0; i < LP_FILTER_ORDER; i++)
- lsp[i] = cos(lsf[i] * FREQ_LSP_FAC); // FREQ_LSP_FAC = 2*M_PI / 8000.0
+ lsp[i] = cos(lsf[i] * 2.0 * M_PI / 8000.0);
}
/**
@@ -191,7 +191,7 @@ static void interpolate_lsf(float lsf_q[
for (i = 0; i < 4; i++)
ff_weighted_vector_sumf(lsf_q[i], lsf_q[3], lsf_new,
- 0.25 * (3 - i), 0.25 * (i + 1) * FREQ_LSF,
+ 0.25 * (3 - i), 0.25 * (i + 1) / 8000.0,
LP_FILTER_ORDER);
}
More information about the FFmpeg-soc
mailing list