MediaRecorder start failed: -38

前端 未结 2 433
遥遥无期
遥遥无期 2020-11-27 06:48

i searched to check if this question is no dup , i see some has no answer and others did not help.

this is my code :

private void startRecording()
{         


        
相关标签:
2条回答
  • 2020-11-27 07:25

    In my case that error (MediaRecorder: start failed: -38) was appearing after switching to second camera when I forgot to release MediaRecorder during closing (first) camera:

    mediaRecorder?.release()
    mediaRecorder = null
    
    0 讨论(0)
  • 2020-11-27 07:44

    Found the solution , it appears i had some other service in the background which is using AudioRecord and uses the mic as well.... so thats the -38 :)

    0 讨论(0)
提交回复
热议问题