From 228ca70d485e2660c2e381d7112cbcca65c156a0 Mon Sep 17 00:00:00 2001 From: diego Date: Wed, 2 Jun 2004 22:59:04 +0000 Subject: update to the 2.0 release of faad, patch by adland git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@12528 b3059339-0415-0410-9bf9-f77b7e298cf2 --- libfaad2/pns.c | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) (limited to 'libfaad2/pns.c') diff --git a/libfaad2/pns.c b/libfaad2/pns.c index 86f2262d80..bc4e08af70 100644 --- a/libfaad2/pns.c +++ b/libfaad2/pns.c @@ -1,6 +1,6 @@ /* ** FAAD2 - Freeware Advanced Audio (AAC) Decoder including SBR decoding -** Copyright (C) 2003 M. Bakker, Ahead Software AG, http://www.nero.com +** Copyright (C) 2003-2004 M. Bakker, Ahead Software AG, http://www.nero.com ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by @@ -22,7 +22,7 @@ ** Commercial non-GPL licensing of this software is possible. ** For more info contact Ahead Software through Mpeg4AAClicense@nero.com. ** -** $Id: pns.c,v 1.22 2003/09/09 18:09:52 menno Exp $ +** $Id: pns.c,v 1.2 2003/10/03 22:22:27 alex Exp $ **/ #include "common.h" @@ -31,6 +31,11 @@ #include "pns.h" +/* static function declarations */ +static void gen_rand_vector(real_t *spec, int16_t scale_factor, uint16_t size, + uint8_t sub); + + #ifdef FIXED_POINT #define DIV(A, B) (((int64_t)A << REAL_BITS)/B) @@ -116,7 +121,7 @@ static INLINE void gen_rand_vector(real_t *spec, int16_t scale_factor, uint16_t else tmp = (tmp & ((1<<(REAL_BITS-1))-1)); - energy += MUL(tmp,tmp); + energy += MUL_R(tmp,tmp); spec[i] = tmp; } @@ -138,11 +143,11 @@ static INLINE void gen_rand_vector(real_t *spec, int16_t scale_factor, uint16_t scale <<= exp; if (frac) - scale = MUL_R_C(scale, pow2_table[frac + 3]); + scale = MUL_C(scale, pow2_table[frac + 3]); for (i = 0; i < size; i++) { - spec[i] = MUL(spec[i], scale); + spec[i] = MUL_R(spec[i], scale); } } #endif -- cgit v1.2.3