[Webkit-unassigned] [Bug 159340] Drawing an <img> with an SVG source into a <canvas> has incorrect rendering if the SVG viewBox does not match the <img> metrics

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Jul 1 08:58:14 PDT 2016


https://bugs.webkit.org/show_bug.cgi?id=159340

--- Comment #6 from Antoine Quint <graouts at webkit.org> ---
The Chromium bug is a WONTFIX as the behaviour is as spec'd, see discussion in https://bugs.chromium.org/p/chromium/issues/detail?id=625096. It looks like on WK2 we're doing the right thing, while on WK1 we're not, and not the other way around as previously thought.

Basically, when drawing an <img> which points to an SVG image in a <canvas>, the size of the <img> is irrelevant. If the <svg> element specifies width/height attributes, then those should be used as the source image size, otherwise the size should be computed based on the SVG image's aspect ratio based on the viewBox attribute and the size of the <canvas> image.

I'll do a pass through our tests to check that we're correctly implementing this.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20160701/a2e1fa81/attachment.html>


More information about the webkit-unassigned mailing list