Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Audio Issue on iPhone 14 with Agora SDK #342

Closed
adeelabbas opened this issue Mar 10, 2023 · 5 comments
Closed

Audio Issue on iPhone 14 with Agora SDK #342

adeelabbas opened this issue Mar 10, 2023 · 5 comments

Comments

@adeelabbas
Copy link

We are experiencing an audio issue on iPhone 14 when using Agora SDK with custom audio recording using AVCaptureSession and AVAssetWriter. There is no problem on iPhone 13 and older devices. Also interesting to note is that when an iPhone 14 device is the only device in the call, no error happens. The error happens when there is another device in the call sending audio to iPhone 14. We think that the problem happens when iPhone 14 speakerphone is open and at the same time as microphone from another AVCaptureSession is trying to capture samples.

Here is a link to a sample app and detailed steps to reproduce issue.

@plutoless
Copy link
Contributor

@adeelabbas we will take a look into your demo. have you changed anything or you are using the original demo?

@adeelabbas
Copy link
Author

I added code to use AVAssetWriter and AVAudioSession to write a local audio file

@plutoless
Copy link
Contributor

i would suggest you to stick to agora audio capture, and use onRecordedAudioFrame callback to process the audio recording file writing. If you are starting your own AVAudioSession, it would be easy to conflict with agora sdk.

@adeelabbas
Copy link
Author

Do you folks have a sample app that we can use to record local audio file using onRecordedAudioFrame callbacks?

@plutoless
Copy link
Contributor

@adeelabbas
if you only need to record local mic, you can refer to this demo
https://github.com/AgoraIO/API-Examples/blob/main/iOS/APIExample/APIExample/Examples/Advanced/RawMediaData/RawMediaData.swift

if you want to record all audios in the channel, you may look into this to learn to how process raw audio data.
https://github.com/AgoraIO/API-Examples/blob/main/iOS/APIExample/APIExample/Examples/Advanced/RawAudioData/RawAudioData.swift

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants