Just as audio and video may need transcoding for the web, subtitles and captions may also need to be converted and made available.
Getting subtitles and captions
If you have existing subtitle or caption files, you may need to convert them. Original assets may contain broadcast captions. You can also create captions using tools, some of which can convert Flash captions and subtitles for you. Regardless of how you get them, most web use cases require captions in the WebVTT format.
Captioning tools:
Playing them back on the web
If you're not using a custom player capable of playing other caption subtitle formats, then you will be using WebVTT. There are two methods for using these files on the web.
- Muxing
- Use your video editing tool to incorporate the caption as an additional stream in your video containers. Although this method ensures that the captions will always be available to the viewer this will make your video files larger, and less flexible than using
<track>
(see below). - The <track> element
- The
<track>
element can be included as a child of the video element, which will load your WebVTT file separately and allow you to display it when needed, alter the positioning and styling of each track, etc.