Closed Bug 1793031 Opened 3 years ago Closed 3 years ago

[wpt-sync] Sync PR 35708 - [CompositeClipPathAnimations] Fix crash caused by position: fixed.

Categories

(Core :: Web Painting, task, P4)

task

Tracking

()

RESOLVED FIXED
107 Branch
Tracking Status
firefox107 --- fixed

People

(Reporter: wpt-sync, Unassigned)

References

()

Details

(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 35708 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/35708
Details from upstream follow.

Claire Chambers <clchambers@microsoft.com> wrote:

[CompositeClipPathAnimations] Fix crash caused by position: fixed.

With a translation of 0,0, a DCHECK in
DrawingDisplayItem::CalculateRectKnownToBeOpaqueForRecord would fail, as
the 'image size' for a deferred image is set by a parameter in the paint
worklet input, which in this case was the reference box. This would
fail the DCHECK when the clip path was larger than the reference box.

An extra parameter has been added to the clip path paint worklet input
so that the reference box is independent from the size of the clip area.

The area painted when producing the deferred image has also been
translated so that its origin is 0,0. This is also necessary to avoid the
DCHECK.

More about this change: https://docs.google.com/document/d/1gYI6G6ylpxKX0N1L23KPnaKsNOvNMaE-vM3l6RIroqU/edit

Note that the test for a version of this crash caused by a rounding error is also affected by another issue (1249071), so currently this test only guards against a crash and not visually incorrect clip paths. This will be resolved in a future CL.

This change also sets up a future change that resolves https://bugs.chromium.org/p/chromium/issues/detail?id=1248610

Bug: 1353038, 1249071
Change-Id: I1d62a00a92f38e06e2ae090caefced5fdf289fd9
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3866054
Reviewed-by: Robert Flack \<flackr@chromium.org>
Commit-Queue: Claire Chambers \<clchambers@microsoft.com>
Reviewed-by: Xianzhu Wang \<wangxianzhu@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1052298}

Component: web-platform-tests → Web Painting
Product: Testing → Core

CI Results

Ran 9 Firefox configurations based on mozilla-central, and Firefox, Chrome, and Safari on GitHub CI

Total 2 tests

Status Summary

Firefox

PASS: 2

Chrome

PASS: 2

Safari

PASS: 2

Links

Gecko CI (Treeherder)
GitHub PR Head
GitHub PR Base

Severity: -- → N/A
Pushed by wptsync@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/e5b7577741b6 [wpt PR 35708] - [CompositeClipPathAnimations] Fix crash caused by position: fixed., a=testonly
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 107 Branch
You need to log in before you can comment on or make changes to this bug.