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

jm at svn.xiph.org jm at svn.xiph.org
Thu Dec 8 00:56:28 PST 2005


Author: jm
Date: 2005-12-08 00:56:25 -0800 (Thu, 08 Dec 2005)
New Revision: 10565

Modified:
   trunk/speex/libspeex/mdf.c
Log:
fixed the float version, lowered the upper bound on adaptation


Modified: trunk/speex/libspeex/mdf.c
===================================================================
--- trunk/speex/libspeex/mdf.c	2005-12-07 20:00:11 UTC (rev 10564)
+++ trunk/speex/libspeex/mdf.c	2005-12-08 08:56:25 UTC (rev 10565)
@@ -169,6 +169,8 @@
          acc[i+1] += (X[i+1]*Y[i] + X[i]*Y[i+1]);
       }
       acc[i] += X[i]*Y[i];
+      X += N;
+      Y += N;
    }
 }
 #endif
@@ -413,8 +415,8 @@
          float r;
          /* Compute frequency-domain adaptation mask */
          r = leak_estimate*st->Yf[i] / (1.f+st->Rf[i]);
-         if (r>1)
-            r = 1;
+         if (r>.5)
+            r = .5;
          st->power_1[i] = WEIGHT_SCALING*adapt_rate*r/(1.f+st->power[i]);
          /*printf ("%f ", st->power_1[i]);*/
       }



More information about the commits mailing list