diff --git a/libavcodec/mpegaudiodec.c b/libavcodec/mpegaudiodec.c index c18d7525f4..0d2641418d 100644 --- a/libavcodec/mpegaudiodec.c +++ b/libavcodec/mpegaudiodec.c @@ -247,14 +247,6 @@ static inline int l3_unscale(int value, int exponent) static int dev_4_3_coefs[DEV_ORDER]; -#if 0 /* unused */ -static int pow_mult3[3] = { - POW_FIX(1.0), - POW_FIX(1.25992104989487316476), - POW_FIX(1.58740105196819947474), -}; -#endif - static av_cold void int_pow_init(void) { int i, a; @@ -266,53 +258,6 @@ static av_cold void int_pow_init(void) } } -#if 0 /* unused, remove? */ -/* return the mantissa and the binary exponent */ -static int int_pow(int i, int *exp_ptr) -{ - int e, er, eq, j; - int a, a1; - - /* renormalize */ - a = i; - e = POW_FRAC_BITS; - while (a < (1 << (POW_FRAC_BITS - 1))) { - a = a << 1; - e--; - } - a -= (1 << POW_FRAC_BITS); - a1 = 0; - for(j = DEV_ORDER - 1; j >= 0; j--) - a1 = POW_MULL(a, dev_4_3_coefs[j] + a1); - a = (1 << POW_FRAC_BITS) + a1; - /* exponent compute (exact) */ - e = e * 4; - er = e % 3; - eq = e / 3; - a = POW_MULL(a, pow_mult3[er]); - while (a >= 2 * POW_FRAC_ONE) { - a = a >> 1; - eq++; - } - /* convert to float */ - while (a < POW_FRAC_ONE) { - a = a << 1; - eq--; - } - /* now POW_FRAC_ONE <= a < 2 * POW_FRAC_ONE */ -#if POW_FRAC_BITS > FRAC_BITS - a = (a + (1 << (POW_FRAC_BITS - FRAC_BITS - 1))) >> (POW_FRAC_BITS - FRAC_BITS); - /* correct overflow */ - if (a >= 2 * (1 << FRAC_BITS)) { - a = a >> 1; - eq++; - } -#endif - *exp_ptr = eq; - return a; -} -#endif - static av_cold int decode_init(AVCodecContext * avctx) { MPADecodeContext *s = avctx->priv_data;