Skip to main content

AVAudioSession Issue iOS

XCode: All versions | Appodeal SDK: All versions


If you use video or audio sessions in your app (usually for music players), you may encounter a problem with incorrect audio playback when loading an AdMob ad.

To solve this problem, add the following method to your AppDelegate:

import GoogleMobileAds

final class AppDelegate ... {
func application(
_ application: UIApplication,
didFinishLaunchingWithOptions launchOptions:[UIApplication.LaunchOptionsKey: Any]?
) -> Bool {
GADMobileAds.sharedInstance().audioVideoManager.audioSessionIsApplicationManaged = true
return true
}
}

You can find more information here.