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

Unified Diff: dm/DMSrcSink.cpp

Issue 1006583005: SkCodec: add wbmp class (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 9 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 | « dm/DM.cpp ('k') | gyp/codec.gyp » ('j') | src/codec/SkCodec_wbmp.h » ('J')
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 5242c95e83a77f2caaf6047d3e67e41a2ed61a6c..b2e9a552cc66c8608634b931232c21dbbd3d68ee 100644
--- a/dm/DMSrcSink.cpp
+++ b/dm/DMSrcSink.cpp
@@ -93,7 +93,12 @@ Error CodecSrc::draw(SkCanvas* canvas) const {
case SkImageGenerator::kIncompleteInput:
break;
case SkImageGenerator::kInvalidConversion:
+ bitmap.reset();
+ if (SkInstallDiscardablePixelRef(codec.detach(), &bitmap)) {
msarett 2015/03/26 12:37:35 What does this do? I'm just not sure I understand
scroggo 2015/03/26 14:37:57 SkInstallDiscardablePixelRef is declared in SkImag
hal.canary 2015/03/26 17:10:53 I am removing this code for now.
+ break;
+ }
return Error::Nonfatal("Incompatible colortype conversion");
+
default:
// Everything else is considered a failure.
return SkStringPrintf("Couldn't getPixels %s.", fPath.c_str());
« no previous file with comments | « dm/DM.cpp ('k') | gyp/codec.gyp » ('j') | src/codec/SkCodec_wbmp.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698