LoudHush Icon



© Modulo Consulting 2005-2010

Enabling the iLBC codec for LoudHush

What is iLBC?

Quoting from the iLBCfreeware.org project homepage: iLBC (internet Low Bitrate Codec) is a FREE speech codec suitable for robust voice communication over IP. The codec is designed for narrow band speech and results in a payload bit rate of 13.33 kbit/s with an encoding frame length of 30 ms and 15.20 kbps with an encoding length of 20 ms. The iLBC codec enables graceful speech quality degradation in the case of lost frames, which occurs in connection with lost or delayed IP packets.

LoudHush is not distributed with the iLBC codec because distributing a iLBC enabled version of LoudHush would require us to go into a commercial agreement with GIPS.

GIPS however, allows "personal, non-commercial use" of iLBC. This article is a step-by-step guide into building a iaxclient version that includes the iLBC codec.


1. Download the iLBC RFC on the Desktop


2. Unpack the LoudHush iaxclient code


tar zvxf iaxclient_v19_ml.tar.gz
cd iaxclient_v19_ml/lib
3. Create the iLBC folder
mkdir iLBC

Download and copy test.awk within the iLBC directory. test.awk is an awk script that parses the RFC to extract the actual C implementation:

BEGIN { srcname = "nothing"; }
{ if (/^A\.[0-9][0-9]*\.* *[a-zA-Z][a-zA-Z_0-9]*\.[ch]/) {
    if (srcname != "nothing")
    srcname = $2;
    printf("creating source file %s\n", srcname);
  }else if (srcname != "nothing") {
    if (/Andersen,* *et* *al\./) 
      printf("skipping %s\n", $0);
    else if (/^L/)
      printf("skipping2 %s\n", $0);
    else if (/Internet Low Bit Rate Codec *December 2004/)
      printf("skipping3 %s\n", $0);
    else if (/Authors' *Addresses/){
      print $0 >> srcname;
  printf("ending file %s\n", srcname);
cd iLBC
cat ~/Desktop/rfc3951.txt | awk -f test.awk

this will create a lot of C files in the iLBC directory.

4. tell iaxclient to compile with iLBC
cd ..

edit Makefile

make clean
make shared 

You should get a new libiaxclient.dylib in the current directory. You can check for a correct compile:

nm libiaxclient.dylib | grep iLBC
0002a8d0 T _iLBC_decode
0002bd80 T _iLBC_encode
5. Enable LoudHush support for iLBC
defaults write com.modulo.LoudHush prefCodecILBC 1
6. install new iaxclient

copy libiaxclient.dylib in LoudHush.app/Contents/Resources (maybe backup original libiaxclient.dylib)

7. start LoudHush, select iLBC, test.

Send any questions or comments to info@loudhush.ro. Thank you.