videojs / video.js

Video.js - open source HTML5 video player
https://videojs.com
Other
38.1k stars 7.45k forks source link

Hiding subtitles #2830

Closed osanwe closed 8 years ago

osanwe commented 8 years ago

Hello!

I've added several subtitles to a video with tracks option and had a switcher on the control bar. It's good. But I want show all subtitles near to player, not over the video, like on edx. Therefore I read a subtitles file and show its content. It isn't a problem. But how can I hide subtitles on the video? Now I use .srt file instead of .vtt, but I think it isn't a right way.

Thanks in advance!

gkatsev commented 8 years ago

The best way to not display the subtitles, is to just remove them from the player. However, you can also change the track's mode from showing to hidden if you want them to still fire cuechange events but not actually be visible to the viewer. Hope that helps.