Index: src/core/SkReadBuffer.h |
diff --git a/src/core/SkReadBuffer.h b/src/core/SkReadBuffer.h |
index c853c0003623d0adfa6142f49d25cf8e226bf53e..b6c3f892b8d7cb9d8230296f346d5cceedd59d36 100644 |
--- a/src/core/SkReadBuffer.h |
+++ b/src/core/SkReadBuffer.h |
@@ -166,12 +166,11 @@ public: |
virtual uint32_t getArrayCount(); |
/** |
- * Returns false if the bitmap could not be completely read. In that case, it will be set |
+ * Returns false if the image could not be completely read. In that case, it will be set |
* to have width/height, but no pixels. |
*/ |
- bool readBitmap(SkBitmap* bitmap); |
- |
- SkImage* readImage(); |
+ sk_sp<SkImage> readBitmapAsImage(); |
+ sk_sp<SkImage> readImage(); |
virtual SkTypeface* readTypeface(); |
@@ -208,9 +207,12 @@ public: |
* encoded the SkBitmap. If the proper decoder cannot be used, a red bitmap with the |
* appropriate size will be used. |
*/ |
+#if 0 |
void setBitmapDecoder(SkPicture::InstallPixelRefProc bitmapDecoder) { |
fBitmapDecoder = bitmapDecoder; |
} |
+#endif |
+ void setImageDeserializer(SkImageDeserializer* factory) { fImageDeserializer = factory; } |
// Default impelementations don't check anything. |
virtual bool validate(bool isValid) { return isValid; } |
@@ -259,7 +261,8 @@ private: |
// Only used if we do not have an fFactoryArray. |
SkTHashMap<SkString, SkFlattenable::Factory> fCustomFactory; |
- SkPicture::InstallPixelRefProc fBitmapDecoder; |
+// SkPicture::InstallPixelRefProc fBitmapDecoder; |
+ SkImageDeserializer* fImageDeserializer; |
#ifdef DEBUG_NON_DETERMINISTIC_ASSERT |
// Debugging counter to keep track of how many bitmaps we |