Open artemkrachulov opened 1 month ago
As a temporary solution, I have followed configuration after connection to the room:
Task {
let _ = try await roomContext.connect(url, token.token)
try await roomContext.setMicrophone(enabled: true)
if self.isVideo {
try await roomContext.setCamera(enabled: true)
} else {
// Switch audio back to Receiver
AudioManager.shared.isSpeakerOutputPreferred = false
}
}
But still, maybe we can avoid this unnecessary jumping from Receiver-Speaker-Receiver.
We're building an application where iOS Voip is combined with LiveKit. We have all configured modes, categories, and options for the AudioSession depending on the type of the call: video or audio. The issue comes when the user connects to the room:
When a new call is reported and CXProvider activates an audio session, AudioSession audio routes are configured correctly: Audio - Receiver Video - Speaker After connection to the room audio switches to the Speaker, but should stay Receiver as initially.
Do we have a default audio and mic configuration, where we can join the room with the required options? Example: Build-in Audio / Microphone On / Video off for video calls and Speaker Audio / Microphone On / Video on for video calls?
SDK Version 2.0.8
iOS/macOS Version Version 14.5 (23F79)