W3C home > Mailing lists > Public > whatwg@whatwg.org > February 2010

[whatwg] Offscreen canvas (or canvas for web workers).

From: Maciej Stachowiak <mjs@apple.com>
Date: Tue, 23 Feb 2010 21:57:34 -0800
Message-ID: <1F24538C-4F1C-456D-B2FB-AD0433F88A7C@apple.com>

On Feb 23, 2010, at 7:40 AM, Jeremy Orlow wrote:

>
> Note that doing rendering in a worker and then displaying it on the  
> the main thread also gives you double buffering for no additional  
> cost.  This is something our teams are excited about as well.

While I think the use cases presented for background thread image  
manipulation are valid, I'm confused about this claim:

(A) <canvas> implementations do double-buffering anyway, to avoid  
drawing intermediate states in the middle of JS execution.
(B) If you want triple-buffering (maybe you want to use multiple event  
loop cycles to draw the next frame), you don't need a Worker to do it.  
You can


BTW some examples of shipping pixels being much less shipping drawing  
commands:

- Raytracing a complex scene at high resolution.
- Drawing a highly zoomed in high resolution portion of the Mandelbrot  
set.

To be fair though, you could compute the pixels for those with just  
math, there is no need to have a graphics context type abstraction.

Regards,
Maciej
Received on Tuesday, 23 February 2010 21:57:34 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 16:59:21 UTC