Contents

playbackCoordinator(_:interstitialTimeRangesFor:)

Asks the delegate for time ranges in a player item that don’t correspond to the primary content.

Declaration

optional func playbackCoordinator(_ coordinator: AVPlayerPlaybackCoordinator, interstitialTimeRangesFor playerItem: AVPlayerItem) -> [NSValue]

Parameters

  • coordinator:

    The object coordinating playback.

  • playerItem:

    The player item for which to retrieve interstitial time ranges.

Return Value

An array of NSValue objects that contain the interstitial time ranges.

Discussion

Implementing this method enables the coordinator to synchronize playback between participants that have different interstitials stitched into the primary content timeline.

If you don’t implement this method, the coordinator assumes that the entire item corresponds to the primary content.