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

Issue 65493004: increase coverage of SkPath.cpp, remove unused code (Closed)

Created:
7 years, 1 month ago by caryclark
Modified:
7 years, 1 month ago
Reviewers:
bsalomon, reed1
CC:
skia-review_googlegroups.com
Visibility:
Public.

Description

increase coverage of SkPath.cpp, remove unused code Using Mike Klein's excellent coverage tool, increase the unit testing of SkPath.cpp from 70% to 95%. Along the way, determined that these functions were not maintained or used: SkPath::pathTo SkPath::contains as well as a large block of SkPath::cheapGetDirection(). Changed SkPath::validate() to permit infinities in the path data points. Fixed errors in preserving direction. Fixed error setting direction when convexity is unknown. Added missing conic to moveTo only detector. BUG= Committed: http://code.google.com/p/skia/source/detail?r=12291

Patch Set 1 #

Patch Set 2 : remove dead code #

Total comments: 9

Patch Set 3 : revert float to scalar #

Patch Set 4 : revert more float to scalar #

Patch Set 5 : restore contains #

Patch Set 6 : add test for contains; remove unused code #

Total comments: 2

Patch Set 7 : increase coverage above 95%; add missing conic case #

Unified diffs Side-by-side diffs Delta from patch set Stats (+664 lines, -243 lines) Patch
M bench/PathBench.cpp View 5 chunks +2 lines, -14 lines 0 comments Download
M include/core/SkPath.h View 1 2 3 4 2 chunks +2 lines, -6 lines 0 comments Download
M src/core/SkPath.cpp View 1 2 3 4 5 6 13 chunks +64 lines, -178 lines 0 comments Download
M src/core/SkPathRef.cpp View 1 chunk +3 lines, -4 lines 0 comments Download
M tests/PathTest.cpp View 1 2 3 4 5 6 24 chunks +592 lines, -40 lines 0 comments Download
M tools/coverage.sh View 1 2 3 4 5 6 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 10 (0 generated)
caryclark
7 years, 1 month ago (2013-11-13 18:06:15 UTC) #1
reed1
https://codereview.chromium.org/65493004/diff/40001/include/core/SkPath.h File include/core/SkPath.h (left): https://codereview.chromium.org/65493004/diff/40001/include/core/SkPath.h#oldcode896 include/core/SkPath.h:896: bool contains(SkScalar x, SkScalar y) const; This guy was ...
7 years, 1 month ago (2013-11-13 18:37:52 UTC) #2
caryclark
https://codereview.chromium.org/65493004/diff/40001/include/core/SkPath.h File include/core/SkPath.h (left): https://codereview.chromium.org/65493004/diff/40001/include/core/SkPath.h#oldcode896 include/core/SkPath.h:896: bool contains(SkScalar x, SkScalar y) const; On 2013/11/13 18:37:52, ...
7 years, 1 month ago (2013-11-13 18:52:37 UTC) #3
reed1
https://codereview.chromium.org/65493004/diff/40001/include/core/SkPath.h File include/core/SkPath.h (left): https://codereview.chromium.org/65493004/diff/40001/include/core/SkPath.h#oldcode896 include/core/SkPath.h:896: bool contains(SkScalar x, SkScalar y) const; On 2013/11/13 18:52:37, ...
7 years, 1 month ago (2013-11-13 18:58:58 UTC) #4
caryclark
contains() restored; SkFloatToScalar() removed; please review again
7 years, 1 month ago (2013-11-13 21:47:26 UTC) #5
bsalomon
lgtm, the new cheap dir computer is easier to read. https://codereview.chromium.org/65493004/diff/170001/tests/PathTest.cpp File tests/PathTest.cpp (right): https://codereview.chromium.org/65493004/diff/170001/tests/PathTest.cpp#newcode147 ...
7 years, 1 month ago (2013-11-14 01:28:54 UTC) #6
caryclark
This incremental CL gets the lines + functions coverage for SkPath.cpp above 95%. The coverage ...
7 years, 1 month ago (2013-11-14 15:29:35 UTC) #7
reed1
lgtm
7 years, 1 month ago (2013-11-14 16:21:57 UTC) #8
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://skia-tree-status.appspot.com/cq/caryclark@google.com/65493004/270001
7 years, 1 month ago (2013-11-14 16:24:28 UTC) #9
commit-bot: I haz the power
7 years, 1 month ago (2013-11-14 16:53:30 UTC) #10
Message was sent while issue was closed.
Change committed as 12291

Powered by Google App Engine
This is Rietveld 408576698