]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
bring this in sync with latest voipcodec release... need to update mod_voipcodecs...
authorBrian West <brian@freeswitch.org>
Sat, 9 Feb 2008 22:36:00 +0000 (22:36 +0000)
committerBrian West <brian@freeswitch.org>
Sat, 9 Feb 2008 22:36:00 +0000 (22:36 +0000)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@7572 d0543943-73ff-0310-b7d9-9358b9ac24b2

32 files changed:
libs/voipcodecs/src/g711.c
libs/voipcodecs/src/g722_decode.c
libs/voipcodecs/src/g722_encode.c
libs/voipcodecs/src/g726.c
libs/voipcodecs/src/gsm0610_decode.c
libs/voipcodecs/src/gsm0610_encode.c
libs/voipcodecs/src/gsm0610_long_term.c
libs/voipcodecs/src/gsm0610_lpc.c
libs/voipcodecs/src/gsm0610_preprocess.c
libs/voipcodecs/src/gsm0610_rpe.c
libs/voipcodecs/src/gsm0610_short_term.c
libs/voipcodecs/src/ima_adpcm.c
libs/voipcodecs/src/lpc10_analyse.c
libs/voipcodecs/src/lpc10_decode.c
libs/voipcodecs/src/lpc10_encode.c
libs/voipcodecs/src/lpc10_placev.c
libs/voipcodecs/src/lpc10_voicing.c
libs/voipcodecs/src/oki_adpcm.c
libs/voipcodecs/src/voipcodecs/bit_operations.h
libs/voipcodecs/src/voipcodecs/bitstream.h
libs/voipcodecs/src/voipcodecs/dc_restore.h
libs/voipcodecs/src/voipcodecs/g711.h
libs/voipcodecs/src/voipcodecs/g722.h
libs/voipcodecs/src/voipcodecs/g726.h
libs/voipcodecs/src/voipcodecs/gsm0610.h
libs/voipcodecs/src/voipcodecs/ima_adpcm.h
libs/voipcodecs/src/voipcodecs/lpc10.h
libs/voipcodecs/src/voipcodecs/oki_adpcm.h
libs/voipcodecs/src/voipcodecs/telephony.h
libs/voipcodecs/src/voipcodecs/vector_int.h
libs/voipcodecs/src/voipcodecs/version.h
libs/voipcodecs/src/voipcodecs/version.h.in

index 6568bd1b4b89b1fc9ab3485f99f16c1933b4265e..bc63f67264282c32eb979dffb4609bc3cc28cf42 100644 (file)
@@ -10,8 +10,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser Lesser GNU General Public License version 2.1.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -22,7 +23,7 @@
  * along with this program; if not, write to the Free Software
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  *
- * $Id: g711.c,v 1.4 2006/11/19 14:07:24 steveu Exp $
+ * $Id: g711.c,v 1.6 2008/02/09 15:32:56 steveu Exp $
  */
 
 /*! \file */
index 8b52b843425bf5bc1affa3c0c64762e1123bd8aa..a173f892d05e6268319f21d23c82c59136de2486 100644 (file)
@@ -10,8 +10,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser Lesser GNU General Public License version 2.1.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -28,7 +29,7 @@
  * Computer Science, Speech Group
  * Chengxiang Lu and Alex Hauptmann
  *
- * $Id: g722_decode.c,v 1.19 2007/03/14 11:51:01 steveu Exp $
+ * $Id: g722_decode.c,v 1.20 2008/02/09 15:32:56 steveu Exp $
  */
 
 /*! \file */
index 3612b7d50c90ddcc7d9685c5f9d8434717c97426..e90a419eac3e39db3366818c21eb6c5bed15416d 100644 (file)
@@ -10,8 +10,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser Lesser GNU General Public License version 2.1.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -28,7 +29,7 @@
  * Computer Science, Speech Group
  * Chengxiang Lu and Alex Hauptmann
  *
- * $Id: g722_encode.c,v 1.17 2007/03/14 11:51:01 steveu Exp $
+ * $Id: g722_encode.c,v 1.18 2008/02/09 15:32:56 steveu Exp $
  */
 
 /*! \file */
index e7172219ad8746fde305358461d406b1c09d497c..b63c945ff96a5ce3b5f25d33cc0de4891f500e31 100644 (file)
@@ -10,8 +10,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -48,7 +49,7 @@
  * 2550 Garcia Avenue
  * Mountain View, California  94043
  *
- * $Id: g726.c,v 1.17 2006/11/19 14:07:24 steveu Exp $
+ * $Id: g726.c,v 1.18 2008/02/09 15:32:56 steveu Exp $
  */
 
 /*! \file */
index a4d26371af41cd66af6d3109f93c0543d7cd73bc..ce852dc9ecec73e557076247591f12726c4d0c66 100644 (file)
@@ -10,8 +10,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -25,7 +26,7 @@
  * This code is based on the widely used GSM 06.10 code available from
  * http://kbs.cs.tu-berlin.de/~jutta/toast.html
  *
- * $Id: gsm0610_decode.c,v 1.14 2007/08/21 14:25:54 steveu Exp $
+ * $Id: gsm0610_decode.c,v 1.15 2008/02/09 15:31:36 steveu Exp $
  */
 
 /*! \file */
index b0ce3004b80f6140d0934feef1ef212f25bff5be..f6209fb2025ed56b2fe000ad03b8d3d1b82bf8bf 100644 (file)
@@ -10,8 +10,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -25,7 +26,7 @@
  * This code is based on the widely used GSM 06.10 code available from
  * http://kbs.cs.tu-berlin.de/~jutta/toast.html
  *
- * $Id: gsm0610_encode.c,v 1.17 2007/11/26 13:28:59 steveu Exp $
+ * $Id: gsm0610_encode.c,v 1.18 2008/02/09 15:31:36 steveu Exp $
  */
 
 /*! \file */
index f8bc8902beb7a85e354027dc6f3ffc18cc36ab25..ade57f6b568933b2ddef183bcd35dbd45870c358 100644 (file)
@@ -10,8 +10,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -25,7 +26,7 @@
  * This code is based on the widely used GSM 06.10 code available from
  * http://kbs.cs.tu-berlin.de/~jutta/toast.html
  *
- * $Id: gsm0610_long_term.c,v 1.10 2007/08/20 15:22:22 steveu Exp $
+ * $Id: gsm0610_long_term.c,v 1.11 2008/02/09 15:31:36 steveu Exp $
  */
 
 /*! \file */
index c53e64c7e46f658bd2274465b27161ae98978217..5873908ec772d9a4c8f5911f6040e825c87ed071 100644 (file)
@@ -10,8 +10,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -25,7 +26,7 @@
  * This code is based on the widely used GSM 06.10 code available from
  * http://kbs.cs.tu-berlin.de/~jutta/toast.html
  *
- * $Id: gsm0610_lpc.c,v 1.15 2007/08/20 15:22:22 steveu Exp $
+ * $Id: gsm0610_lpc.c,v 1.16 2008/02/09 15:31:36 steveu Exp $
  */
 
 /*! \file */
index cef911a5cc1167052d12daf183b00fe062f42f12..c237d4647932bc4d8b1d5d56a06a5b8987c744ff 100644 (file)
@@ -10,8 +10,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -25,7 +26,7 @@
  * This code is based on the widely used GSM 06.10 code available from
  * http://kbs.cs.tu-berlin.de/~jutta/toast.html
  *
- * $Id: gsm0610_preprocess.c,v 1.8 2007/08/20 15:22:22 steveu Exp $
+ * $Id: gsm0610_preprocess.c,v 1.9 2008/02/09 15:31:36 steveu Exp $
  */
 
 /*! \file */
index 2e03fd9098bd76db472fade66de1416b3def07d6..f0f09ca06f56753b74a59ad3bb778214e019bbac 100644 (file)
@@ -10,8 +10,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -25,7 +26,7 @@
  * This code is based on the widely used GSM 06.10 code available from
  * http://kbs.cs.tu-berlin.de/~jutta/toast.html
  *
- * $Id: gsm0610_rpe.c,v 1.14 2007/08/20 15:22:22 steveu Exp $
+ * $Id: gsm0610_rpe.c,v 1.15 2008/02/09 15:31:36 steveu Exp $
  */
 
 /*! \file */
index fb0cbab65ce4e92ac6d59e2280815c29d889d18d..8b96865b6c5354e783eef8c905f5888eb42daac5 100644 (file)
@@ -10,8 +10,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -25,7 +26,7 @@
  * This code is based on the widely used GSM 06.10 code available from
  * http://kbs.cs.tu-berlin.de/~jutta/toast.html
  *
- * $Id: gsm0610_short_term.c,v 1.10 2007/08/20 15:22:22 steveu Exp $
+ * $Id: gsm0610_short_term.c,v 1.11 2008/02/09 15:31:36 steveu Exp $
  */
 
 /*! \file */
index d721cd10e4ae387230ff807eb596af86efcdfff0..6612bb3fc220fb54ff0c3070925819c937adebf7 100644 (file)
@@ -11,8 +11,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
index b88eb06ccb13132c02df725e88c8215d201ed92a..8be5b5229581d1479e7cb2957dcb628a1be1e7ac 100644 (file)
@@ -10,8 +10,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -26,7 +27,7 @@
  * implementation of the LPC-10 2400 bps Voice Coder. They do not
  * exert copyright claims on their code, and it may be freely used.
  *
- * $Id: lpc10_analyse.c,v 1.13 2007/01/03 14:15:35 steveu Exp $
+ * $Id: lpc10_analyse.c,v 1.15 2008/02/09 15:31:36 steveu Exp $
  */
 
 #ifdef HAVE_CONFIG_H
@@ -78,13 +79,13 @@ static void remove_dc_bias(float speech[], int len, float sigout[])
 /*- End of function --------------------------------------------------------*/
 
 static void eval_amdf(float speech[],
-                       int32_t lpita,
-                       const int32_t tau[], 
-                       int32_t ltau,
-                       int32_t maxlag,
-                       float amdf[],
-                       int32_t *minptr,
-                       int32_t *maxptr)
+                      int32_t lpita,
+                      const int32_t tau[], 
+                      int32_t ltau,
+                      int32_t maxlag,
+                      float amdf[],
+                      int32_t *minptr,
+                      int32_t *maxptr)
 {
     float sum;
     int i;
@@ -307,13 +308,13 @@ static void dynamic_pitch_tracking(lpc10_encode_state_t *s,
 
 /* Detection of onsets in (or slightly preceding) the futuremost frame of speech. */
 static void onset(lpc10_encode_state_t *s,
-                   float *pebuf,
-                   int32_t osbuf[],
-                   int32_t *osptr,
-                   int32_t oslen,
-                   int32_t sbufl,
-                   int32_t sbufh,
-                   int32_t lframe)
+                  float *pebuf,
+                  int32_t osbuf[],
+                  int32_t *osptr,
+                  int32_t oslen,
+                  int32_t sbufl,
+                  int32_t sbufh,
+                  int32_t lframe)
 {
     int32_t i;
     float r1;
index e58ab020472e2fc14184e7893f4e8f5108906d44..107542a68a9d9019b7846a2d19d9661df89017e4 100644 (file)
@@ -10,8 +10,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -26,7 +27,7 @@
  * implementation of the LPC-10 2400 bps Voice Coder. They do not
  * exert copyright claims on their code, and it may be freely used.
  *
- * $Id: lpc10_decode.c,v 1.16 2007/11/26 13:28:59 steveu Exp $
+ * $Id: lpc10_decode.c,v 1.18 2008/02/09 15:31:36 steveu Exp $
  */
 
 #ifdef HAVE_CONFIG_H
@@ -1079,7 +1080,7 @@ int lpc10_decode_release(lpc10_decode_state_t *s)
 }
 /*- End of function --------------------------------------------------------*/
 
-int lpc10_decode(lpc10_decode_state_t *s, int16_t amp[], const uint8_t code[], int quant)
+int lpc10_decode(lpc10_decode_state_t *s, int16_t amp[], const uint8_t code[], int len)
 {
     int voice[2];
     int32_t pitch;
@@ -1089,18 +1090,21 @@ int lpc10_decode(lpc10_decode_state_t *s, int16_t amp[], const uint8_t code[], i
     float rms;
     int i;
     int j;
+    int base;
 
-    /* Decode 54 bits to LPC10_SAMPLES_PER_FRAME speech samples. */
-    for (i = 0;  i < quant;  i++)
+    /* Decode 54 bits in 7 bytes to LPC10_SAMPLES_PER_FRAME speech samples. */
+    len /= 7;
+    for (i = 0;  i < len;  i++)
     {
         lpc10_unpack(&frame, &code[i*7]);
         decode(s, &frame, voice, &pitch, &rms, rc);
         synths(s, voice, &pitch, &rms, rc, speech);
+        base = i*LPC10_SAMPLES_PER_FRAME;
         for (j = 0;  j < LPC10_SAMPLES_PER_FRAME;  j++)
-            amp[i*LPC10_SAMPLES_PER_FRAME + j] = (int16_t) rintf(32768.0f*speech[j]);
+            amp[base + j] = (int16_t) rintf(32768.0f*speech[j]);
     }
 
-    return quant*LPC10_SAMPLES_PER_FRAME;
+    return len*LPC10_SAMPLES_PER_FRAME;
 }
 /*- End of function --------------------------------------------------------*/
 /*- End of file ------------------------------------------------------------*/
index 83a15eb4287f488a65a27b454f6bf95d1e119add..c12708987fdb9d7d620da38a6f315ab6cdc2ebe6 100644 (file)
@@ -10,8 +10,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -26,7 +27,7 @@
  * implementation of the LPC-10 2400 bps Voice Coder. They do not
  * exert copyright claims on their code, and it may be freely used.
  *
- * $Id: lpc10_encode.c,v 1.17 2007/11/26 13:28:59 steveu Exp $
+ * $Id: lpc10_encode.c,v 1.19 2008/02/09 15:31:36 steveu Exp $
  */
 
 #ifdef HAVE_CONFIG_H
@@ -368,7 +369,7 @@ int lpc10_encode_release(lpc10_encode_state_t *s)
 }
 /*- End of function --------------------------------------------------------*/
 
-int lpc10_encode(lpc10_encode_state_t *s, uint8_t code[], const int16_t amp[], int quant)
+int lpc10_encode(lpc10_encode_state_t *s, uint8_t code[], const int16_t amp[], int len)
 {
     int32_t voice[2];
     int32_t pitch;
@@ -379,7 +380,8 @@ int lpc10_encode(lpc10_encode_state_t *s, uint8_t code[], const int16_t amp[], i
     int i;
     int j;
 
-    for (i = 0;  i < quant;  i++)
+    len /= LPC10_SAMPLES_PER_FRAME;
+    for (i = 0;  i < len;  i++)
     {
         for (j = 0;  j < LPC10_SAMPLES_PER_FRAME;  j++)
             speech[j] = (float) amp[i*LPC10_SAMPLES_PER_FRAME + j]/32768.0f;
@@ -388,7 +390,7 @@ int lpc10_encode(lpc10_encode_state_t *s, uint8_t code[], const int16_t amp[], i
         encode(s, &frame, voice, pitch, rms, rc);
         lpc10_pack(s, &code[7*i], &frame);
     }
-    return quant*7;
+    return len*7;
 }
 /*- End of function --------------------------------------------------------*/
 /*- End of file ------------------------------------------------------------*/
index e1d819ba3805c3a52566171ab55d8b920a6bb0cd..ccf8653cf40075f4095a1ca33e6e39a24d5fb2a9 100644 (file)
@@ -10,8 +10,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -26,7 +27,7 @@
  * implementation of the LPC-10 2400 bps Voice Coder. They do not
  * exert copyright claims on their code, and it may be freely used.
  *
- * $Id: lpc10_placev.c,v 1.12 2007/01/03 14:15:35 steveu Exp $
+ * $Id: lpc10_placev.c,v 1.13 2008/02/09 15:31:36 steveu Exp $
  */
 
 #ifdef HAVE_CONFIG_H
index cd297c0cb143f6acfbb5e8ad070ac8b0a187c467..55df585210fad997c8898c96368eb4f0bf9ffa92 100644 (file)
@@ -10,8 +10,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -26,7 +27,7 @@
  * implementation of the LPC-10 2400 bps Voice Coder. They do not
  * exert copyright claims on their code, and it may be freely used.
  *
- * $Id: lpc10_voicing.c,v 1.7 2006/11/30 15:41:47 steveu Exp $
+ * $Id: lpc10_voicing.c,v 1.9 2008/02/09 15:31:36 steveu Exp $
  */
 
 #ifdef HAVE_CONFIG_H
 #include "lpc10_encdecs.h"
 
 static void vparms(int32_t vwin[],
-                    float *inbuf,
-                    float *lpbuf,
-                    const int32_t buflim[],
-                    int32_t half,
-                    float *dither,
-                    int32_t *mintau,
-                    int32_t *zc, 
-                    int32_t *lbe,
-                    int32_t *fbe,
-                    float *qs,
-                    float *rc1,
-                    float *ar_b,
-                    float *ar_f)
+                   float *inbuf,
+                   float *lpbuf,
+                   const int32_t buflim[],
+                   int32_t half,
+                   float *dither,
+                   int32_t *mintau,
+                   int32_t *zc, 
+                   int32_t *lbe,
+                   int32_t *fbe,
+                   float *qs,
+                   float *rc1,
+                   float *ar_b,
+                   float *ar_f)
 {
     int32_t inbuf_offset;
     int32_t lpbuf_offset;
index 107304879509d5e30abed76fb4db15e74a845dca..d8784ad0f21e096d271a405fb3b363ef5e0e9b66 100644 (file)
@@ -15,8 +15,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -27,7 +28,7 @@
  * along with this program; if not, write to the Free Software
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  *
- * $Id: oki_adpcm.c,v 1.22 2006/11/28 16:59:56 steveu Exp $
+ * $Id: oki_adpcm.c,v 1.23 2008/02/09 15:33:40 steveu Exp $
  */
 
 /*! \file */
index 9d5e928ca49a0a97c4f26f3d57a4c0bbe9b5aac7..cf643680c90c0db2da9677941d0462c226c63d1e 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * SpanDSP - a series of DSP components for telephony
+ * VoIPcodecs - a series of DSP components for telephony
  *
  * bit_operations.h - Various bit level operations, such as bit reversal
  *
index 15131fdcce25685efa31949e5a45baaab046a37c..ccd9e9b87dfd3e9e688466318d5a71b5d4422b96 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * SpanDSP - a series of DSP components for telephony
+ * VoIPcodecs - a series of DSP components for telephony
  *
  * bitstream.h - Bitstream composition and decomposition routines.
  *
index 64fee03456e5deb8e2559d0fccef0a16fb0cdc11..7846f37f4640a8e9baec2602a0d42dc846b09a00 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * SpanDSP - a series of DSP components for telephony
+ * VoIPcodecs - a series of DSP components for telephony
  *
  * dc_restore.h - General telephony routines to restore the zero D.C.
  *                level to audio which has a D.C. bias.
@@ -11,7 +11,7 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
+ * it under the terms of the GNU General Public License version 2, as
  * published by the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
index bf4b8e72b8be9f888824dfb04cfff8571ae6d0e4..3e7ca63a44a81af0cc540b01f079e280073b5463 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * SpanDSP - a series of DSP components for telephony
+ * VoIPcodecs - a series of DSP components for telephony
  *
  * g711.h - In line A-law and u-law conversion routines
  *
@@ -10,8 +10,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -22,7 +23,7 @@
  * along with this program; if not, write to the Free Software
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  *
- * $Id: g711.h,v 1.8 2007/12/13 11:31:32 steveu Exp $
+ * $Id: g711.h,v 1.9 2008/02/09 15:32:26 steveu Exp $
  */
 
 /*! \file */
index d96d15b21d9e39af0a57e060eba1215b3288a301..966992fd00002dd579c1bdb28d89beaa370c9d4d 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * SpanDSP - a series of DSP components for telephony
+ * VoIPcodecs - a series of DSP components for telephony
  *
  * g722.h - The ITU G.722 codec.
  *
@@ -10,8 +10,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -28,7 +29,7 @@
  * Computer Science, Speech Group
  * Chengxiang Lu and Alex Hauptmann
  *
- * $Id: g722.h,v 1.16 2007/04/08 08:16:17 steveu Exp $
+ * $Id: g722.h,v 1.17 2008/02/09 15:32:26 steveu Exp $
  */
 
 
index df2e0b94807540bf1e43de980276aeccb023a86e..f1212e3cfbbfe2e70b9b8bb896c8a9dabc438c8e 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * SpanDSP - a series of DSP components for telephony
+ * VoIPcodecs - a series of DSP components for telephony
  *
  * g726.h - ITU G.726 codec.
  *
@@ -10,8 +10,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * along with this program; if not, write to the Free Software
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  *
- * Based on G.721/G.723 code which is:
- *
- * This source code is a product of Sun Microsystems, Inc. and is provided
- * for unrestricted use.  Users may copy or modify this source code without
- * charge.
- *
- * SUN SOURCE CODE IS PROVIDED AS IS WITH NO WARRANTIES OF ANY KIND INCLUDING
- * THE WARRANTIES OF DESIGN, MERCHANTIBILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE, OR ARISING FROM A COURSE OF DEALING, USAGE OR TRADE PRACTICE.
- *
- * Sun source code is provided with no support and without any obligation on
- * the part of Sun Microsystems, Inc. to assist in its use, correction,
- * modification or enhancement.
- *
- * SUN MICROSYSTEMS, INC. SHALL HAVE NO LIABILITY WITH RESPECT TO THE
- * INFRINGEMENT OF COPYRIGHTS, TRADE SECRETS OR ANY PATENTS BY THIS SOFTWARE
- * OR ANY PART THEREOF.
- *
- * In no event will Sun Microsystems, Inc. be liable for any lost revenue
- * or profits or other special, indirect and consequential damages, even if
- * Sun has been advised of the possibility of such damages.
- *
- * Sun Microsystems, Inc.
- * 2550 Garcia Avenue
- * Mountain View, California  94043
- *
- * $Id: g726.h,v 1.18 2007/12/13 11:31:32 steveu Exp $
+ * $Id: g726.h,v 1.19 2008/02/09 15:32:26 steveu Exp $
  */
 
 /*! \file */
index 282065adccf8bdc32e37cc56cd94e1f64aeb690b..83e05e89f5a4b23fde136069fed37daa4743a009 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * SpanDSP - a series of DSP components for telephony
+ * VoIPcodecs - a series of DSP components for telephony
  *
  * gsm0610.h - GSM 06.10 full rate speech codec.
  *
@@ -10,8 +10,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -22,7 +23,7 @@
  * along with this program; if not, write to the Free Software
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  *
- * $Id: gsm0610.h,v 1.13 2007/12/13 11:31:32 steveu Exp $
+ * $Id: gsm0610.h,v 1.14 2008/02/09 15:31:36 steveu Exp $
  */
 
 #if !defined(_SPANDSP_GSM0610_H_)
index 573f5066caa0f5cb5339b44702fefeee9ac2658f..e3976b1ad51fe8cd00f145f0bb1e54489438f219 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * SpanDSP - a series of DSP components for telephony
+ * VoIPcodecs - a series of DSP components for telephony
  *
  * imaadpcm.c - Conversion routines between linear 16 bit PCM data and
  *                     IMA/DVI/Intel ADPCM format.
index 192d63dcaca14d7687dd8540b9ad7803ec2e547f..24b4c14a7c9a44026e2f9b4cd08b9eac0c2a66e3 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * SpanDSP - a series of DSP components for telephony
+ * VoIPcodecs - a series of DSP components for telephony
  *
  * lpc10.h - LPC10 low bit rate speech codec.
  *
@@ -10,8 +10,9 @@
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -22,7 +23,7 @@
  * along with this program; if not, write to the Free Software
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  *
- * $Id: lpc10.h,v 1.13 2007/04/08 08:16:18 steveu Exp $
+ * $Id: lpc10.h,v 1.15 2008/02/09 15:31:36 steveu Exp $
  */
 
 #if !defined(_SPANDSP_LPC10_H_)
@@ -184,9 +185,10 @@ int lpc10_encode_release(lpc10_encode_state_t *s);
     \param s The LPC10e context.
     \param ima_data The LPC10e data produced.
     \param amp The audio sample buffer.
-    \param len The number of samples in the buffer.
+    \param len The number of samples in the buffer. This must be a multiple of 180, as
+           this is the number of samples on a frame.
     \return The number of bytes of LPC10e data produced. */
-int lpc10_encode(lpc10_encode_state_t *s, uint8_t code[], const int16_t amp[], int quant);
+int lpc10_encode(lpc10_encode_state_t *s, uint8_t code[], const int16_t amp[], int len);
 
 /*! Initialise an LPC10e decode context.
     \param s The LPC10e context
@@ -200,9 +202,10 @@ int lpc10_decode_release(lpc10_decode_state_t *s);
     \param s The LPC10e context.
     \param amp The audio sample buffer.
     \param code The LPC10e data.
-    \param quant The number of frames of LPC10e data to be decoded.
+    \param len The number of bytes of LPC10e data to be decoded. This must be a multiple of 7,
+           as each frame is packed into 7 bytes.
     \return The number of samples returned. */
-int lpc10_decode(lpc10_decode_state_t *s, int16_t amp[], const uint8_t code[], int quant);
+int lpc10_decode(lpc10_decode_state_t *s, int16_t amp[], const uint8_t code[], int len);
 
 
 #if defined(__cplusplus)
index d050a995ee0d27844c227857d1730c15b0560b28..9c68720be3fb352ce47aba10c51e1b7afd47ce8a 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * SpanDSP - a series of DSP components for telephony
+ * VoIPcodecs - a series of DSP components for telephony
  *
  * oki_adpcm.h - Conversion routines between linear 16 bit PCM data and
  *                      OKI (Dialogic) ADPCM format.
@@ -8,14 +8,12 @@
  *
  * Copyright (C) 2001 Steve Underwood
  *
- * Based on a bit from here, a bit from there, eye of toad,
- * ear of bat, etc - plus, of course, my own 2 cents.
- *
  * All rights reserved.
  *
  * This program is free software; you can redistribute it and/or modify
- * it under the terms of the Lesser GNU General Public License version 2.1, as
- * published by the Free Software Foundation.
+ * it under the terms of the GNU General Public License version 2, or
+ * the Lesser GNU General Public License version 2.1, as published by
+ * the Free Software Foundation.
  *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -26,7 +24,7 @@
  * along with this program; if not, write to the Free Software
  * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  *
- * $Id: oki_adpcm.h,v 1.17 2007/12/13 11:31:33 steveu Exp $
+ * $Id: oki_adpcm.h,v 1.18 2008/02/09 15:33:40 steveu Exp $
  */
 
 /*! \file */
index e9f079a27bf9f2080d54d61a76a90bd96e7de0b3..b33786ef0980bc913df39d1ce7f3c041676d1011 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * SpanDSP - a series of DSP components for telephony
+ * VoIPcodecs - a series of DSP components for telephony
  *
  * telephony.h - some very basic telephony definitions
  *
index 92591ef0969f721b8aeb369e23ac22614bd5cf03..9a162a73091e25426d4a537e1f98dd0dd9e23eb2 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * SpanDSP - a series of DSP components for telephony
+ * VoIPcodecs - a series of DSP components for telephony
  *
  * vector_int.h
  *
index 9991ad2268321b2380e3eb13bd53842d68e4b819..b7b2992936c393365006da534eddc56075150f21 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * SpanDSP - a series of DSP components for telephony
+ * VoIPcodecs - a series of DSP components for telephony
  *
  * version.h - A tag file, so the exact installed revision can be assertained.
  *
index 9991ad2268321b2380e3eb13bd53842d68e4b819..b7b2992936c393365006da534eddc56075150f21 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * SpanDSP - a series of DSP components for telephony
+ * VoIPcodecs - a series of DSP components for telephony
  *
  * version.h - A tag file, so the exact installed revision can be assertained.
  *