Vlastnost HTML Audio/Video DOM textTracks
❮ HTML Audio/Video DOM Reference
Příklad
Získejte počet dostupných textových stop:
var vid = document.getElementById("myVideo");
alert(vid.textTracks.length);
Definice a použití
Vlastnost textTracks vrací objekt TextTrackList.
Objekt TextTrackList představuje dostupné textové stopy pro audio/video.
Každá dostupná textová stopa je reprezentována objektem TextTrack.
Podpora prohlížeče
Čísla v tabulce určují první verzi prohlížeče, která plně podporuje vlastnost.
Property | |||||
---|---|---|---|---|---|
textTracks | Yes | 10.0 | 33.0 | 6.0 | Yes |
Syntax
audio|video.textTracks
Návratová hodnota
Type | Description |
---|---|
TextTrackList Object | Represents the available text tracks for the the audio/video. TextioTrackList Object:
Note: The first available TextTrack object is index 0 |
TextTrack Object | Represents an text track. TextTrack Object Properties:
|
❮ HTML Audio/Video DOM Reference