javascript - showTextTrack in Video.js 5 -
i trying change active caption track javascript in video.js v5.10.4. saw few posts , suggested use showtexttrack
, when execute command says showtexttrack not function
. have following code
var video = videojs('video'); var first_track_id = video.texttracks().tracks_[0].id; // returns vjs_track_399 video.showtexttrack(first_track_id, "captions"); // returns error above
is there other way accomplish trying do, or doing wrong?
showtexttracks()
video.js 4. set mode of track showing
:
video.texttracks()[0].mode = 'showing';
Comments
Post a Comment