diff options
author | reed <reed@google.com> | 2014-12-12 12:48:50 -0800 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2014-12-12 12:48:50 -0800 |
commit | ccc12ed08f7999ad47b3eb6e5d8b08765749d5b9 (patch) | |
tree | c428c366c1bab081948c9a7eefe3b68e48f5bc8b /src/effects/SkDashPathEffect.cpp | |
parent | 0e912464cecf50cc152c3fb93c2aac31c8a99cac (diff) |
improve cull, so we don't create empty segments
BUG=skia:3224
Review URL: https://codereview.chromium.org/798093002
Diffstat (limited to 'src/effects/SkDashPathEffect.cpp')
-rw-r--r-- | src/effects/SkDashPathEffect.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/effects/SkDashPathEffect.cpp b/src/effects/SkDashPathEffect.cpp index f866ea074e..8cd703f62f 100644 --- a/src/effects/SkDashPathEffect.cpp +++ b/src/effects/SkDashPathEffect.cpp @@ -94,7 +94,7 @@ static bool cull_line(SkPoint* pts, const SkStrokeRec& rec, } SkASSERT(minX < maxX); - if (maxX < bounds.fLeft || minX > bounds.fRight) { + if (maxX <= bounds.fLeft || minX >= bounds.fRight) { return false; } @@ -125,7 +125,7 @@ static bool cull_line(SkPoint* pts, const SkStrokeRec& rec, } SkASSERT(minY < maxY); - if (maxY < bounds.fTop || minY > bounds.fBottom) { + if (maxY <= bounds.fTop || minY >= bounds.fBottom) { return false; } |