Bitrate by default for Audio Recording with MediaRecorder
With java class MediaRecorder, you can record audio with encoder AMR NB (4.75 to 12.2 kbps sampled @ 8kHz)
I developed an app for a mobile with Android 2.2 and the bit rat开发者_运维问答e used was 12.2 kbps by default, but I installed the same apk in a mobile with Android 2.3.3 and I think that bit rate changed to 4.75 kbps by default. Is it normal? The mobile used is Nexus One.
The codec lines for this issue are:
mrecorder.setAudioSource(MediaRecorder.AudioSource.MIC); 
mrecorder.setOutputFormat(MediaRecorder.OutputFormat.RAW_AMR);
mrecorder.setAudioEncoder(MediaRecorder.AudioEncoder.AMR_NB);
I tried to force MediaRecorder to use a specific bitrate with setAudioEncodingBitRate(int bitRate) but it didn´t work.
I don´t understand why bitrate has decreased.
setAudioEncodingBitRate(int bitRate) is not decreased, it is working since API 8 (2.2), and some encoding formats and frequencies, like AAC 44,1KHz, only since API 10 (2.3.3) :(
 
         加载中,请稍侯......
 加载中,请稍侯......
      
精彩评论