AVPlayerItemOutput Class Reference
| Inherits from | |
| Conforms to | |
| Framework | /System/Library/Frameworks/AVFoundation.framework |
| Availability | Available in iOS 6.0 and later. |
| Declared in | AVPlayerItemOutput.h |
Overview
The AVPlayerItemOutput class is an abstract class that defines the common interface for moving samples from an asset to an AVPlayer object. You do not create instances of this class directly but instead use one of the concrete subclasses that manage specific types of assets.
This class provides basic methods for converting time values to the timebase of the item. It also provides an option to suppress rendering of the output associated with the specific instance of this class.
Tasks
Converting Time Information
Configuring the Playback Options
-
suppressesPlayerRenderingproperty
Properties
suppressesPlayerRendering
A Boolean indicating whether the player object renders the receiver’s output.
Discussion
When the value of this property is NO (the default), the player object handles the rendering of the receiver’s associated output. You can change the value of this property to YES if you want to suppress the rendering of the media data associated with this object.
Availability
- Available in iOS 6.0 and later.
Declared In
AVPlayerItemOutput.hInstance Methods
itemTimeForHostTime:
Converts a host time (specified in seconds) to the item’s timebase.
Parameters
- hostTimeInSeconds
A host time value, specified in seconds. For example, you might specify the time value returned by the
CACurrentMediaTimefunction or the timestamp from aCADisplayLinkobject for this parameter.
Return Value
The equivalent time in the item’s timebase.
Discussion
The timestamp associated with a CADisplayLink object represents the time of the most recent screen refresh, which is usually a time in the past. If you want to find the time associated with the next screen refresh, you need to increment the timestamp by the value in the display link’s duration property.
Availability
- Available in iOS 6.0 and later.
Declared In
AVPlayerItemOutput.hitemTimeForMachAbsoluteTime:
Converts a Mach host time to the item’s timebase.
Parameters
- machAbsoluteTime
The Mach host time to convert. You typically retrieve this value using the
mach_absolute_timefunction.
Return Value
The equivalent time in the item’s timebase.
Availability
- Available in iOS 6.0 and later.
Declared In
AVPlayerItemOutput.h© 2012 Apple Inc. All Rights Reserved. (Last updated: 2012-09-19)