W3C home > Mailing lists > Public > whatwg@whatwg.org > November 2012

Re: [whatwg] Exposing framerate / statistics of <video> playback and related feedback

From: Ian Hickson <ian@hixie.ch>
Date: Thu, 29 Nov 2012 23:51:37 +0000 (UTC)
To: Charles Pritchard <chuck@jumis.com>
Message-ID: <Pine.LNX.4.64.1211292350270.9975@ps20323.dreamhostps.com>
Cc: whatwg <whatwg@whatwg.org>
On Tue, 1 May 2012, Charles Pritchard wrote:
> 
> The list looked at having a (canvas) ctx.stream = mediaElement; option 
> to better copy frames from a media stream into Canvas. I don't think 
> that the assignment operator will work, but it does seem like we could 
> optimize our drawImage calls to only happen when needed. At present, we 
> simply would run requestAnimationFrame. But, if a video stream is 
> operating on a slower frame rate than rAF, then the drawImage + rAF 
> method will be wasteful.
> 
> I've suggested an onframeready event; it seems as though that event 
> could also carry the number of dropped frames.

I haven't added this, because copying a video one frame at a time doesn't 
seem like an efficient way to do anything. Some sort of mechanism like 
what I had proposed for WebRTC (not sure if it's still in there) seems 
like a more solid solution, letting the browser do all the heavy lifting 
(potentially off the main thread).

-- 
Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'
Received on Friday, 30 November 2012 01:07:35 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 30 January 2013 18:48:11 GMT