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

Unified Diff: src/codec/SkSwizzler.cpp

Issue 1395183003: Add scaled subset API to SkCodec (Closed) Base URL: https://skia.googlesource.com/skia.git@split0
Patch Set: Created 5 years, 2 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
Index: src/codec/SkSwizzler.cpp
diff --git a/src/codec/SkSwizzler.cpp b/src/codec/SkSwizzler.cpp
index 95ed1d7b962f58f96836a66be01389853591105b..9c7df4350dd1ccd62e4d369cc3c132288b8a09cd 100644
--- a/src/codec/SkSwizzler.cpp
+++ b/src/codec/SkSwizzler.cpp
@@ -710,9 +710,6 @@ int SkSwizzler::onSetSampleX(int sampleX) {
fSampleX = sampleX;
fX0 = get_start_coord(sampleX) + fSrcOffset;
fDstWidth = get_scaled_dimension(fSrcWidth, sampleX);
-
msarett 2015/10/12 18:33:29 I missed this in an earlier CL, but this check is
scroggo 2015/10/12 20:47:07 Wait, does this belong in crrev.com/1390213002? I
- // check that fX0 is less than original width
- SkASSERT(fX0 >= 0 && fX0 < fSrcWidth);
return fDstWidth;
}

Powered by Google App Engine
This is Rietveld 408576698