diff options
author | senorblanco@chromium.org <senorblanco@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2011-07-22 15:31:14 +0000 |
---|---|---|
committer | senorblanco@chromium.org <senorblanco@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2011-07-22 15:31:14 +0000 |
commit | 2ce9a04b27f29d618e70a9b6ae535e17d73910e0 (patch) | |
tree | 16d364f70d850387d40b81a0fd1f9d490a3c2924 /experimental | |
parent | 58007d713eb1d408cc9a2b9cf37ae95bdbea9e38 (diff) |
Improve GPU blur performance 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.
Review URL: http://codereview.appspot.com/4803048/
git-svn-id: http://skia.googlecode.com/svn/trunk@1941 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'experimental')
0 files changed, 0 insertions, 0 deletions