Audio compression in android

3.3k Views Asked by At

I want to send some speech file over internet to my server. My server will do the same. But some speech file or audio files are large in size. My aim is to compress that audio data to server. I found speex do the same. I am unable to get how to use speex in my android. For java there is jspeex jar available. Any sample program or tutorial on how to use speex for compressing my audio data or any other way to compress audio data will help me. I need you support.

Thanks Deepak

3

There are 3 best solutions below

0
On

If you are brave enough to try android-ndk stuff, see if https://github.com/mutantbob/ndk-speex works for you.

0
On

You cannot use this library because google has removed the package javax.sound.sampled.spi which is used by the jspeex library

2
On

You would just import the JAR. If you're using eclipse, right click on your project > properties > build path, then import the JAR. import it into your file to do the compression and then call the functions you wish to use for compression.

Take a look at JSpeex javadoc to see how you would achieve what you want.. http://jspeex.sourceforge.net/doc/index.html