[sip-comm] Failure to connect RTP audio streams - JMF and Java


I've been working with mainly with windows XP. I had already installed java 1.4.2_05
and JMF 2.1.1e.

Java (SDK) worked fine with all my other projects and JMF would play MP3 and MPEG
files. It would also capture from the headset microphone.

Even the "base binary version" of sip-communicator would establish and answer calls
successfully, but until yesterday I've failed to get a 2-way call working properly. The
diagnostic log4j traces have sometimes been helpful, but at other times haven't given
me a clue.

I've learnt some things for sure, but only guessed some others. If I write them down
here, perhaps others can share their experiences and correct my misunderstandings.
This should be helpful for anyone starting to use the sip-communicator.

I decided to get the latest source and build it. I had to upgrade to the latest version of
Ant before it would work, but there were no other problems.

I won't bore you with the details, but I found it completely impossible to use my
externally installed JMF. I had to uninstall it and purge all traces of its existence,
including the native windows DLL's and the \Documents and
Settings\username\.jmf\jmf.properties file. I had to set sip-communicator.xml
<FIRST_LAUNCH> back to "true" force JMF re-initialisation.

I also found it impossible to use the windows-accelerated internal JMF, but perhaps
this is because I haven't purged the external package properly. However, I am using
the all-java version successfully and am happy to keep it for now.

I wasn't able to get the latest source working with java 1.4.2. The main problem was

java.lang.IllegalArgumentException: Illegal request to write non-integral number of
frames (22050 bytes )

This is a known bug in java that has been fixed in java 1.5.0. Sun refuse to port the fix to
older releases and after I looked at the differences, I can sympathise. Mid-level sound
support seems to have been moved from JMF into java.

I took a deep breath and stopped fighting... I upgraded to java 1.5.0.

Here's my one-line batch file that is working with the all-java internal JMF...

java -classpath sip-communicator.jar;.;lib;lib\jmf-all\jmf.jar;
-Dlog4j.configuration=log4j.xml -Djava.library.path=./lib

This batch file is in the sip-communicator directory.

Note that "lib" is present in the classpath so that the classloader can find the log4j
properties file. Until I got log4j working properly, the debug messages streamed onto
the console and this seemed to make media stream setup fragile.


Brian Burch


To unsubscribe, e-mail: users-unsubscribe@sip-communicator.dev.java.net
For additional commands, e-mail: users-help@sip-communicator.dev.java.net