[whatwg] getImageData/putImageData comments

Boris Zbarsky wrote:
> The other use case is doing createImageData, followed by filling in the 
> pixels, followed by putImageData.

I just saw the example in the spec that does just this, but bases the 
values it puts in on numbers it gets out of getImageData.  For that case 
you would of course want a blank imagedata that matches what 
getImageData hands out.

I still think that we need a better "I have some externally-derived 
pixel data I'd like to just stick in this canvas" API here.  fillRect() 
has terrible performance characteristics (as has been brought up many 
times before), and the current imagedata design makes it very difficult 
to use it correctly for this purpose...

-Boris

Received on Monday, 1 June 2009 07:00:49 UTC