On Tue, Oct 30, 2007 at 06:54:45PM +0200, Eran Levy wrote: > Hi, > Any idea how to convert .MP3 to .GSM? I could not find a good application.
I figure you want this for Asterisk. Almost all audio codecs on Asterisk (except g722) use a phone quality audio: 8000Hz, 16bit samples, mono. MP#s you'll find are typically of much higher quality. Hence down-sampling the MP3 file to even a .wav file of the same quality will usually generate a file of comparable size to the original MP3 file, rather than the huge size you'd expect. gsm and other compressed codecs will generate smaller files. But you're also degregating audio quality . Anyway, here's a little script to help you: #!/bin/sh # make_ast_wav: convert sound files to "wav" files Asterisk likes. # Usage: make_ast_wav file1 [file2 ..] # files should have extensions sox identifies (.mp3 , .ogg, etc.) # downsampling .wav files is not supported. for src in "$@"; do base=`echo $src | rev | cut -d. -f2-| rev` sox $src -w -c 1 -r 8000 $base.wav done -- Tzafrir Cohen | [EMAIL PROTECTED] | VIM is http://tzafrir.org.il | | a Mutt's [EMAIL PROTECTED] | | best ICQ# 16849754 | | friend ================================================================= To unsubscribe, send mail to [EMAIL PROTECTED] with the word "unsubscribe" in the message body, e.g., run the command echo unsubscribe | mail [EMAIL PROTECTED]