iOS Developer Library

Developer

AV Foundation Framework Reference AVAssetTrackGroup Class Reference

Options
Deployment Target:

On This Page
Language:

AVAssetTrackGroup

The AVAssetTrackGroup class encapsulates a single group of related tracks in an asset.

Instances of AVAssetTrackGroup describe a single group of related alternate tracks, only one of which should be played at a time. Groups of alternate tracks typically contain variations of the same content, such as subtitles in multiple translations.

Clients can inspect the track groups contained in an asset (AVAsset) instance by loading and obtaining the value of the asset’s trackGroups property.

  • The IDs of the tracks in the group. (read-only)

    Declaration

    Swift

    var trackIDs: [NSNumber] { get }

    Objective-C

    @property(nonatomic, readonly) NSArray <NSNumber *> *trackIDs

    Discussion

    The value of this property is an array of NSNumber instances that are interpreted as CMPersistentTrackID values, one for each track in the group.

    Availability

    Available in iOS 7.0 and later.