Use microphone in webrtc & media recorder simultaneously in Android?

北战南征 提交于 2020-08-17 10:09:23

问题


I am using webrtc for video calling in android. I am simultaneously screen recording after call is connected in sender end. I am getting this error log in sender end. Receiver end voice is not hearing when screen recording is started using MediaRecorder. I think webrtc is not streaming audio to receiver end when media recorder is started using microphone.

Error

AudioRecord: start() status -38
2020-06-25 13:37:18.948 3276-5257/com.obs.booking E/WebRtcAudioRecord: WebRtcAudioRecord: Start recording error: AUDIO_RECORD_START_STATE_MISMATCH. AudioRecord.startRecording failed - incorrect state :1
2020-06-25 13:37:18.949 3276-5257/com.obs.booking E/AudioRecordJni: StartRecording failed!
2020-06-25 13:37:18.949 3276-5257/com.obs.booking E/libjingle: (voe_base_impl.cc:439): StartSend: Failed to start recording
2020-06-25 13:37:18.949 3276-5257/com.obs.booking E/libjingle: (voe_base_impl.cc:386): StartSend() failed to start recording
2020-06-25 13:37:18.949 3276-5257/com.obs.booking E/libjingle: (audio_send_stream.cc:245): AudioSendStream::Start failed with error: -1

Help me out to resolve this error.

来源:https://stackoverflow.com/questions/62633876/use-microphone-in-webrtc-media-recorder-simultaneously-in-android

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!