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

Issue 6844067: Added dashing fast path (Closed)

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

Description

This CL adds a fast path for single-pixel on/off dashed lines. It handles about 70% of the dashed lines seen in the captured skps. It definitely helps the gpu path but only seems to make a difference on the pokemon-table test for raster: d:\src\skia.9\trunk>python bench\bench_compare.py -o before-gpu.txt -n after-gpu.txt milwaukeepolicenews.skp tile_256x256_gpu 8.03 8.99 -0.96 -12.0% vnexpress.skp tile_256x256_gpu 23.54 26.18 -2.64 -11.2% sms.personal.skp tile_256x256_gpu 8.24 9.06 -0.82 -10.0% spreadsheet.skp tile_256x256_gpu 20.03 21.91 -1.88 -9.4% sahadan.skp tile_256x256_gpu 22.21 24.25 -2.04 -9.2% techcrunch.skp tile_256x256_gpu 49.12 53.40 -4.28 -8.7% simsimi.skp tile_256x256_gpu 15.03 16.28 -1.25 -8.3% pravda.skp tile_256x256_gpu 20.03 21.66 -1.63 -8.1% cuteoverload.skp tile_256x256_gpu 131.84 142.10 -10.26 -7.8% sfgate.skp tile_256x256_gpu 59.95 64.03 -4.08 -6.8% wsj.skp tile_256x256_gpu 93.34 99.09 -5.75 -6.2% uk.wsj.skp tile_256x256_gpu 78.83 83.28 -4.45 -5.6% nofolo.skp tile_256x256_gpu 15.73 16.55 -0.82 -5.2% theverge.skp tile_256x256_gpu 158.83 166.61 -7.78 -4.9% michelle-obama-debate.skp tile_256x256_gpu 204.40 214.00 -9.60 -4.7% wowwiki-pandaria.skp tile_256x256_gpu 203.29 212.34 -9.05 -4.5% xkcd.skp tile_256x256_gpu 30.44 31.73 -1.29 -4.2% gmail.skp tile_256x256_gpu 38.29 39.67 -1.38 -3.6% slashdot.skp tile_256x256_gpu 79.43 82.21 -2.78 -3.5% game.deksiam.in.th.skp tile_256x256_gpu 67.46 69.81 -2.35 -3.5% nytimes.skp tile_256x256_gpu 35.41 36.58 -1.17 -3.3% youtube.skp tile_256x256_gpu 137.19 141.71 -4.52 -3.3% iphone.capitolvolkswagen.skp tile_256x256_gpu 32.23 33.26 -1.03 -3.2% transformice.skp tile_256x256_gpu 29.94 30.89 -0.95 -3.2% gsp.ro.skp tile_256x256_gpu 293.95 303.20 -9.25 -3.1% digg.skp tile_256x256_gpu 59.14 60.77 -1.63 -2.8% culturalsolutions.co.uk.skp tile_256x256_gpu 75.52 77.55 -2.03 -2.7% br.337.skp tile_256x256_gpu 33.55 34.24 -0.69 -2.1% planet.mozilla.skp tile_256x256_gpu 853.90 871.37 -17.47 -2.0% frantzen-lindeberg.skp tile_256x256_gpu 40.41 41.19 -0.78 -1.9% gmail-thread.skp tile_256x256_gpu 26.78 27.29 -0.51 -1.9% worldjournal.skp tile_256x256_gpu 304.45 310.01 -5.56 -1.8% mlb.skp tile_256x256_gpu 48.53 49.28 -0.75 -1.5% androidpolice.skp tile_256x256_gpu 298.20 300.35 -2.15 -0.7% googleblog.blogspot.uk.skp tile_256x256_gpu 153.08 153.90 -0.82 -0.5% hs.fi.skp tile_256x256_gpu 114.32 113.97 +0.35 +0.3% pokemon-table.skp tile_256x256_gpu 519.50 487.28 +32.22 +6.2% dashed-spreadsheet.skp tile_256x256_gpu 238.87 195.18 +43.69 +18.3% d:\src\skia.9\trunk>python bench\bench_compare.py -o before-bitmap.txt -n after-bitmap.txt gmail-thread.skp tile_256x256 8.54 9.46 -0.92 -10.8% digg.skp tile_256x256 36.42 38.90 -2.48 -6.8% worldjournal.skp tile_256x256 39.96 42.48 -2.52 -6.3% game.deksiam.in.th.skp tile_256x256 21.04 21.90 -0.86 -4.1% googleblog.blogspot.uk.skp tile_256x256 62.80 65.18 -2.38 -3.8% sahadan.skp tile_256x256 15.14 15.58 -0.44 -2.9% xkcd.skp tile_256x256 9.21 9.47 -0.26 -2.8% cuteoverload.skp tile_256x256 76.19 78.32 -2.13 -2.8% frantzen-lindeberg.skp tile_256x256 58.80 60.31 -1.51 -2.6% theverge.skp tile_256x256 245.85 251.33 -5.48 -2.2% vnexpress.skp tile_256x256 17.06 17.43 -0.37 -2.2% techcrunch.skp tile_256x256 42.67 43.56 -0.89 -2.1% nytimes.skp tile_256x256 24.13 24.44 -0.31 -1.3% pravda.skp tile_256x256 10.19 10.32 -0.13 -1.3% planet.mozilla.skp tile_256x256 819.16 828.99 -9.83 -1.2% sfgate.skp tile_256x256 42.09 42.56 -0.47 -1.1% slashdot.skp tile_256x256 21.19 21.37 -0.18 -0.8% sms.personal.skp tile_256x256 2.99 3.01 -0.02 -0.7% dashed-spreadsheet.skp tile_256x256 77.84 78.35 -0.51 -0.7% gmail.skp tile_256x256 13.40 13.48 -0.08 -0.6% transformice.skp tile_256x256 17.93 18.03 -0.10 -0.6% wowwiki-pandaria.skp tile_256x256 170.82 171.76 -0.94 -0.6% androidpolice.skp tile_256x256 388.71 390.67 -1.96 -0.5% milwaukeepolicenews.skp tile_256x256 6.35 6.38 -0.03 -0.5% spreadsheet.skp tile_256x256 9.43 9.46 -0.03 -0.3% uk.wsj.skp tile_256x256 53.73 53.80 -0.07 -0.1% gsp.ro.skp tile_256x256 204.58 204.52 +0.06 +0.0% mlb.skp tile_256x256 50.38 50.27 +0.11 +0.2% youtube.skp tile_256x256 40.58 40.48 +0.10 +0.2% michelle-obama-debate.skp tile_256x256 88.83 88.55 +0.28 +0.3% nofolo.skp tile_256x256 13.80 13.74 +0.06 +0.4% hs.fi.skp tile_256x256 80.89 79.74 +1.15 +1.4% culturalsolutions.co.uk.skp tile_256x256 75.20 74.06 +1.14 +1.5% wsj.skp tile_256x256 61.91 60.76 +1.15 +1.9% iphone.capitolvolkswagen.skp tile_256x256 20.31 19.85 +0.46 +2.3% pokemon-table.skp tile_256x256 367.13 356.94 +10.19 +2.8% simsimi.skp tile_256x256 4.48 4.24 +0.24 +5.4% br.337.skp tile_256x256 19.53 17.28 +2.25 +11.5%

Patch Set 1 #

Patch Set 2 : Addressed code review issues #

Patch Set 3 : Aggregated 'asPoints' return information #

Patch Set 4 : Added extra tests in SkDraw::drawPoints #

Patch Set 5 : Added some enhancements #

Unified diffs Side-by-side diffs Delta from patch set Stats (+240 lines, -0 lines) Patch
M gm/dashing.cpp View 1 chunk +78 lines, -0 lines 0 comments Download
M include/core/SkPathEffect.h View 1 2 3 4 2 chunks +45 lines, -0 lines 0 comments Download
M include/effects/SkDashPathEffect.h View 1 2 1 chunk +3 lines, -0 lines 0 comments Download
M src/core/SkDraw.cpp View 1 2 3 1 chunk +33 lines, -0 lines 0 comments Download
M src/core/SkPathEffect.cpp View 1 2 1 chunk +5 lines, -0 lines 0 comments Download
M src/effects/SkDashPathEffect.cpp View 1 2 1 chunk +76 lines, -0 lines 0 comments Download

Messages

Total messages: 6
robertphillips
11 years, 7 months ago (2012-11-20 15:30:34 UTC) #1
reed1
virtual bool asPoints(SkTDArray<SkPoint>* results, const SkPath& src, SkStrokeRec*, const SkMatrix*) const; Seems like SkStrokeRec is ...
11 years, 7 months ago (2012-11-21 14:47:23 UTC) #2
robertphillips
This patch: fixes the parameters to asPoints adds a comment to asPoints to capture future ...
11 years, 7 months ago (2012-11-26 16:14:13 UTC) #3
robertphillips
Altered interface to aggregate point information returned by 'asPoints'.
11 years, 7 months ago (2012-11-26 19:21:12 UTC) #4
reed1
lgtm further refinements: - add explicit constructor/destructor - add fPath field - consider SkData or ...
11 years, 7 months ago (2012-11-28 15:03:17 UTC) #5
robertphillips
11 years, 7 months ago (2012-11-28 17:19:05 UTC) #6
committed as r6585

- add explicit constructor/destructor

Done.

- add fPath field

Done.

- consider SkData or ptr/len for returned data instead of templated-array

Added TODO.
Sign in to reply to this message.

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