aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/SkLinearBitmapPipeline_tile.h
diff options
context:
space:
mode:
authorGravatar herb <herb@google.com>2016-03-07 09:17:47 -0800
committerGravatar Commit bot <commit-bot@chromium.org>2016-03-07 09:17:47 -0800
commitc60fee0f15c73137c4e335de04e9ca06e131b110 (patch)
tree62b9049fc258cab2646be16cb3f0a2985b283cd9 /src/core/SkLinearBitmapPipeline_tile.h
parent1590f3b32890f6455b30494308633177b54db347 (diff)
Rework files and add test cases.
Diffstat (limited to 'src/core/SkLinearBitmapPipeline_tile.h')
-rw-r--r--src/core/SkLinearBitmapPipeline_tile.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/core/SkLinearBitmapPipeline_tile.h b/src/core/SkLinearBitmapPipeline_tile.h
index 2f855a36af..761e3c57eb 100644
--- a/src/core/SkLinearBitmapPipeline_tile.h
+++ b/src/core/SkLinearBitmapPipeline_tile.h
@@ -100,6 +100,7 @@ public:
}
} else {
Span rightClamped = span.breakAt(xMax, dx);
+
if (!rightClamped.isEmpty()) {
rightClamped.clampToSinglePixel({xMax - 1, y});
next->pointSpan(rightClamped);
@@ -198,7 +199,7 @@ public:
Span span({x, y}, length, count);
if (dx > 0) {
- while (!span.isEmpty() && span.endX() > xMax) {
+ while (!span.isEmpty() && span.endX() >= xMax) {
Span toDraw = span.breakAt(xMax, dx);
next->pointSpan(toDraw);
span.offset(-xMax);