Amr录制并获取声音大小
定义对象
1 | private MediaRecorder mMediaRecorder; |
开始录制
1 | private void startRecord() { |
停止录制
1 | private void stopRecord() { |
Amr播放
定义对象
1 | private MediaPlayer mPlayer = null; |
播放
1 | void playVoice(String amrPath) { |
获取Amr时长
1 | /** |
1 | private MediaRecorder mMediaRecorder; |
1 | private void startRecord() { |
1 | private void stopRecord() { |
1 | private MediaPlayer mPlayer = null; |
1 | void playVoice(String amrPath) { |
1 | /** |