InterstitialMarker

public class InterstitialMarker : TimelineMarker

Marks the time range of an interstitial for the asset when presented in the tvOS system UI. Only supported when StyleConfig.userInterfaceType = .system is used! An interstitial could be an advertisement, legal notice, or content warning. The time range defined by an InterstitialMarker is visually collapsed from the presentation, affecting rendered duration and playback time. The values returned by player.duration and player.currentTime remain unaffected.

  • Declaration

    Swift

    public var time: TimeInterval
  • Declaration

    Swift

    public var duration: TimeInterval
  • Whether linear playback should be enforced for the duration of this marker. Linear playback means that seeking and time-shifting is not allowed. If set to true, linear playback is automatically enforced for UI interactions when PlayerView is used with user interface type .system. Keep in mind that the Player API can still be directly used without any restrictions to seek or time-shift.

    Default value is false

    Declaration

    Swift

    public let requiresLinearPlayback: Bool
  • Declaration

    Swift

    public init(
        time: TimeInterval,
        duration: TimeInterval,
        requiresLinearPlayback: Bool = false
    )