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

Issue 150973004: Fixes the rendering of a SVG filter (e.g. feFlood) by testing against total (Closed)

Created:
6 years, 10 months ago by Savago-old
Modified:
6 years, 10 months ago
CC:
blink-reviews, jamesr, krit, jbroman, bemjb+rendering_chromium.org, dsinclair, zoltan1, eae+blinkwatch, leviw+renderwatch, danakj, ed+blinkwatch_opera.com, Rik, gyuyoung.kim_webkit.org, jchaffraix+rendering, pdr, pdr., rwlbuis
Base URL:
https://chromium.googlesource.com/chromium/blink.git@master
Visibility:
Public.

Description

Fixes the rendering of a SVG filter (e.g. feFlood) by testing against total area instead of single dimension. While fixing this bug, I noticed also layer violations in FilterEffectRenderer and RenderSVGResourceFilter accessing the maximum size defined in FilterEffect or replicating the test logic for maximum dimension. This patch also fixes those issues. BUG=240184 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=167564

Patch Set 1 #

Total comments: 10

Patch Set 2 : Addressed reviewer's comments: static variable, compare function, #

Total comments: 1

Patch Set 3 : FloatRect(IntRect()) #

Total comments: 5

Patch Set 4 : Added tests, proper handling area x scale. #

Patch Set 5 : Added rebaseline test. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+65 lines, -28 lines) Patch
M LayoutTests/TestExpectations View 1 2 3 4 1 chunk +2 lines, -0 lines 0 comments Download
A LayoutTests/svg/filters/big-height-filter.svg View 1 1 chunk +15 lines, -0 lines 0 comments Download
A + LayoutTests/svg/filters/big-height-filter-expected.svg View 1 2 3 1 chunk +0 lines, -1 line 0 comments Download
A LayoutTests/svg/filters/big-width-filter.svg View 1 1 chunk +15 lines, -0 lines 0 comments Download
A + LayoutTests/svg/filters/big-width-filter-expected.svg View 1 2 3 1 chunk +0 lines, -1 line 0 comments Download
M Source/core/rendering/FilterEffectRenderer.cpp View 3 chunks +2 lines, -10 lines 0 comments Download
M Source/core/rendering/svg/RenderSVGResourceFilter.cpp View 1 2 3 4 1 chunk +10 lines, -10 lines 0 comments Download
M Source/platform/graphics/filters/FilterEffect.h View 1 2 3 3 chunks +4 lines, -3 lines 0 comments Download
M Source/platform/graphics/filters/FilterEffect.cpp View 1 2 3 2 chunks +17 lines, -3 lines 0 comments Download

Messages

Total messages: 26 (0 generated)
f(malita)
No review yet, but I noticed you don't have a layout test. We'll need one ...
6 years, 10 months ago (2014-02-07 00:01:20 UTC) #1
fs
https://codereview.chromium.org/150973004/diff/1/Source/core/rendering/svg/RenderSVGResourceFilter.cpp File Source/core/rendering/svg/RenderSVGResourceFilter.cpp (right): https://codereview.chromium.org/150973004/diff/1/Source/core/rendering/svg/RenderSVGResourceFilter.cpp#newcode113 Source/core/rendering/svg/RenderSVGResourceFilter.cpp:113: if (size.width() * scale.width() > FilterEffect::maxFilterArea()) { This compares ...
6 years, 10 months ago (2014-02-07 10:17:50 UTC) #2
Savago-old
Dear fs Thanks for the review, I will comment inline. > https://codereview.chromium.org/150973004/diff/1/Source/core/rendering/svg/RenderSVGResourceFilter.cpp#newcode113 > Source/core/rendering/svg/RenderSVGResourceFilter.cpp:113: if ...
6 years, 10 months ago (2014-02-10 19:53:36 UTC) #3
Savago-old
Sorry, I missed this one: > https://codereview.chromium.org/150973004/diff/1/Source/platform/graphics/filters/FilterEffect.h > > File Source/platform/graphics/filters/FilterEffect.h (right): > > > ...
6 years, 10 months ago (2014-02-10 19:58:19 UTC) #4
fs
On 2014/02/10 19:53:36, Savago wrote: > Dear fs > > Thanks for the review, I ...
6 years, 10 months ago (2014-02-11 10:14:38 UTC) #5
fs
On 2014/02/10 19:58:19, Savago wrote: > Sorry, I missed this one: > > > > ...
6 years, 10 months ago (2014-02-11 10:18:58 UTC) #6
Stephen Chennney
Mostly I agree with fs. And you need a test. Actually, you need 3 or ...
6 years, 10 months ago (2014-02-11 14:47:20 UTC) #7
Stephen White
https://codereview.chromium.org/150973004/diff/1/Source/platform/graphics/filters/FilterEffect.cpp File Source/platform/graphics/filters/FilterEffect.cpp (right): https://codereview.chromium.org/150973004/diff/1/Source/platform/graphics/filters/FilterEffect.cpp#newcode78 Source/platform/graphics/filters/FilterEffect.cpp:78: || (rect.height() * rect.width() > kMaxFilterArea)) Is there is ...
6 years, 10 months ago (2014-02-11 15:20:34 UTC) #8
Stephen Chennney
On 2014/02/11 15:20:34, Stephen White wrote: > https://codereview.chromium.org/150973004/diff/1/Source/platform/graphics/filters/FilterEffect.cpp > File Source/platform/graphics/filters/FilterEffect.cpp (right): > > https://codereview.chromium.org/150973004/diff/1/Source/platform/graphics/filters/FilterEffect.cpp#newcode78 ...
6 years, 10 months ago (2014-02-11 16:36:37 UTC) #9
Savago-old
Gentlemen Thanks you all for the review, this next patch should address most of requests. ...
6 years, 10 months ago (2014-02-11 20:40:54 UTC) #10
Stephen White
https://codereview.chromium.org/150973004/diff/170001/Source/platform/graphics/filters/FilterEffect.cpp File Source/platform/graphics/filters/FilterEffect.cpp (right): https://codereview.chromium.org/150973004/diff/170001/Source/platform/graphics/filters/FilterEffect.cpp#newcode83 Source/platform/graphics/filters/FilterEffect.cpp:83: return isFilterSizeValid(higherPrec); Nit: Technically this isn't higher precision (there ...
6 years, 10 months ago (2014-02-11 21:03:27 UTC) #11
fs
On 2014/02/11 20:40:54, Savago wrote: > Gentlemen > > Thanks you all for the review, ...
6 years, 10 months ago (2014-02-12 08:13:23 UTC) #12
fs
https://codereview.chromium.org/150973004/diff/250001/Source/core/rendering/svg/RenderSVGResourceFilter.cpp File Source/core/rendering/svg/RenderSVGResourceFilter.cpp (right): https://codereview.chromium.org/150973004/diff/250001/Source/core/rendering/svg/RenderSVGResourceFilter.cpp#newcode113 Source/core/rendering/svg/RenderSVGResourceFilter.cpp:113: if (size.width() > FilterEffect::maxFilterLength()) { Now scale is no ...
6 years, 10 months ago (2014-02-12 08:16:36 UTC) #13
Savago-old
fs I did an experiment using different filterRes values and identified what seems to be ...
6 years, 10 months ago (2014-02-12 22:46:08 UTC) #14
Savago-old
If that is ok, I would rather first fix the current issue (i.e. rendering of ...
6 years, 10 months ago (2014-02-12 22:49:22 UTC) #15
Savago-old
Concerning the check in RenderSVGResourceFilter, what if the code tests for the scaled size area ...
6 years, 10 months ago (2014-02-13 20:59:40 UTC) #16
f(malita)
Tests look great, but let's take fs' advice and turn them into ref-tests (those are ...
6 years, 10 months ago (2014-02-15 16:00:44 UTC) #17
f(malita)
On 2014/02/12 22:49:22, Savago wrote: > If that is ok, I would rather first fix ...
6 years, 10 months ago (2014-02-15 16:03:11 UTC) #18
f(malita)
On 2014/02/15 16:00:44, Florin Malita wrote: > bool RenderSVGResourceFilter::fitsInMaximumImageSize(const FloatSize& size, > FloatSize& filterScale) Come ...
6 years, 10 months ago (2014-02-15 16:15:15 UTC) #19
f(malita)
On 2014/02/15 16:00:44, Florin Malita wrote: > But I'm a bit concerned because two of ...
6 years, 10 months ago (2014-02-15 17:14:33 UTC) #20
Savago-old
Florin Thanks for the review, I just uploaded a new patch version. I see that ...
6 years, 10 months ago (2014-02-20 00:54:20 UTC) #21
f(malita)
Thanks Savago, lgtm. On 2014/02/20 00:54:20, Savago wrote: > Florin > > Thanks for the ...
6 years, 10 months ago (2014-02-20 23:56:35 UTC) #22
Savago-old
The CQ bit was checked by a.cavalcanti@partner.samsung.com
6 years, 10 months ago (2014-02-21 01:54:01 UTC) #23
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/a.cavalcanti@partner.samsung.com/150973004/440001
6 years, 10 months ago (2014-02-21 01:54:13 UTC) #24
Savago-old
Florin Thanks for reviewing, last patch version has the rebaseline of the failing test.
6 years, 10 months ago (2014-02-21 01:55:11 UTC) #25
commit-bot: I haz the power
6 years, 10 months ago (2014-02-21 03:11:37 UTC) #26
Message was sent while issue was closed.
Change committed as 167564

Powered by Google App Engine
This is Rietveld 408576698