[css-houdini-drafts] [css-paint-api] Converting a URL to a CanvasImageSource?

asajeffrey has just created a new issue for https://github.com/w3c/css-houdini-drafts:

== [css-paint-api] Converting a URL to a CanvasImageSource? ==
`PaintRenderingContext2D` (https://drafts.css-houdini.org/css-paint-api/#2d-rendering-context) implements `CanvasDrawImage` (https://html.spec.whatwg.org/multipage/canvas.html#canvasdrawimage), which uses `CanvasImageSource` as the type of its `image` argument (https://html.spec.whatwg.org/multipage/canvas.html#canvasimagesource).

In examples such as https://github.com/w3c/web-platform-tests/blob/740aba06484bcb174c692175493fa591d29feedd/css-paint-api/paint2d-image.html#L20, the `image` is a URL. It is not obvious from the spec how this should be converted to a `CanvasImageSource`. In particular, paint worklets do not have access to the `HTMLImageElement` class, as it is not marked `Exposed=(Window,PaintWorklet)`.

Please view or discuss this issue at https://github.com/w3c/css-houdini-drafts/issues/416 using your GitHub account

Received on Tuesday, 20 June 2017 17:33:45 UTC