[wpt-sync] Sync PR 21788 - [Image-Orientation] Fix canvas drawImage
Categories
(Core :: Graphics: Canvas2D, task, P4)
Tracking
()
Tracking | Status | |
---|---|---|
firefox75 | --- | fixed |
People
(Reporter: mozilla.org, Unassigned)
References
()
Details
(Whiteboard: [wptsync downstream])
Sync web-platform-tests PR 21788 into mozilla-central (this bug is closed when the sync is complete).
PR: https://github.com/web-platform-tests/wpt/pull/21788
Details from upstream follow.
Stephen Chenney <schenney@chromium.org> wrote:
[Image-Orientation] Fix canvas drawImage
Image orientation was not correctly applied in base_rendering_context_2d,
resulting in always oriented images sometimes drawn with the wrong source
rect. This change fixes that.The image-orientation setting we respect always comes from the canvas
into which the image is being drawn. This keeps the rules for which
orientation to apply simple.As part of this change, orientation is added to StaticBitmapImage and
used in the necessary cases to track the orientation of the source
image. Only non-texture-backed images will be drawn with the correct
orientation because image orientation is not supported by
directly composited images.As part of this change, the code to correct an image source rect is
moved to Image and callers updated.Bug: 1043790
Change-Id: I13d74b66cff912382f8f5efe0050eae6a0f283c0Reviewed-on: https://chromium-review.googlesource.com/2044050
WPT-Export-Revision: 5cb57bc5602de55c8dbc89e1c810b4db80ba7dcf
Assignee | ||
Updated•4 years ago
|
Assignee | ||
Updated•4 years ago
|
Assignee | ||
Updated•4 years ago
|
Assignee | ||
Comment 1•4 years ago
|
||
Pushed to try (stability) https://treeherder.mozilla.org/#/jobs?repo=try&revision=d3e6f4180221b9a116986a8a8b493b7b47a877e9
Assignee | ||
Comment 2•4 years ago
|
||
CI Results
Ran 13 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI
Total 8 tests
Status Summary
Firefox
PASS: 6
FAIL: 2
Chrome
PASS: 2
FAIL: 6
Safari
PASS: 3
FAIL: 5
Links
Gecko CI (Treeherder)
GitHub PR Head
GitHub PR Base
Details
New Tests That Don't Pass
/2dcontext/drawing-images-to-the-canvas/image-orientation/drawImage-from-element-swap-width-height.html: FAIL (Chrome: FAIL, Safari: PASS)
/2dcontext/drawing-images-to-the-canvas/image-orientation/drawImage-from-bitmap-swap-width-height.html: FAIL (Chrome: FAIL, Safari: FAIL)
Pushed by wptsync@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/5b625db07181 [wpt PR 21788] - [Image-Orientation] Fix canvas drawImage, a=testonly https://hg.mozilla.org/integration/autoland/rev/2157de86143f [wpt PR 21788] - Update wpt metadata, a=testonly
Comment 4•4 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/5b625db07181
https://hg.mozilla.org/mozilla-central/rev/2157de86143f
Description
•