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

Unified Diff: dm/DMSrcSink.cpp

Issue 1320273004: Revert of Scanline decoding for gifs (Closed) Base URL: https://skia.googlesource.com/skia.git@real-bmp-scan
Patch Set: Created 5 years, 3 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 | src/codec/SkCodecPriv.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: dm/DMSrcSink.cpp
diff --git a/dm/DMSrcSink.cpp b/dm/DMSrcSink.cpp
index 981e47d6c0bf84690c25c8a49392fa2e3abadc18..e31a249f70bcbf58eb340c7de3719c3b87e738f3 100644
--- a/dm/DMSrcSink.cpp
+++ b/dm/DMSrcSink.cpp
@@ -352,28 +352,8 @@
return Error::Nonfatal("Could not start scanline decoder");
}
- SkCodec::Result result = SkCodec::kUnimplemented;
- switch (scanlineDecoder->getScanlineOrder()) {
- case SkScanlineDecoder::kTopDown_SkScanlineOrder:
- case SkScanlineDecoder::kBottomUp_SkScanlineOrder:
- case SkScanlineDecoder::kNone_SkScanlineOrder:
- result = scanlineDecoder->getScanlines(bitmap.getAddr(0, 0),
- decodeInfo.height(), bitmap.rowBytes());
- break;
- case SkScanlineDecoder::kOutOfOrder_SkScanlineOrder: {
- for (int y = 0; y < decodeInfo.height(); y++) {
- int dstY = scanlineDecoder->getY();
- void* dstPtr = bitmap.getAddr(0, dstY);
- result = scanlineDecoder->getScanlines(dstPtr, 1, bitmap.rowBytes());
- if (SkCodec::kSuccess != result && SkCodec::kIncompleteInput != result) {
- return SkStringPrintf("%s failed with error message %d",
- fPath.c_str(), (int) result);
- }
- }
- break;
- }
- }
-
+ const SkCodec::Result result = scanlineDecoder->getScanlines(
+ bitmap.getAddr(0, 0), decodeInfo.height(), bitmap.rowBytes());
switch (result) {
case SkCodec::kSuccess:
case SkCodec::kIncompleteInput:
« no previous file with comments | « no previous file | src/codec/SkCodecPriv.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698