W3C home > Mailing lists > Public > public-webapps@w3.org > April to June 2015

Re: Async Image -> ImageData conversion

From: Boris Zbarsky <bzbarsky@mit.edu>
Date: Fri, 26 Jun 2015 08:37:30 -0700
Message-ID: <558D71BA.4090805@mit.edu>
To: Ashley Gullen <ashley@scirra.com>
CC: "public-webapps@w3.org" <public-webapps@w3.org>, Jeff Muizelaar <jrmuizel@mozilla.com>
On 6/26/15 4:07 AM, Ashley Gullen wrote:
> I don't think we should extend HTMLImageElement because it is not
> available in workers. Adding the conversion methods to ImageBitmap
> allows workers to perform conversions using Blob (compressed image data)
> in the place of HTMLImageElement.

Maybe I wasn't clear.  I was suggesting that we have the methods on both 
HTMLImageElement and ImageBitmap (and possibly on any other things we 
feel should have the methods directly).

> I like the suggestion that "ImageBitmap be the hub of image conversion",

I agree that it sounds appealing, but it means ImageBitmap now has to 
serve two masters: it has to be something that you can paint from 
quickly (premultiplied, probably lives on the GPU) _and_ it needs to be 
something you can transferToImageData efficiently (better to not live on 
the GPU for this).

Maybe that's OK; it's just a bit of a warning flag from my point of view 
when a single object is meant to do multiple quite different things; it 
makes it harder to have it be good at all of them...

-Boris
Received on Friday, 26 June 2015 15:38:08 UTC

This archive was generated by hypermail 2.3.1 : Friday, 27 October 2017 07:27:32 UTC