[pjsip] Audio distortion in Linux
Thomas Kluge
T.Kluge at gmx.com
Tue Mar 10 05:44:43 EDT 2009
We have a strange audio distortion using fileinput or the portaudio
interface in pjsip under linux with the current version and different linux
distribiutions but not in Win32. I would describe the distortion as humming
bass.
I followed the suggestions in the audio troubleshooter section in pjsip wiki
(http://trac.pjsip.org/repos/wiki/sound-problems) but nothing helped.
The distortion depends on the input audio signal level and frequency and is
caused by the encoding side.
The following audio samples shall demonstrate this:
The original source 44.1 KHz 16 bit mono:
www.bercos.de/public/testsounds/test_audio_441_16_cut-mono.wav
Local loop with pjsua in Win32 with G.722
www.bercos.de/public/testsounds/rec_local-PC-16-44100-G722.wav
Audio encoded on Linux and played in Win32 with G.722 (with distortion)
www.bercos.de/public/testsounds/rec_Linux-PC-16-44100-G722.wav
Same as before but encoded with L16/44100 (no difference, with distortion)
www.bercos.de/public/testsounds/rec_Linux-PC-16-44100-L16_441000.wav
Same as before but input over Alsa-Jack->PortAudio->pjsua on Linux (with
distortion)
www.bercos.de/public/testsounds/rec_Linux-PC-linein_Jack-PortAudio-G722.wav
Now back to Alsa input in pjsua on Linux (please ignore drop-outs, sound is
clear)
www.bercos.de/public/testsounds/rec_Linux-PC-Micro-44100-G722.wav
Used command line options (have no influence on the problem):
--ec-tail=0
--no-vad
--quality=6
user.mak settings
export CFLAGS += -DPA_USE_JACK=1 -DPA_USE_ALSA=1 -DPA_USE_OSS=1
export LDFLAGS += -ljack
export PORTAUDIO_OBJS += pa_jack.o pa_ringbuffer.o
config_site.h settings
#define PJMEDIA_HAS_GSM_CODEC 0
#define PJMEDIA_HAS_L16_CODEC 1
#define PJMEDIA_HAS_ILBC_CODEC 0
#define PJMEDIA_HAS_SPEEX_CODEC 1
#define PJMEDIA_HAS_G722_CODEC 1
#define PJMEDIA_HAS_SRTP 1
Does anybody have an idea what the reason might be?
Another problem:
If define PJMEDIA_HAS_SRTP is enabled (default), pjsua crashes in
function pjmedia_transport_srtp_create() line 279 of endpoint.c
(Nullpointer: endpt is NULL)
return pj_pool_create(endpt->pf, name, initial, increment, NULL);
(only in Win32 Release Version)
best wishes,
Thomas Kluge
More information about the pjsip
mailing list