Index: src/core/SkBitmapFilter.cpp |
diff --git a/src/core/SkBitmapFilter.cpp b/src/core/SkBitmapFilter.cpp |
index f06662544e99f86eae6b402ee7ed1d4be5672cd3..8c11f7c4c5d4308039964464648d16cc084ee088 100644 |
--- a/src/core/SkBitmapFilter.cpp |
+++ b/src/core/SkBitmapFilter.cpp |
@@ -40,14 +40,14 @@ void highQualityFilter(ColorPacker pack, const SkBitmapProcState& s, int x, int |
SkScalar fr = 0, fg = 0, fb = 0, fa = 0; |
int y0 = SkClampMax(SkScalarCeilToInt(srcPt.fY-s.getBitmapFilter()->width()), maxY); |
- int y1 = SkClampMax(SkScalarFloorToInt(srcPt.fY+s.getBitmapFilter()->width()), maxY); |
+ int y1 = SkClampMax(SkScalarFloorToInt(srcPt.fY+s.getBitmapFilter()->width()+1), maxY); |
int x0 = SkClampMax(SkScalarCeilToInt(srcPt.fX-s.getBitmapFilter()->width()), maxX); |
- int x1 = SkClampMax(SkScalarFloorToInt(srcPt.fX+s.getBitmapFilter()->width()), maxX); |
+ int x1 = SkClampMax(SkScalarFloorToInt(srcPt.fX+s.getBitmapFilter()->width())+1, maxX); |
- for (int srcY = y0; srcY <= y1; srcY++) { |
+ for (int srcY = y0; srcY < y1; srcY++) { |
SkScalar yWeight = s.getBitmapFilter()->lookupScalar((srcPt.fY - srcY)); |
- for (int srcX = x0; srcX <= x1 ; srcX++) { |
+ for (int srcX = x0; srcX < x1 ; srcX++) { |
SkScalar xWeight = s.getBitmapFilter()->lookupScalar((srcPt.fX - srcX)); |
SkScalar combined_weight = SkScalarMul(xWeight, yWeight); |