W3C home > Mailing lists > Public > whatwg@whatwg.org > July 2013

[whatwg] Why can't ImageBitmap objects have width and height attributes?

From: Justin Novosad <junov@google.com>
Date: Mon, 15 Jul 2013 13:54:05 -0700
Message-ID: <CABpaAqSCYJra3zrMOTisoVQRLDmLwK0_rygpdrpcBkzP_aLjUA@mail.gmail.com>
To: WHAT Working Group <whatwg@whatwg.org>
Hi all,

We've recently started implementing ImageBitmap in Blink.  While writing
tests, we quickly realized that it is quite anoying that ImageBitmaps are
completely opaque objects.  When converting animation tests that used to
use image elements over to using ImageBitmaps, we're ending up having to
pass triplets (ImagBitmap, width, height) where we used to just have an
image.

It would be much more convenient if ImageBitmaps exposed their width and
height in pixels as read-only attributes.  I don't see any technical reason
why we couldn't do that.  Am I missing something?

Thanks,

    -Justin
Received on Monday, 15 July 2013 20:54:32 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 17:00:03 UTC