[whatwg] I believe source rectangles for HTML5 Canvas drawImage are specified incorrectly
cabanier at gmail.com
Tue Dec 18 20:39:11 PST 2012
On Tue, Dec 18, 2012 at 1:14 PM, Robert O'Callahan <robert at ocallahan.org>wrote:
> On Wed, Dec 19, 2012 at 4:17 AM, Kevin Gadd <kevin.gadd at gmail.com> wrote:
>> Sorry, upon reading over the ImageBitmap part of the spec again I'm
>> confused: Why is constructing an ImageBitmap asynchronous? I thought
>> any decoding isn't supposed to happen until drawImage, so I don't
>> really understand why this operation involves a callback and a delay.
>> Making ImageBitmap creation async means that you *cannot* use this as
>> a replacement for drawImage source rectangles unless you know all
>> possible source rectangles in advance. This is not possible for many,
>> many use cases (scrolling through a bitmap would be one trivial
> I think this is a real problem.
> It seems to me a synchronous constructor that creates an ImageBitmap for a
> subimage of another ImageBitmap (but not other kind of source!) will be
Did you mean to say a synchronous constructor?
Reading the new spec (
http://www.whatwg.org/specs/web-apps/current-work/#imagebitmap), I still
fail to see how this is better than a drawimage with dx=dy=0 and
More information about the whatwg