Index: src/codec/SkCodec.cpp |
diff --git a/src/codec/SkCodec.cpp b/src/codec/SkCodec.cpp |
index 0411e44069e32cd15e7e218ac2100eb6649e6080..015b1229747f7e7aec98c21062ecf4cf6e7a31e7 100644 |
--- a/src/codec/SkCodec.cpp |
+++ b/src/codec/SkCodec.cpp |
@@ -61,3 +61,12 @@ bool SkCodec::rewindIfNeeded() { |
fNeedsRewind = true; |
return !neededRewind || fStream->rewind(); |
} |
+ |
+SkScanlineDecoder* SkCodec::getScanlineDecoder(const SkImageInfo& dstInfo) { |
+ fScanlineDecoder.reset(NULL); |
+ if (!rewindIfNeeded()) { |
+ return NULL; |
+ } |
+ fScanlineDecoder.reset(this->onGetScanlineDecoder(dstInfo)); |
+ return fScanlineDecoder.get(); |
+} |