[FFmpeg-soc] [soc]: r1228 - qcelp/qcelpdec.c

reynaldo subversion at mplayerhq.hu
Wed Aug 29 05:23:01 CEST 2007


Author: reynaldo
Date: Wed Aug 29 05:23:01 2007
New Revision: 1228

Log:
Rearrange invalid lag check - Another Michael's suggested change

Modified:
   qcelp/qcelpdec.c

Modified: qcelp/qcelpdec.c
==============================================================================
--- qcelp/qcelpdec.c	(original)
+++ qcelp/qcelpdec.c	Wed Aug 29 05:23:01 2007
@@ -395,7 +395,7 @@ static void qcelp_apply_gain_ctrl(int do
 /**
  * Pitch filters or pre-filters pv, returns 0 if everything goes
  * well, otherwise it returns the index of the failing-to-be-pitched
- * element or -1 if an invalid (140.5, 141.5, 142.5) lag is found.
+ * element or -1 if an invalid (140.5, 141.5, 142.5, 243.5) lag is found.
  *
  * This function implements both, the pitch filter and the pitch pre-filter
  * whose results gets stored in pv.
@@ -434,10 +434,11 @@ static int qcelp_do_pitchfilter(QCELPFra
                 lag[i]=plag[i]+16;
 
                 if(pfrac[i])
+                {
+                    if(lag[i] >= 140) return -1; // WIP: hook to IFQ decoding
                     lag[i]+=0.5;
+                }
 
-                if(lag[i] == 140.5 || lag[i] == 141.5 || lag[i] == 142.5)
-                    return -1;
             }
 
             /*



More information about the FFmpeg-soc mailing list