[xiph-commits] r12211 - trunk/speex/libspeex

jm at svn.xiph.org jm at svn.xiph.org
Fri Dec 15 14:40:52 PST 2006


Author: jm
Date: 2006-12-15 14:40:50 -0800 (Fri, 15 Dec 2006)
New Revision: 12211

Modified:
   trunk/speex/libspeex/sb_celp.c
Log:
wideband fixed-point details


Modified: trunk/speex/libspeex/sb_celp.c
===================================================================
--- trunk/speex/libspeex/sb_celp.c	2006-12-15 13:59:28 UTC (rev 12210)
+++ trunk/speex/libspeex/sb_celp.c	2006-12-15 22:40:50 UTC (rev 12211)
@@ -569,7 +569,7 @@
       
       rl = low_pi_gain[sub];
 #ifdef FIXED_POINT
-      filter_ratio=EXTRACT16(SATURATE(PDIV32(SHL32(rl+82,2),EXTRACT16(SHR32(82+rh,5))),32767));
+      filter_ratio=EXTRACT16(SATURATE(PDIV32(SHL32(ADD32(rl,82),7),ADD32(82,rh)),32767));
 #else
       filter_ratio=(rl+.01)/(rh+.01);
 #endif
@@ -1017,7 +1017,7 @@
 
          rl = low_pi_gain[sub];
 #ifdef FIXED_POINT
-         filter_ratio=EXTRACT16(SATURATE(PDIV32(SHL32(rl+82,2),EXTRACT16(SHR32(82+rh,5))),32767));
+         filter_ratio=EXTRACT16(SATURATE(PDIV32(SHL32(ADD32(rl,82),7),ADD32(82,rh)),32767));
 #else
          filter_ratio=(rl+.01)/(rh+.01);
 #endif



More information about the commits mailing list