Mute/Unmute Button for IMA preroll ads

347 views
Skip to first unread message

Bhavya Bharti

unread,
Sep 13, 2019, 6:25:08 AM9/13/19
to Interactive Media Ads SDK
Hi Team,

I am using IMA SDK for my iPhone app. I was using adWillPlayMuted to mute preroll ads but was not working. Then I switched to setVolume(0) method and it worked like charm to mute the preroll ads.

Now, my requirement is I want to give flexibility to my app users to mute/unmute the preroll ad as per his need/wish. Is there any way provided by IMA SDK to do this?
I couldn't find any document to display mute button, same way as in AVPlayer. I don't want to add custom button in my code. Please help.

Thanks and Regards,
Bhavya Bharti

IMA SDK

unread,
Sep 13, 2019, 3:13:36 PM9/13/19
to bha...@whizti.com, ima...@googlegroups.com
Hi Bhavya,

Thank you for reaching out to us. The adWillPlayMuted specifies whether the player intends to start the content and ad with no volume. Changing this setting will have no impact on ad playback (It doesn't mute the ad). The volume field of the AdsManager class is a getter and setter field that can use to change your ad volume value, to give the user the possibility to unmute the ad, you have to implement a button which when tapped would call the volume field on the AdsManager class with a value of 1.

Regards,
Arnaud Casame
IMA SDK Team

ref:_00D1U1174p._5001UHGgdB:ref
Reply all
Reply to author
Forward
0 new messages