I'm a new Asterisk user. I've managed to set it up to do everything I want except sound good. Currently, Asterisk sounds considerably worse than my cell phone. I know VOIP can be _better_ than my cell phone, because I've heard Skype do it. (Using 32k iLBC, I believe.) I did an experiment with audio quality: 1) I made a recording which was pretty good. I used an iSight microphone and recorded at its native 48k sampling rate in Audacity. Then I trimmed it and ran their noise reduction filter. 2) I transformed it into a bunch of other formats with this script: for base in "$@"; do for rate in 8000 16000 32000; do sox "$base"-48000.wav -r $rate "$base"-$rate.wav resample -ql speexenc --vad --dtx --rate $rate "$base"-$rate.wav "$base"-$rate.spx speexdec "$base"-$rate.spx "$base"-$rate-fromspx.wav done sox "$base"-8000.wav "$base"-8000.gsm done 3) I listened to them all with Quicktime Player. From that I determined that a WAV with 32k sampling rate sounds good to me, but I'm not happy with 8k or 16k. Since adding lossy compression is only going to make things worse, that rules out most of Asterisk's codecs. The 32k (ultra-wideband) speex with default settings sounds good, and it's a free codec. I'm not real concerned about bandwidth use, but it does pretty well there, too. I understand that Skype uses ultra-wideband iLBC; it's audio quality is also good. But I understand there are patent problems. (Are licenses even available? How much do they cost?) I've got three problems for actually using this though: 1) Can asterisk load 32k audio files? I see that the current CVS's format_wav.c can not. Is there another module that does? I might try modifying the WAV loader. Are there assumptions of 8k throughout Asterisk, or is this pretty isolated to that file? 2) Are there higher quality versions of the Asterisk sounds? They're in a nice, professional voice, but 8K GSM just sounds awful. If the source encodings are available, I could resample them into whatever else in a similar fashion to what I've done above. 3) Are there clients that support the 32k sampling rate? a) I'm particularly interested in softphones for OS X. The ones I see are X-Lite, SJphone, and iaxComm. X-Lite has some weird distortion problems for me with even 8k ulaw (<http://support.xten.net/ viewtopic.php?t=3626>). SJphone's Speex support is weird - they have 8.0k and 15.2 k (?). iaxComm has the settings I want, but they sound awful. I'm not giving it a fair test, though; see #1. (None of these have a decent user interface either, but one problem at a time...) b) Any hardware phones? Regards, Scott -- Scott Lamb <http://www.slamb.org/>
Scott, I have been using xten's eyebeam and a jabra bluetooth headset with pretty good results. The local calls to PC's and out an analog line have been good. I have *@home 1.0 with a clone X100P card. Robert> From: Scott Lamb <slamb@slamb.org> > Reply-To: Asterisk Users Mailing List - Non-Commercial Discussion > <asterisk-users@lists.digium.com> > Date: Fri, 13 May 2005 17:36:00 -0700 > To: asterisk-users@lists.digium.com > Subject: [Asterisk-Users] Audio quality > > I'm a new Asterisk user. I've managed to set it up to do everything I > want except sound good. Currently, Asterisk sounds considerably worse > than my cell phone. I know VOIP can be _better_ than my cell phone, > because I've heard Skype do it. (Using 32k iLBC, I believe.) > > I did an experiment with audio quality: > > 1) I made a recording which was pretty good. I used an iSight > microphone and recorded at its native 48k sampling rate in Audacity. > Then I trimmed it and ran their noise reduction filter. > > 2) I transformed it into a bunch of other formats with this script: > > for base in "$@"; do > for rate in 8000 16000 32000; do > sox "$base"-48000.wav -r $rate "$base"-$rate.wav > resample -ql > speexenc --vad --dtx --rate $rate "$base"-$rate.wav > "$base"-$rate.spx > speexdec "$base"-$rate.spx "$base"-$rate-fromspx.wav > done > sox "$base"-8000.wav "$base"-8000.gsm > done > > 3) I listened to them all with Quicktime Player. > > From that I determined that a WAV with 32k sampling rate sounds good > to me, but I'm not happy with 8k or 16k. Since adding lossy > compression is only going to make things worse, that rules out most > of Asterisk's codecs. > > The 32k (ultra-wideband) speex with default settings sounds good, and > it's a free codec. I'm not real concerned about bandwidth use, but it > does pretty well there, too. > > I understand that Skype uses ultra-wideband iLBC; it's audio quality > is also good. But I understand there are patent problems. (Are > licenses even available? How much do they cost?) > > I've got three problems for actually using this though: > > 1) Can asterisk load 32k audio files? I see that the current CVS's > format_wav.c can not. Is there another module that does? I might try > modifying the WAV loader. Are there assumptions of 8k throughout > Asterisk, or is this pretty isolated to that file? > > 2) Are there higher quality versions of the Asterisk sounds? They're > in a nice, professional voice, but 8K GSM just sounds awful. If the > source encodings are available, I could resample them into whatever > else in a similar fashion to what I've done above. > > 3) Are there clients that support the 32k sampling rate? > > a) I'm particularly interested in softphones for OS X. The ones I see > are X-Lite, SJphone, and iaxComm. X-Lite has some weird distortion > problems for me with even 8k ulaw (<http://support.xten.net/ > viewtopic.php?t=3626>). SJphone's Speex support is weird - they have > 8.0k and 15.2 k (?). iaxComm has the settings I want, but they sound > awful. I'm not giving it a fair test, though; see #1. > > (None of these have a decent user interface either, but one problem > at a time...) > > b) Any hardware phones? > > Regards, > Scott > > -- > Scott Lamb <http://www.slamb.org/> > > _______________________________________________ > Asterisk-Users mailing list > Asterisk-Users@lists.digium.com > http://lists.digium.com/mailman/listinfo/asterisk-users > To UNSUBSCRIBE or update options visit: > http://lists.digium.com/mailman/listinfo/asterisk-users
On May 13, 2005, at 8:36 PM, Scott Lamb wrote:> I'm a new Asterisk user. I've managed to set it up to do everything > I want except sound good. Currently, Asterisk sounds considerably > worse than my cell phone. I know VOIP can be _better_ than my cell > phone, because I've heard Skype do it. (Using 32k iLBC, I believe.) >(1) Your cellphone, and the entire PSTN, use an 8khz sample rate. Going over public phone networks, you'll never get more than 8khz sampling. Using asterisk and uLaw, assuming there's no problems on the network, should give you sound equivalent to a land-line phone, which also uses 8kHz uLaw (or, aLaw if you're outside USA, but the sound is basically going to be the same). (2) I think skype uses, in it's "best" mode, wideband (16khz) iLBC. [you wrote "32k", where it isn't clear whether you were talking about kHz or kbps]. Asterisk doesn't presently have support for sample rates other than 8kHz. I don't expect that 1.2 will have this either, as you either need to (a) hack it in using a different "codec" type for each sample- rate, where there are only 16 audio codec type slots in the current API, or (b) make incompatible changes to many APIs, and probably to the IAX2 protocol as well. The iaxclient library has some support for different sample rates in the audio layer, and it's codec drivers, but does not yet have any support for these at the protocol layer. -SteveK