Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-30-2023
08:11 AM
- last edited on
07-31-2023
01:42 PM
by
Shahzad_Ismail
Hi guys,
I'm implementing the SDK based on the VideoCallKitSwift swift sample.
SDK 5.23.5 dynamic, iOS 16.5.1.
Not sure if it's related, but the hosting app is in SwiftUI.
Everything looks good so far, the only problem I have is the startPlayingSoundFile function.
It's not failing, and in the log I see the line:
[audio-controller] Successfully played audio file at path '/private/var/containers/Bundle/Application/579036B2-938F-4708-8EF9-6BADD83546A4/test.app/ringback.wav'
The audio file I took from the sample folder.
Sometimes only when I stop in debugger I can hear the ring for a short while, but then it stops.
Any ideas?
Here is the code.
do {
try AppDelegate.callKitMediator.client?.audioController.startPlayingSoundFile(withPath: Bundle.main.path(forResource: "ringback", ofType: "wav"), looping: true)
} catch {
os_log("WARNING: path for resource %{public}@ not found in the main bundle", log: self.customLog, type: .error, "ringback.wav")
}
I'm implementing the SDK based on the VideoCallKitSwift swift sample.
SDK 5.23.5 dynamic, iOS 16.5.1.
Not sure if it's related, but the hosting app is in SwiftUI.
Everything looks good so far, the only problem I have is the startPlayingSoundFile function.
It's not failing, and in the log I see the line:
[audio-controller] Successfully played audio file at path '/private/var/containers/Bundle/Application/579036B2-938F-4708-8EF9-6BADD83546A4/test.app/ringback.wav'
The audio file I took from the sample folder.
Sometimes only when I stop in debugger I can hear the ring for a short while, but then it stops.
Any ideas?
Here is the code.
do {
try AppDelegate.callKitMediator.client?.audioController.startPlayingSoundFile(withPath: Bundle.main.path(forResource: "ringback", ofType: "wav"), looping: true)
} catch {
os_log("WARNING: path for resource %{public}@ not found in the main bundle", log: self.customLog, type: .error, "ringback.wav")
}
Solved! Go to Solution.
Labels:
- Labels:
-
Voice
10 REPLIES 10
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-04-2024 04:41 AM
Thank you, it works successfully, but the sound is coming through the phone. If I want it to play directly through the speaker, how can I do that?

- « Previous
-
- 1
- 2
- Next »