iOS Developer Library

Developer

AVFoundation Framework Reference AVPlayerItemOutputPullDelegate Protocol Reference

Options
Deployment Target:

On This Page
Language:

AVPlayerItemOutputPullDelegate

Inherits From


Not Applicable

Import Statement


Swift

import AVFoundation

Objective-C

@import AVFoundation;

Availability


Available in iOS 6.0 and later

The AVPlayerItemOutputPullDelegate protocol defines the methods that are called by an AVPlayerItemVideoOutput object in response to pixel buffer changes.

  • Tells the delegate that new samples are about to arrive.

    Declaration

    Swift

    optional func outputMediaDataWillChange(_ sender: AVPlayerItemOutput!)

    Objective-C

    - (void)outputMediaDataWillChange:(AVPlayerItemOutput *)sender

    Parameters

    sender

    The output object that sent the message.

    Discussion

    You can use this method to prepare for any new sample data. This method is called at some point after a call to your video output object’s requestNotificationOfMediaDataChangeWithAdvanceInterval: method.

    Import Statement

    Objective-C

    @import AVFoundation;

    Swift

    import AVFoundation

    Availability

    Available in iOS 6.0 and later

  • Tells the delegate that a new sample sequence is commencing.

    Declaration

    Swift

    optional func outputSequenceWasFlushed(_ output: AVPlayerItemOutput!)

    Objective-C

    - (void)outputSequenceWasFlushed:(AVPlayerItemOutput *)output

    Parameters

    output

    The output object that sent the message.

    Discussion

    This method is called after any attempt to seek or change the playback direction of the item’s content. If you are maintaining any queued future samples, you can use your implementation of this method to discard those samples.

    Import Statement

    Objective-C

    @import AVFoundation;

    Swift

    import AVFoundation

    Availability

    Available in iOS 6.0 and later