Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(290)

Issue 7307076: Fix a few bugs in both fast and slow blur; implementations now match visually. Also provide a way … (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
11 years, 7 months ago by Humper
Modified:
11 years, 6 months ago
CC:
skia-review_googlegroups.com
Base URL:
https://skia.googlecode.com/svn/trunk
Visibility:
Public.

Description

Fix a few bugs in both fast and slow blur; implementations now match visually. Also provide a way to interpret the incoming radius as sigma/2 Note -- may need to guard things to do the multi-stage webkit rebaseline goodness BUG= Committed: https://code.google.com/p/skia/source/detail?r=7793

Patch Set 1 #

Patch Set 2 : re-enable old GM tests #

Total comments: 41

Patch Set 3 : Style cleanups and restore old high->low quality trigger behavior #

Patch Set 4 : fix syntax error #

Patch Set 5 : style cleanups, and add support for rectangles that are thinner than the support of the blur kernel #

Total comments: 11

Patch Set 6 : style nitpicks and function rename. #

Patch Set 7 : Add support for blur styles, redo gm to exercise it. I cut out some of the blur radii from the gm … #

Total comments: 1

Patch Set 8 : Merge 8 bit rollback from stephen #

Patch Set 9 : fix issues with merge #

Total comments: 8

Patch Set 10 : Pare down the # of tests / GMs #

Unified diffs Side-by-side diffs Delta from patch set Stats (+660 lines, -195 lines) Patch
M bench/BlurRectBench.cpp View 1 2 3 4 5 6 7 8 9 3 chunks +97 lines, -18 lines 0 comments Download
M gm/blurrect.cpp View 1 2 3 4 5 6 7 8 9 7 chunks +194 lines, -49 lines 0 comments Download
M src/effects/SkBlurMask.h View 1 2 3 4 5 6 1 chunk +10 lines, -2 lines 0 comments Download
M src/effects/SkBlurMask.cpp View 1 2 3 4 5 6 7 8 9 33 chunks +359 lines, -126 lines 0 comments Download

Messages

Total messages: 35
Humper
https://codereview.appspot.com/7307076/diff/2001/src/effects/SkBlurMask.cpp File src/effects/SkBlurMask.cpp (left): https://codereview.appspot.com/7307076/diff/2001/src/effects/SkBlurMask.cpp#oldcode32 src/effects/SkBlurMask.cpp:32: static int boxBlur(const uint8_t* src, int src_y_stride, uint8_t* dst, ...
11 years, 7 months ago (2013-02-08 19:02:32 UTC) #1
Stephen White
https://codereview.appspot.com/7307076/diff/2001/src/effects/SkBlurMask.cpp File src/effects/SkBlurMask.cpp (left): https://codereview.appspot.com/7307076/diff/2001/src/effects/SkBlurMask.cpp#oldcode32 src/effects/SkBlurMask.cpp:32: static int boxBlur(const uint8_t* src, int src_y_stride, uint8_t* dst, ...
11 years, 7 months ago (2013-02-08 19:24:18 UTC) #2
robertphillips
nits https://codereview.appspot.com/7307076/diff/2001/bench/BlurRectBench.cpp File bench/BlurRectBench.cpp (right): https://codereview.appspot.com/7307076/diff/2001/bench/BlurRectBench.cpp#newcode60 bench/BlurRectBench.cpp:60: should be loopCount. Why not just set loopCount ...
11 years, 7 months ago (2013-02-08 19:33:25 UTC) #3
Stephen White
If it helps, I've attached what the code looks like with the unrolling taken out, ...
11 years, 7 months ago (2013-02-08 19:40:02 UTC) #4
Humper
https://codereview.appspot.com/7307076/diff/2001/bench/BlurRectBench.cpp File bench/BlurRectBench.cpp (right): https://codereview.appspot.com/7307076/diff/2001/bench/BlurRectBench.cpp#newcode60 bench/BlurRectBench.cpp:60: On 2013/02/08 19:33:25, robertphillips wrote: > should be loopCount. ...
11 years, 7 months ago (2013-02-08 19:51:21 UTC) #5
Stephen White
https://codereview.appspot.com/7307076/diff/2001/src/effects/SkBlurMask.cpp File src/effects/SkBlurMask.cpp (right): https://codereview.appspot.com/7307076/diff/2001/src/effects/SkBlurMask.cpp#newcode255 src/effects/SkBlurMask.cpp:255: for (; x < new_width - border - 16; ...
11 years, 7 months ago (2013-02-08 20:07:11 UTC) #6
Humper
https://codereview.appspot.com/7307076/diff/2001/bench/BlurRectBench.cpp File bench/BlurRectBench.cpp (right): https://codereview.appspot.com/7307076/diff/2001/bench/BlurRectBench.cpp#newcode60 bench/BlurRectBench.cpp:60: haha loop_count isn't even used! :D On 2013/02/08 19:51:21, ...
11 years, 7 months ago (2013-02-08 20:13:15 UTC) #7
Stephen White
https://codereview.appspot.com/7307076/diff/2001/src/effects/SkBlurMask.cpp File src/effects/SkBlurMask.cpp (right): https://codereview.appspot.com/7307076/diff/2001/src/effects/SkBlurMask.cpp#newcode54 src/effects/SkBlurMask.cpp:54: *dptr = (sum * scale + (1 << 15)) ...
11 years, 7 months ago (2013-02-08 20:13:18 UTC) #8
Humper
Okay I've done all the style cleanups Robert mentioned. I'm going to benchmark the 16 ...
11 years, 7 months ago (2013-02-08 20:14:54 UTC) #9
Humper
https://codereview.appspot.com/7307076/diff/2001/src/effects/SkBlurMask.cpp File src/effects/SkBlurMask.cpp (right): https://codereview.appspot.com/7307076/diff/2001/src/effects/SkBlurMask.cpp#newcode54 src/effects/SkBlurMask.cpp:54: *dptr = (sum * scale + (1 << 15)) ...
11 years, 7 months ago (2013-02-08 21:36:29 UTC) #10
Stephen White
https://codereview.appspot.com/7307076/diff/2001/src/effects/SkBlurMask.cpp File src/effects/SkBlurMask.cpp (right): https://codereview.appspot.com/7307076/diff/2001/src/effects/SkBlurMask.cpp#newcode54 src/effects/SkBlurMask.cpp:54: *dptr = (sum * scale + (1 << 15)) ...
11 years, 7 months ago (2013-02-08 21:50:30 UTC) #11
Humper
https://codereview.appspot.com/7307076/diff/2001/src/effects/SkBlurMask.cpp File src/effects/SkBlurMask.cpp (right): https://codereview.appspot.com/7307076/diff/2001/src/effects/SkBlurMask.cpp#newcode54 src/effects/SkBlurMask.cpp:54: *dptr = (sum * scale + (1 << 15)) ...
11 years, 7 months ago (2013-02-08 21:51:50 UTC) #12
Humper
Bench results here: http://70.32.156.53:10117/builders/Skia_Shuttle_Ubuntu12_ATI5770_Float_Bench_64_Trybot/builds/12/steps/BenchWebpagePictures/logs/stdio Greg Humphreys | Software Engineer [skia, chrome] | humper@google.com | 434-260-0543 ...
11 years, 7 months ago (2013-02-09 14:13:36 UTC) #13
Humper
I also submitted bench runs for other platforms, but the system didn't send me mail ...
11 years, 7 months ago (2013-02-09 14:14:06 UTC) #14
reed1
... what is the summary of the bench-results for your CL? On Sat, Feb 9, ...
11 years, 7 months ago (2013-02-11 14:36:33 UTC) #15
Humper
Ah, the summary is that the bench trybots don't email me when they're done, which ...
11 years, 7 months ago (2013-02-11 14:38:34 UTC) #16
Humper
Nevermind, the mails were just going to spam. The summary is that it seems some ...
11 years, 7 months ago (2013-02-11 15:29:17 UTC) #17
Humper
In these experiments I saw that in 8 bit mode we lack the precision to ...
11 years, 7 months ago (2013-02-11 17:23:56 UTC) #18
Humper
CL updated with some style cleanups as well as support for rectangles that are thinner ...
11 years, 7 months ago (2013-02-12 14:56:28 UTC) #19
reed1
https://codereview.appspot.com/7307076/diff/13002/src/effects/SkBlurMask.cpp File src/effects/SkBlurMask.cpp (right): https://codereview.appspot.com/7307076/diff/13002/src/effects/SkBlurMask.cpp#newcode198 src/effects/SkBlurMask.cpp:198: { I know its not new to this CL, ...
11 years, 7 months ago (2013-02-12 15:14:35 UTC) #20
Humper
https://codereview.appspot.com/7307076/diff/13002/src/effects/SkBlurMask.cpp File src/effects/SkBlurMask.cpp (right): https://codereview.appspot.com/7307076/diff/13002/src/effects/SkBlurMask.cpp#newcode198 src/effects/SkBlurMask.cpp:198: { To be honest the details of boxBlurInterp are ...
11 years, 7 months ago (2013-02-12 20:34:04 UTC) #21
Humper
New code uploaded. Incidentally, the 'quality' and 'style' parameters to BlurRect aren't used anywhere. They ...
11 years, 7 months ago (2013-02-12 20:38:11 UTC) #22
Humper
Final draft adds support for blur styles to the fast analytic path; they match up ...
11 years, 7 months ago (2013-02-15 00:27:25 UTC) #23
Stephen White
You're also going to need to wrap the SkBlurMask changes in an #ifdef, so that ...
11 years, 7 months ago (2013-02-15 16:41:33 UTC) #24
Stephen White
11 years, 7 months ago (2013-02-15 16:41:51 UTC) #25
reed1
Stephen, since you understand the current code better, do you have an alternate fix for ...
11 years, 7 months ago (2013-02-15 17:01:55 UTC) #26
Stephen White
On 2013/02/15 17:01:55, reed1 wrote: > Stephen, since you understand the current code better, do ...
11 years, 6 months ago (2013-02-15 18:22:18 UTC) #27
reed1
There seem to be a lot of changes in SkBlurMask.cpp that are just renamings (e.g. ...
11 years, 6 months ago (2013-02-20 14:28:23 UTC) #28
Humper
I'll pare down the tests / benches. As for the style changes, I made those ...
11 years, 6 months ago (2013-02-20 14:33:35 UTC) #29
reed1
https://codereview.appspot.com/7307076/diff/21001/src/effects/SkBlurMask.cpp File src/effects/SkBlurMask.cpp (right): https://codereview.appspot.com/7307076/diff/21001/src/effects/SkBlurMask.cpp#newcode533 src/effects/SkBlurMask.cpp:533: uint32_t tmp = sum[px+py] + sum[nx+ny] - sum[nx+py] - ...
11 years, 6 months ago (2013-02-20 14:40:56 UTC) #30
Humper
On 2013/02/20 14:40:56, reed1 wrote: > Ah. Perhaps we just add a // TODO comment ...
11 years, 6 months ago (2013-02-20 14:47:57 UTC) #31
Stephen White
https://codereview.appspot.com/7307076/diff/21001/src/effects/SkBlurMask.cpp File src/effects/SkBlurMask.cpp (right): https://codereview.appspot.com/7307076/diff/21001/src/effects/SkBlurMask.cpp#newcode533 src/effects/SkBlurMask.cpp:533: uint32_t tmp = sum[px+py] + sum[nx+ny] - sum[nx+py] - ...
11 years, 6 months ago (2013-02-20 14:56:52 UTC) #32
Humper
On 2013/02/20 14:47:57, Humper wrote: > On 2013/02/20 14:40:56, reed1 wrote: > > Ah. Perhaps ...
11 years, 6 months ago (2013-02-20 15:03:13 UTC) #33
reed1
You have a note in your description about needing a guard for layoutests. Should you ...
11 years, 6 months ago (2013-02-20 15:48:19 UTC) #34
reed1
11 years, 6 months ago (2013-02-20 15:49:12 UTC) #35
Soon we should consider splitting some of this into a separate impl file (as we
finally did for all the different backends for gradients). SkBlurRect.cpp is
mighty in stature...
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b