[asterisk-dev] speexenc and ControlPlayback garbled

Tzafrir Cohen tzafrir.cohen at xorcom.com
Sun Feb 5 21:13:06 MST 2006


On Sun, Feb 05, 2006 at 07:29:25PM -0800, Mike Taht wrote:

> #!/bin/sh
> 
> # Takes mp3s on the command line, converts to 8000 khz ulaw, gsm, speex
> 
> for i in $*
> do
> base=`echo $i | cut -f1 -d.`;
> #madplay --output=$base.wav --sample-rate=8000 -b 16 --attenuate=-1 -m $i;
> # I recompiled sox for madlib support. The resulting polyphase conversion is
> # much better than what madplay outputs by default
> sox $base.mp3 -r 8000 $base.wav polyphase -w ham # seems to give best results

I actually ended up using mpg321 for the mp3->wav conversion.

> # have tried various quality/comp settings
> speexenc -n --quality 10 --comp 10 --bitrate 8000 $base.wav $base.spx
> sox $base.wav $base.gsm # works
> sox $base.wav $base.ul # works
> mv $base.ul $base.ulaw

To write the above two in one line, use sox's -t .

> rm $base.wav # wav files are big
> 
> done
> 
> 
> --
> Mike Taht
> PostCards From the Bleeding Edge
> http://the-edge.blogspot.com
> _______________________________________________
> --Bandwidth and Colocation provided by Easynews.com --
> 
> asterisk-dev mailing list
> To UNSUBSCRIBE or update options visit:
>    http://lists.digium.com/mailman/listinfo/asterisk-dev
> 

-- 
Tzafrir Cohen     icq#16849755  +972-50-7952406
tzafrir.cohen at xorcom.com  http://www.xorcom.com



More information about the asterisk-dev mailing list