When traversing convex paths only consume zero length segments.

BUG=chromium:688671

Change-Id: Ic27dde1ea7c1fe8b6afa0a05c637d8272e88b803
Reviewed-on: https://skia-review.googlesource.com/9071
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
This commit is contained in:
Brian Salomon 2017-02-28 11:21:28 -05:00 committed by Skia Commit-Bot
parent e556bf76df
commit 97042bfd9f
2 changed files with 2 additions and 2 deletions

View File

@ -281,7 +281,7 @@ static bool get_segments(const SkPath& path,
for (;;) {
SkPoint pts[4];
SkPath::Verb verb = iter.next(pts);
SkPath::Verb verb = iter.next(pts, true, true);
switch (verb) {
case SkPath::kMove_Verb:
m.mapPoints(pts, 1);

View File

@ -365,7 +365,7 @@ bool GrAAConvexTessellator::extractFromPath(const SkMatrix& m, const SkPath& pat
SkPath::Iter iter(path, true);
SkPoint pts[4];
SkPath::Verb verb;
while ((verb = iter.next(pts)) != SkPath::kDone_Verb) {
while ((verb = iter.next(pts, true, true)) != SkPath::kDone_Verb) {
switch (verb) {
case SkPath::kLine_Verb:
this->lineTo(m, pts[1], kSharp_CurveState);