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

Issue 4803048: Improve GPU blur speed (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
13 years, 2 months ago by Stephen White
Modified:
13 years, 2 months ago
Reviewers:
bsalomon
CC:
skia-review_googlegroups.com
Base URL:
http://skia.googlecode.com/svn/trunk/
Visibility:
Public.

Description

This patch speeds up GPU blurs by clearing only when necessary. This gives a 1.8X speedup on the Blurs sample, and 2.3X on the BigBlur sample. We don't need to clear while downsampling, since each step reads only the pixels written in the previous step. We can avoid destination clears before convolution by disabling blending. We also don't need to clear when upsampling, since the upsample step also only reads pixels written by the convolution. The only clears we then need to do are on each side of the srcRect used for convolution, and a 1-pixel border for bilinear upsampling. Since our srcRect is always offset to (0, 0), we only need to clear on the right and bottom.

Patch Set 1 #

Patch Set 2 : Add 1-pixel clears for bilinear upsampling #

Patch Set 3 : Move comment to the right place #

Unified diffs Side-by-side diffs Delta from patch set Stats (+22 lines, -10 lines) Patch
gpu/src/GrContext.cpp View 1 1 chunk +1 line, -0 lines 0 comments Download
src/gpu/SkGpuDevice.cpp View 1 2 3 chunks +21 lines, -10 lines 0 comments Download

Messages

Total messages: 5
Stephen White
13 years, 2 months ago (2011-07-21 21:54:24 UTC) #1
bsalomon
On 2011/07/21 21:54:24, Stephen White wrote: LGTM
13 years, 2 months ago (2011-07-21 22:02:17 UTC) #2
Stephen White
Add 1-pixel clears for bilinear upsampling
13 years, 2 months ago (2011-07-21 23:02:10 UTC) #3
Stephen White
Move comment to the right place
13 years, 2 months ago (2011-07-21 23:04:20 UTC) #4
Stephen White
13 years, 2 months ago (2011-08-01 19:48:52 UTC) #5
Was landed a while ago as r1941.  Closing.
Sign in to reply to this message.

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