My android application needs to convert PCM(22khz) to AMR , but the API AmrInputStream only supports with pcm of 8khz.
How can i downsample the pcm from 22 khz to 8 khz?
My android application needs to convert PCM(22khz) to AMR , but the API AmrInputStream only supports with pcm of 8khz.
How can i downsample the pcm from 22 khz to 8 khz?
The sample rate is hard coded in AmrInputStream.java.
So you have to convert the PCM to AMR first.
For Downsampling, You can try the Mary API.
I find a java downsample lib :https://github.com/hutm/JSSRC there is also a c version could be used by jni