Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(112)

Issue 1459953002: Fix the reference box computation for CSS filter effects. (Closed)

Created:
5 years, 1 month ago by Stephen White
Modified:
5 years, 1 month ago
Reviewers:
chrishtr
CC:
blink-reviews, blink-reviews-layout_chromium.org, blink-reviews-paint_chromium.org, chromium-reviews, dshwang, krit, eae+blinkwatch, f(malita), fs, gyuyoung2, jchaffraix+rendering, kouhei+svg_chromium.org, leviw+renderwatch, pdr+svgwatchlist_chromium.org, pdr+renderingwatchlist_chromium.org, rwlbuis, Stephen Chennney, slimming-paint-reviews_chromium.org, szager+layoutwatch_chromium.org, zoltan1
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Fix the reference box computation for CSS filter effects. Previously, we had been using the element's border bounding box, but this does not take transforms applied to child elements into account. The fix is to use PaintLayer::physicalBoundingBoxIncludingReflectionAndStackingChildren. In order to prevent calling this method at the wrong time in the document lifecycle, this patch defers creation of the FilterEffectBuilder until after style computation. BUG=554169 Committed: https://crrev.com/97aae274311bc2da4388dedf9c25e26692ff1f98 Cr-Commit-Position: refs/heads/master@{#360692}

Patch Set 1 #

Patch Set 2 : Centralize the hack #

Patch Set 3 : Restore const-correctness (inspired by fs's patch) #

Patch Set 4 : Fix assert; add comment #

Patch Set 5 : Fix another comment #

Total comments: 5

Patch Set 6 : Rename filterEffectBuilder(); privatize it; remove document lifecycle assert (for now) #

Patch Set 7 : Remove ComputedStyle::filterOutsets() and its last caller. #

Total comments: 2

Patch Set 8 : Add TODO per review #

Unified diffs Side-by-side diffs Delta from patch set Stats (+117 lines, -29 lines) Patch
A third_party/WebKit/LayoutTests/css3/filters/filter-region-transformed-child.html View 1 chunk +27 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/css3/filters/filter-region-transformed-child-expected.html View 1 chunk +25 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/layout/LayoutBox.cpp View 1 2 1 chunk +2 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/core/layout/svg/ReferenceFilterBuilder.cpp View 2 chunks +5 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/core/paint/FilterPainter.cpp View 1 2 3 4 5 1 chunk +5 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/core/paint/PaintLayer.h View 1 2 3 4 5 2 chunks +5 lines, -7 lines 0 comments Download
M third_party/WebKit/Source/core/paint/PaintLayer.cpp View 1 2 3 4 5 6 7 6 chunks +48 lines, -14 lines 0 comments Download
M third_party/WebKit/Source/core/style/ComputedStyle.h View 1 2 3 4 5 6 1 chunk +0 lines, -2 lines 0 comments Download

Messages

Total messages: 27 (10 generated)
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1459953002/1 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1459953002/1
5 years, 1 month ago (2015-11-19 16:14:41 UTC) #2
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1459953002/20001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1459953002/20001
5 years, 1 month ago (2015-11-19 16:42:40 UTC) #4
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: linux_android_rel_ng on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_android_rel_ng/builds/98392)
5 years, 1 month ago (2015-11-19 17:01:45 UTC) #6
chrishtr
This approach looks generally fine, modulo code cleanup. I checked, and it all of the ...
5 years, 1 month ago (2015-11-19 17:20:43 UTC) #8
Stephen White
On 2015/11/19 17:20:43, chrishtr wrote: > This approach looks generally fine, modulo code cleanup. The ...
5 years, 1 month ago (2015-11-19 19:02:53 UTC) #9
chrishtr
https://codereview.chromium.org/1459953002/diff/80001/third_party/WebKit/Source/core/paint/PaintLayer.cpp File third_party/WebKit/Source/core/paint/PaintLayer.cpp (right): https://codereview.chromium.org/1459953002/diff/80001/third_party/WebKit/Source/core/paint/PaintLayer.cpp#newcode2629 third_party/WebKit/Source/core/paint/PaintLayer.cpp:2629: filterEffectBuilder(); The naming is weird here. ensureFilterEffectBuilder()? https://codereview.chromium.org/1459953002/diff/80001/third_party/WebKit/Source/core/paint/PaintLayer.h File ...
5 years, 1 month ago (2015-11-19 19:12:05 UTC) #10
Stephen White
https://codereview.chromium.org/1459953002/diff/80001/third_party/WebKit/Source/core/paint/PaintLayer.cpp File third_party/WebKit/Source/core/paint/PaintLayer.cpp (right): https://codereview.chromium.org/1459953002/diff/80001/third_party/WebKit/Source/core/paint/PaintLayer.cpp#newcode2601 third_party/WebKit/Source/core/paint/PaintLayer.cpp:2601: ASSERT(layoutObject()->document().lifecycle().state() >= DocumentLifecycle::CompositingClean); Problem: this assert seems to be ...
5 years, 1 month ago (2015-11-19 19:34:51 UTC) #11
Stephen White
Had to remove the document lifecycle assert for now. Let me know if there's a ...
5 years, 1 month ago (2015-11-19 19:53:28 UTC) #12
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1459953002/110001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1459953002/110001
5 years, 1 month ago (2015-11-19 20:08:30 UTC) #14
chrishtr
Sad times, the compositing overlap test depends on compositing state. Forgot about that bad bad ...
5 years, 1 month ago (2015-11-19 21:02:27 UTC) #16
chrishtr
lgtm Looks good modulo the requested documentation & comments.
5 years, 1 month ago (2015-11-19 21:02:45 UTC) #17
Stephen White
https://codereview.chromium.org/1459953002/diff/110001/third_party/WebKit/Source/core/paint/PaintLayer.cpp File third_party/WebKit/Source/core/paint/PaintLayer.cpp (right): https://codereview.chromium.org/1459953002/diff/110001/third_party/WebKit/Source/core/paint/PaintLayer.cpp#newcode2601 third_party/WebKit/Source/core/paint/PaintLayer.cpp:2601: if (!paintsWithFilters()) On 2015/11/19 21:02:27, chrishtr wrote: > Add ...
5 years, 1 month ago (2015-11-19 21:06:31 UTC) #18
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1459953002/130001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1459953002/130001
5 years, 1 month ago (2015-11-19 21:09:45 UTC) #21
commit-bot: I haz the power
Try jobs failed on following builders: ios_dbg_simulator_ninja on tryserver.chromium.mac (JOB_TIMED_OUT, no build URL) ios_rel_device_ninja on ...
5 years, 1 month ago (2015-11-19 23:15:42 UTC) #23
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1459953002/130001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1459953002/130001
5 years, 1 month ago (2015-11-19 23:27:40 UTC) #25
commit-bot: I haz the power
Committed patchset #8 (id:130001)
5 years, 1 month ago (2015-11-20 00:12:12 UTC) #26
commit-bot: I haz the power
5 years, 1 month ago (2015-11-20 00:13:27 UTC) #27
Message was sent while issue was closed.
Patchset 8 (id:??) landed as
https://crrev.com/97aae274311bc2da4388dedf9c25e26692ff1f98
Cr-Commit-Position: refs/heads/master@{#360692}

Powered by Google App Engine
This is Rietveld 408576698