Hi,
https://github.com/googleads/googleads-ima-ios/tree/master/Objective-C/AdvancedExample
What I noted:
Airplay works fine with the supplied implementation, which uses the AVPlayer instance to initialize the IMAAdsRequest:
IMAAdsRequest *request = [[IMAAdsRequest alloc] initWithAdTagUrl:adTagUrl
adDisplayContainer:[self createAdDisplayContainer]
avPlayerVideoDisplay:[[IMAAVPlayerVideoDisplay alloc] initWithAVPlayer:self.contentPlayer]
pictureInPictureProxy:self.pictureInPictureProxy
userContext:nil];
But if you initialize the request with a playhead instead (which should be totally valid), it stops working:
IMAAdsRequest *request = [[IMAAdsRequest alloc] initWithAdTagUrl:adTagUrl
adDisplayContainer:[self createAdDisplayContainer]
contentPlayhead: self.contentPlayhead
userContext:nil];
While connected to Airplay, the video is stuck in the preroll phase. The content is not played after the preroll.
[Steps to reproduce]:
1 - Change the IMAAdsRequest initialization code to use the content playhead
2 - Compile the project for a device and launch
3 - Launch the “preroll” example in the list
4 - During the preroll, connect to Airplay to be ready to cast the video
5 - Watch the preroll finish on the TV
6 - Notice that the content doesn’t start, the seek bar resets at the beginning of the preroll video
Expected:
The content should start as soon as the preroll finishes.
Let me know if you need any more information!
|
||||||