Re: [sdw] WebVMT: Investigate better out-of-band link handling (#1107)

> In the WebVMT case, my working assumption is that the main starting point is either the HTML page (HTML -> media, VMT) or the media file (media -> VMT). Use cases that start from the VMT file seem less likely to me. That may be where we have different perspectives.

I agree that the HTML is a starting point (`HTML -> media, VMT`), and that is an important use case.

I disagree that the media file is a starting point, as it is contains no reference to the VMT file.  Perhaps I've misunderstood. Do you mean 'starting point' for DOM parsing, or something else?

The VMT file would be pretty meaningless without the linked media (`VMT -> media`), though technically it could just run on a timer in isolation. However, there are HTML use cases where this information is essential - see Playlist Use Case below.

> Sure, that's typically the kind of information that you get on the developer console when you browse a page. However, that information is always restricted to resources that the browser needs to fetch to render the page. If it already has the URL of the media file and of the WebVMT file, the WebVMT engine does not need to fetch the link between the VMT file and the media file to render things. That would take extra time, CPU and network usage. So I wouldn't expect it to report on it being broken.

If the media URL is in the HTML file, I agree that there is no need for the WebVMT engine to fetch the resource (and it doesn't). However, the media URL may not be in the HTML, which comes back to the question of 'where is it recorded?' - see Playlist Use Case below.

> The analogy does not work at 100% because there may be 3 resources at play in your case (HTML, media, VMT). In the webpage-image analogy, the main starting point for most use cases is the HTML page, so link is `HTML -> image`.

In the case you describe, `HTML -> media & VMT` and also `VMT -> media`. There's some duplication in this case, but I don't think it's bidirectional.

> In the demo you link to, I wouldn't expect users to point the player at the VMT file directly, in the same way as I wouldn't expect users to point a video player at a subtitles file directly (that is, it may work, but I wouldn't expect the video to appear as if by magic).

In the [mobile demo](http://webvmt.org/demos#mobile), the user must load both files: media and VMT. Just loading one file doesn't magically make the other appear, but sufficient information is required to allow the browser to make the correct association between them. In this case, there is no information in the HTML as the files are loaded afterwards by the user via an HTML input element, as you can see from this HTML excerpt:
```
<input id="vmt-load" multiple type="file" accept="video/*,video/mp4,.vmt">
<video id="vmt-video" controls src="">
   <track kind="metadata" map-id="vmt-map" tile-url="https://{s}.tile.openstreetmap.com/{z}/{x}/{y}.png?apikey=MY_KEY" />
</video>
```
The Playlist Use Case below explores this in more detail.

-- 
GitHub Notification of comment by rjksmith
Please view or discuss this issue at https://github.com/w3c/sdw/issues/1107#issuecomment-452765871 using your GitHub account

Received on Wednesday, 9 January 2019 16:45:59 UTC