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

Issue 1491843006: add support for capped hairlines (Closed)

Created:
5 years ago by caryclark
Modified:
5 years ago
Reviewers:
reed1
CC:
reviews_skia.org
Base URL:
https://skia.googlesource.com/skia.git@master
Target Ref:
refs/heads/master
Project:
skia
Visibility:
Public.

Description

add support for capped hairlines Extend the ends of hairline and haircurve segments when the paint is set to square or round, and the line or curve is at the start or end of a contour. R=reed@google.com BUG=skia:4599 Committed: https://skia.googlesource.com/skia/+/2028d7ff744c36855ed36d602e3e050e9f18ec9f

Patch Set 1 #

Patch Set 2 : add gm test for square + round cap hairlines #

Patch Set 3 : fix typos; add comments #

Patch Set 4 : fix warning #

Total comments: 2

Patch Set 5 : use a template to share code #

Patch Set 6 : outset round cap proportional to covered area #

Patch Set 7 : fix defaults; typo #

Patch Set 8 : suppress warning #

Total comments: 4

Patch Set 9 : add comment #

Unified diffs Side-by-side diffs Delta from patch set Stats (+132 lines, -4 lines) Patch
M include/core/SkPath.h View 1 2 3 4 1 chunk +8 lines, -0 lines 0 comments Download
M include/core/SkPathRef.h View 1 2 3 4 1 chunk +1 line, -0 lines 0 comments Download
M src/core/SkDraw.cpp View 1 2 3 4 5 6 7 1 chunk +32 lines, -0 lines 0 comments Download
M src/core/SkPathRef.cpp View 1 2 3 4 1 chunk +5 lines, -0 lines 0 comments Download
M src/core/SkScan.h View 1 2 3 4 5 1 chunk +4 lines, -0 lines 0 comments Download
M src/core/SkScan_Hairline.cpp View 1 2 3 4 5 6 7 8 4 chunks +82 lines, -4 lines 0 comments Download

Messages

Total messages: 33 (12 generated)
caryclark
please review
5 years ago (2015-12-02 23:47:28 UTC) #3
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1491843006/40001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1491843006/40001
5 years ago (2015-12-02 23:47:32 UTC) #4
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: Build-Ubuntu-GCC-x86_64-Release-Trybot on client.skia.compile (JOB_FAILED, http://build.chromium.org/p/client.skia.compile/builders/Build-Ubuntu-GCC-x86_64-Release-Trybot/builds/4571)
5 years ago (2015-12-02 23:48:33 UTC) #6
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1491843006/60001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1491843006/60001
5 years ago (2015-12-02 23:53:22 UTC) #8
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
5 years ago (2015-12-03 00:06:38 UTC) #10
caryclark
comments?
5 years ago (2015-12-04 15:19:03 UTC) #11
caryclark
oops, forgot to set reviewer
5 years ago (2015-12-04 15:26:34 UTC) #13
reed1
https://codereview.chromium.org/1491843006/diff/60001/gm/hairlines.cpp File gm/hairlines.cpp (right): https://codereview.chromium.org/1491843006/diff/60001/gm/hairlines.cpp#newcode246 gm/hairlines.cpp:246: draw_squarehair_tests(canvas, 0, SkPaint::kSquare_Cap, false); Wonder if adding 0.999 would ...
5 years ago (2015-12-04 18:01:10 UTC) #14
caryclark
https://codereview.chromium.org/1491843006/diff/60001/gm/hairlines.cpp File gm/hairlines.cpp (right): https://codereview.chromium.org/1491843006/diff/60001/gm/hairlines.cpp#newcode246 gm/hairlines.cpp:246: draw_squarehair_tests(canvas, 0, SkPaint::kSquare_Cap, false); On 2015/12/04 18:01:10, reed1 wrote: ...
5 years ago (2015-12-04 20:55:15 UTC) #15
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1491843006/120001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1491843006/120001
5 years ago (2015-12-07 13:22:14 UTC) #17
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: Build-Ubuntu-GCC-x86_64-Release-Trybot on client.skia.compile (JOB_FAILED, http://build.chromium.org/p/client.skia.compile/builders/Build-Ubuntu-GCC-x86_64-Release-Trybot/builds/4626)
5 years ago (2015-12-07 13:23:19 UTC) #19
caryclark
Perhaps it's worth treating square and round differently, allowing the end coverage to reflect the ...
5 years ago (2015-12-07 13:23:48 UTC) #20
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1491843006/140001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1491843006/140001
5 years ago (2015-12-07 13:27:06 UTC) #22
commit-bot: I haz the power
Dry run: This issue passed the CQ dry run.
5 years ago (2015-12-07 13:40:20 UTC) #24
caryclark
What would you like to see next on this patch?
5 years ago (2015-12-08 12:30:40 UTC) #25
reed1
Seems more readable to me than the prev, thanks. Any meansurable perf impact from nanobench? ...
5 years ago (2015-12-08 16:59:02 UTC) #26
caryclark
On 2015/12/08 16:59:02, reed1 wrote: > Seems more readable to me than the prev, thanks. ...
5 years ago (2015-12-08 19:59:13 UTC) #27
caryclark
https://codereview.chromium.org/1491843006/diff/140001/src/core/SkPathRef.cpp File src/core/SkPathRef.cpp (right): https://codereview.chromium.org/1491843006/diff/140001/src/core/SkPathRef.cpp#newcode577 src/core/SkPathRef.cpp:577: const uint8_t* next = fVerbs - 1; On 2015/12/08 ...
5 years ago (2015-12-08 19:59:39 UTC) #28
reed1
brain-fart on expecting an actual Done verb in the data stream. lgtm pending perf happiness ...
5 years ago (2015-12-08 20:03:25 UTC) #29
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1491843006/160001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1491843006/160001
5 years ago (2015-12-09 21:51:32 UTC) #31
commit-bot: I haz the power
5 years ago (2015-12-09 22:04:50 UTC) #33
Message was sent while issue was closed.
Committed patchset #9 (id:160001) as
https://skia.googlesource.com/skia/+/2028d7ff744c36855ed36d602e3e050e9f18ec9f

Powered by Google App Engine
This is Rietveld 408576698