Represents a media track (audio or video) of a media resource.

interface MediaTrack {
    activeQuality: undefined | Quality;
    enabled: boolean;
    id: string;
    kind: MediaTrackKind;
    label: string;
    language: string;
    qualities: Quality[];
    uid: number;
}

Hierarchy (view full)

Properties

activeQuality: undefined | Quality

The active quality of the media track, i.e. the quality that is currently being played.

enabled: boolean

Marks the track to be the selected track for playout

id: string

The identifier of the media track.

Remarks


- This identifier can be used to distinguish between related tracks, e.g. tracks in the same list.

The kind of the media track, represented by a value from the following list:
- 'main': The track is the default track for playback
- 'alternative': The track is not the default track for playback

label: string

The label of the media track.

language: string

The language of the media track.

qualities: Quality[]

The qualities of the media track.

uid: number

A unique identifier of the media track.

Remarks


- This identifier is unique across tracks of a THEOplayer instance and can be used to distinguish between tracks.
- This identifier is a randomly generated number.