WebVTT Observations


The WebVTT Draft Spec has been updated to allow metadata headers. This corrects all the issues outlined in this post. :)

According to the WebVTT Draft Spec, a WebVTT file must start with the string “WEBVTT” followed by some text that does not include a line break, followed by two line breaks. This pretty much kills the idea of including header metadata. Yet, WebVTT files produced by YouTube break this rule and include some extra data in the header (along with line breaks), breaking the spec.

Kind: captions
Language: en

It would be nice if the spec allowed for metadata to be added like this. It would be nice if the spec allowed for something like RDF or microdata, but I understand that one of the beauties of WebVTT is its low markup to content ratio.

Additionally, it would be nice to have support for a GUID, or even an alternative content link to the webpage where this WebVTT file is embedded, or even a link directly to the video file this WebVTT file belongs with. This way, if the WebVTT file is orphaned, one can make a reasonable guess about what it is and where it belongs without the contextual data from the parent HTML document.

It would be nice to have a semantic way to markup sounds, or even who is speaking. Currently, we can use voice tags, but that only seems to get us part of the way there. Note: I’m thinking about this mostly from a “Search Engines Indexing Captions” perspective.

On that note, when will we be able to include WebVTT files in Video Sitemaps?

Why doesn’t the HTML <track> element support the type attribute, like the <source> element? What happens when we discover the thing that is way better than WebVTT? This seems like a step in the wrong direction.

WebVTT files must be UTF-8. The Content-Type must be text/vtt, and specifies no required or optional parameters. Why, then, are so many WebVTT files being served with the Content-Type text/vtt; charset=utf-8?

If WebVTT cue identifiers can contain spaces, how would we reference these IDs in CSS?

The folks at WebVTT contacted me on Twitter regarding metadata at the begining of the file.

I believe the bug referred to is Bug 15851.


Now read this

A Photo is NOT Worth a Thousand Words

Metadata in Photos tl;dr: We are just scratching the surface of capturing the metadata surrounding a photo. Photos have never really stood well on their own. In order to see the whole picture, some context is often necessary. This is... Continue →