[whatwg] <video preload> implementation feedback

Ian Hickson ian at hixie.ch
Fri Jun 15 09:01:09 PDT 2012


On Fri, 15 Jun 2012, Simon Pieters wrote:
> On Thu, 14 Jun 2012 20:32:16 +0200, Ian Hickson <ian at hixie.ch> wrote:
> > On Thu, 14 Jun 2012, Simon Pieters wrote:
> > > 
> > > It's not more. But it still is. Even though images aren't required 
> > > to load at all, you still recently changed the way they load to be 
> > > compatible (http://html5.org/r/7128 ). We should also specify how 
> > > videos load to be compatible. We can do it now and get everyone to 
> > > align on a good behavior, or we can wait and do it in a few years 
> > > when Web content relies on what the market leader does, whether 
> > > that's good or bad behavior.
> > 
> > I don't understand what behaviour it is that you think we should 
> > define.
> 
> When preload=none, step 2 of 
> http://www.whatwg.org/specs/web-apps/current-work/multipage/the-video-element.html#concept-media-load-resource 
> should not be optional.
> 
> The effective (internal) preload state should be defined.
> 
> It should also be defined that with preload=metadata, readyState should 
> never go beyond HAVE_CURRENT_DATA, even for a data: URL or otherwise 
> fully cached resource.

Making it non-conforming for a user agent to aggressively cache resources, 
especially if the user has asked for it, is a non-starter. There are going 
to be cases where that's what the user wants, and I don't see why we would 
have to make this non-conforming.


> > As far as I can tell, the spec is as detailed as it can be here given 
> > the range of possible implementation strategies that we need to allow.
> > 
> > Could you give a concrete example of what you are concerned about?
> 
> <video src=x preload=none onsuspend="makeSiteWork()"></video>

Then we should stop firing "suspend" in the preload=none case, or fire it 
in every case if preload=non, even if the UA immediately unsuspends.

But I'm not convinced anyone is going to hook into onsuspend in this way. 
There'd be no point as far as I can tell, and it's more complicated than 
the alternative (just run the code straight away without waiting).

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'



More information about the whatwg mailing list