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

Unified Diff: src/core/SkTileGrid.cpp

Issue 13860011: Fixing numerical rounding edge case in SkTileGrid (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | tests/TileGridTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkTileGrid.cpp
===================================================================
--- src/core/SkTileGrid.cpp (revision 8831)
+++ src/core/SkTileGrid.cpp (working copy)
@@ -81,9 +81,9 @@
fInfo.fTileInterval.height();
tileStartX = SkPin32(tileStartX, 0, fXTileCount - 1);
- tileEndX = SkPin32(tileEndX, 1, fXTileCount);
+ tileEndX = SkPin32(tileEndX, tileStartX+1, fXTileCount);
tileStartY = SkPin32(tileStartY, 0, fYTileCount - 1);
- tileEndY = SkPin32(tileEndY, 1, fYTileCount);
+ tileEndY = SkPin32(tileEndY, tileStartY+1, fYTileCount);
int queryTileCount = (tileEndX - tileStartX) * (tileEndY - tileStartY);
SkASSERT(queryTileCount);
« no previous file with comments | « no previous file | tests/TileGridTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698