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

Issue 137053003: Apply the CTM to filter parameters for 4 pixel-moving filters. (Closed)

Created:
6 years, 11 months ago by Stephen White
Modified:
6 years, 11 months ago
Reviewers:
sugoi1, sugoi, reed1
CC:
skia-review_googlegroups.com
Visibility:
Public.

Description

Apply the CTM to filter parameters for SkBlurImageFilter, SkDropShadowImageFilter, SkDisplacementMapEffect and SkMorphologyImageFilter. I had resisted this (and may later put in an assert that the CTM contains no rotation, skew or perspective), but it just makes the filters play better with Skia generally. This revealed that the displacement map was not handling clipping or upstream cropping at all well (the color would "swim" through the displacement at the edge of the clip rect). Fixed by passing through the correct offsets to the bitmap accesses in both raster and GPU paths. Same for morphology. R=sugoi@google.com Committed: https://code.google.com/p/skia/source/detail?r=13127

Patch Set 1 #

Patch Set 2 : Add scaling for FEDisplacementMap #

Patch Set 3 : Add displacement map GPU path #

Patch Set 4 : Fix 100-col issue. #

Patch Set 5 : Remove spurious include. #

Patch Set 6 : Fix displacement offsets, GM clipping, colors #

Total comments: 6

Patch Set 7 : Changes re: review comments #

Patch Set 8 : Fix bug in clipped displacements GPU. Put that matrix back. #

Patch Set 9 : Win32 fix #

Patch Set 10 : Tweak #

Patch Set 11 : Reorder GM samples; embiggen the resulting png #

Patch Set 12 : Apply CTM to morphology as well; update to ToT #

Patch Set 13 : Fix leak on GM exit. #

Patch Set 14 : Revert changes to SkBlurImageFilter.h, SkDropShadowImageFilter.h; use local SkVector var instead #

Patch Set 15 : Revert changes to SkBlurImageFilter.h, SkDropShadowImageFilter.h; use local SkVector var instead #

Total comments: 6

Patch Set 16 : Fixed 100-col issues #

Unified diffs Side-by-side diffs Delta from patch set Stats (+319 lines, -84 lines) Patch
A gm/imagefiltersscaled.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 1 chunk +152 lines, -0 lines 0 comments Download
M gyp/gmslides.gypi View 1 2 3 4 5 1 chunk +1 line, -0 lines 0 comments Download
M src/effects/SkBlurImageFilter.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 2 chunks +9 lines, -4 lines 0 comments Download
M src/effects/SkDisplacementMapEffect.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 15 chunks +88 lines, -45 lines 0 comments Download
M src/effects/SkDropShadowImageFilter.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 1 chunk +6 lines, -2 lines 0 comments Download
M src/effects/SkMorphologyImageFilter.cpp View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 7 chunks +63 lines, -33 lines 0 comments Download

Messages

Total messages: 9 (0 generated)
Stephen White
PTAL. Thanks!
6 years, 11 months ago (2014-01-17 21:37:55 UTC) #1
sugoi
https://codereview.chromium.org/137053003/diff/120001/gm/imagefiltersscaled.cpp File gm/imagefiltersscaled.cpp (right): https://codereview.chromium.org/137053003/diff/120001/gm/imagefiltersscaled.cpp#newcode98 gm/imagefiltersscaled.cpp:98: SkVector::Make(SkIntToScalar(1), SkIntToScalar(1)), How about having at least 1 test ...
6 years, 11 months ago (2014-01-17 21:56:27 UTC) #2
Stephen White
https://codereview.chromium.org/137053003/diff/120001/gm/imagefiltersscaled.cpp File gm/imagefiltersscaled.cpp (right): https://codereview.chromium.org/137053003/diff/120001/gm/imagefiltersscaled.cpp#newcode98 gm/imagefiltersscaled.cpp:98: SkVector::Make(SkIntToScalar(1), SkIntToScalar(1)), On 2014/01/17 21:56:27, sugoi wrote: > How ...
6 years, 11 months ago (2014-01-18 01:23:19 UTC) #3
sugoi
On 2014/01/18 01:23:19, Stephen White wrote: > https://codereview.chromium.org/137053003/diff/120001/gm/imagefiltersscaled.cpp > File gm/imagefiltersscaled.cpp (right): > > https://codereview.chromium.org/137053003/diff/120001/gm/imagefiltersscaled.cpp#newcode98 ...
6 years, 11 months ago (2014-01-20 12:44:23 UTC) #4
Stephen White
New patch: add morphology to the party (which is even more in need of a ...
6 years, 11 months ago (2014-01-20 15:33:11 UTC) #5
sugoi
https://codereview.chromium.org/137053003/diff/670001/gm/imagefiltersscaled.cpp File gm/imagefiltersscaled.cpp (right): https://codereview.chromium.org/137053003/diff/670001/gm/imagefiltersscaled.cpp#newcode70 gm/imagefiltersscaled.cpp:70: SkAutoTUnref<SkShader> shader(SkGradientShader::CreateRadial(SkPoint::Make(x, y), radius, colors, NULL, 2, SkShader::kClamp_TileMode)); Exceeds ...
6 years, 11 months ago (2014-01-20 19:36:56 UTC) #6
Stephen White
https://codereview.chromium.org/137053003/diff/670001/gm/imagefiltersscaled.cpp File gm/imagefiltersscaled.cpp (right): https://codereview.chromium.org/137053003/diff/670001/gm/imagefiltersscaled.cpp#newcode70 gm/imagefiltersscaled.cpp:70: SkAutoTUnref<SkShader> shader(SkGradientShader::CreateRadial(SkPoint::Make(x, y), radius, colors, NULL, 2, SkShader::kClamp_TileMode)); On ...
6 years, 11 months ago (2014-01-20 19:46:01 UTC) #7
sugoi
On 2014/01/20 19:46:01, Stephen White wrote: > https://codereview.chromium.org/137053003/diff/670001/gm/imagefiltersscaled.cpp > File gm/imagefiltersscaled.cpp (right): > > https://codereview.chromium.org/137053003/diff/670001/gm/imagefiltersscaled.cpp#newcode70 ...
6 years, 11 months ago (2014-01-20 19:57:13 UTC) #8
Stephen White
6 years, 11 months ago (2014-01-20 19:58:33 UTC) #9
Message was sent while issue was closed.
Committed patchset #16 manually as r13127 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698