[Problem/Question]
If the Android app doesn’t have CAMERA and RECORD_AUDIO when an incoming video DirectCall starts ringing, it requests them in onRinging. The user grants both and we accept() with audio and video enabled. The call connects, but the caller (our web app) gets no audio and no video from the Android user. If the permissions were granted before the call started ringing, everything works.
From reading the SDK: the PeerConnection constructor runs when the DirectCall is created (ringing) and builds the whole media pipeline once: JavaAudioDeviceModule, audio source/track, video source/track. Nothing rebuilds it after a later permission grant. startVideo() and hold()/unhold() (which goes through resumeVideoCapturer()) only replace the capturer inside the existing pipeline, so they don’t recover audio or video. We tried hold()/unhold() on a device; no change.
Same symptom, unanswered: 7883 and 8958
Could you either rebuild the media pipeline on accept(), expose an API to do that.
[SDK Version]
Sendbird Calls Android SDK 1.12.5 (com.sendbird.sdk:sendbird-calls:1.12.5). Caller: Sendbird Calls JavaScript SDK in our web app.
[Reproduction Steps]
-
Revoke CAMERA and RECORD_AUDIO for the Android app (Settings > Apps > Permissions).
-
Place a 1:1 video DirectCall to the Android user.
-
In onRinging, show the incoming-call screen. On “Accept”, request the permissions:
requestPermissions(arrayOf(Manifest.permission.RECORD_AUDIO, Manifest.permission.CAMERA), RC)
-
Grant both. In onRequestPermissionsResult, accept:
val options = CallOptions()
.setAudioEnabled(true)
.setVideoEnabled(true)
.setFrontCameraAsDefault(true)
call.accept(AcceptParams().setCallOptions(options)) -
The call reaches onConnected. The caller sees a black video and hears nothing from the Android side.
-
Optional: call startVideo(), or hold() then unhold(true). No change.
Control: grant both permissions before step 2 and repeat. Audio and video work.
[Frequency]
100% reproducible whenever either permission is missing at the moment the call starts ringing.
[Current impact]
Users who haven’t granted camera and microphone before their first call can’t be seen or heard by their other side, even after granting the permissions on the call screen. Our workaround: ask for both permissions up front, before any call can arrive. If a call still rings without them, we answer voice-only (no camera) or decline and ask the caller to call back (no microphone). That means a lost or degraded first call for those users.