AI-generated Key Takeaways
-
IMAAVPlayerVideoDisplayDelegate is a callback protocol.
-
The
playerVideoDisplay:willLoadStreamAsset:method is called when a stream is about to be loaded for playback, allowing for registration of AVURLAsset for Fairplay content protection. -
The
playerVideoDisplay:didLoadPlayerItem:method is called when the player item is at least partially loaded, specifically for dynamic ad insertion.
IMAAVPlayerVideoDisplayDelegate
@protocol IMAAVPlayerVideoDisplayDelegate <NSObject>A callback protocol for IMAAVPlayerVideoDisplayDelegate.
-
Called when the IMAAVPlayerVideoDisplay will load a stream for playback. Allows the publisher to register the AVURLAsset for Fairplay content protection before playback starts.
Declaration
Swift
optional func playerVideoDisplay(_ playerVideoDisplay: IMAAVPlayerVideoDisplay, willLoadStreamAsset URLAsset: AVURLAsset)Objective-C
- (void)playerVideoDisplay:(nonnull IMAAVPlayerVideoDisplay *)playerVideoDisplay willLoadStreamAsset:(nonnull AVURLAsset *)URLAsset;Parameters
playerVideoDisplaythe IMAVPlayerVideoDisplay that will load the AVURLAsset.
URLAssetthe AVURLAsset representing the stream to be loaded.
-
Called when the
IMAAVPlayerVideoDisplayhas at least partially loaded media for playback and the player item is loaded. Only called for dynamic ad insertion.Declaration
Swift
optional func playerVideoDisplay(_ playerVideoDisplay: IMAAVPlayerVideoDisplay, didLoad playerItem: AVPlayerItem)Objective-C
- (void)playerVideoDisplay:(nonnull IMAAVPlayerVideoDisplay *)playerVideoDisplay didLoadPlayerItem:(nonnull AVPlayerItem *)playerItem;