Why following code shows setVideoSource failed exception

后端 未结 1 768
自闭症患者
自闭症患者 2021-01-23 09:34
 MediaRecorder mr=new MediaRecorder();   
 mr.setVideoSource(MediaRecorder.VideoSource.CAMERA);
相关标签:
1条回答
  • 2021-01-23 10:02

    I suggest you first try adding a couple uses-permissions to you AndroidManifest.xml:

    <uses-permission android:name="android.permission.RECORD_VIDEO" />
    <uses-permission android:name="android.permission.CAMERA" />
    
    0 讨论(0)
提交回复
热议问题