Instance Property

timeRange

The time range to read from the asset.

Declaration

var timeRange: CMTimeRange { get set }

Discussion

The intersection of the value of this property and CMTimeRangeMake(kCMTimeZero, asset.duration) determines the time range of the asset for reading media data.

The default value is CMTimeRangeMake(kCMTimeZero, kCMTimePositiveInfinity). You cannot change the value of this property after starting reading.

See Also

Controlling Reading

var status: AVAssetReader.Status

The status of the reading of sample buffers from the asset.

enum AVAssetReader.Status

The statuses for a reader.

func startReading() -> Bool

Prepares the receiver for obtaining sample buffers from the asset.

func cancelReading()

Cancels any background work and prevents the receiver’s outputs from reading more samples.

var error: Error?

Describes the error that occurred.

Beta Software

This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.

Learn more about using Apple's beta software