我使用MediaRecorder录音,会出异常:
java.lang.RuntimeException: setAudioSource failed.下面是部分代码
.......
m_MyRecorder = new MediaRecorder();
m_MyRecorder.setAudioSource(MediaRecorder.AudioSource.MIC);//这句抛出异常
m_MyRecorder.setOutputFormat(MediaRecorder.OutputFormat.DEFAULT);
m_MyRecorder.setAudioEncoder(MediaRecorder.AudioEncoder.DEFAULT);
m_MyRecorder.setOutputFile(RecordFile.getAbsolutePath());
m_MyRecorder.prepare();
m_MyRecorder.start();
......
请高手指点
java.lang.RuntimeException: setAudioSource failed.下面是部分代码
.......
m_MyRecorder = new MediaRecorder();
m_MyRecorder.setAudioSource(MediaRecorder.AudioSource.MIC);//这句抛出异常
m_MyRecorder.setOutputFormat(MediaRecorder.OutputFormat.DEFAULT);
m_MyRecorder.setAudioEncoder(MediaRecorder.AudioEncoder.DEFAULT);
m_MyRecorder.setOutputFile(RecordFile.getAbsolutePath());
m_MyRecorder.prepare();
m_MyRecorder.start();
......
请高手指点
解决方案 »
- 这种布局为什么按下输入框,键盘会把输入框挡住。。
- android.graphics.drawable怎么设置时间隐藏?
- 如何解决adb shell error:device not found。
- Android 通话中如何关闭听筒?
- app widget 配置活动 update
- android中怎么获得系统用的字体大小和样式啊,跪求。急用。
- 继续做APP还是去做游戏?
- Slidingmenu setTouchModeBehind(SlidingMenu.TOUCHMODE_FULLSCREEN)。菜单无法获取焦点
- dn't find class "jarservicetest.JarService"on path: /data/app/.servicetest-1.apk
- 安卓串口开发
- 关于在Android上运行纯C程序
- android上传图片,后台得不到file
我的 开发板,模拟器,平板电脑(买的产品) 上,所有的 RecordUI 运行时,都出现如下错误码:"RecordUI(进程:record.com)意外停止,请重试"不知是何原因?