Index: src/core/SkOrderedReadBuffer.cpp |
diff --git a/src/core/SkOrderedReadBuffer.cpp b/src/core/SkOrderedReadBuffer.cpp |
index 4af64706a1db70e9246863a75f1ef9d183982c11..12343114f99e7d164dc3a93fc9d9acfdd1b58def 100644 |
--- a/src/core/SkOrderedReadBuffer.cpp |
+++ b/src/core/SkOrderedReadBuffer.cpp |
@@ -209,7 +209,13 @@ void SkOrderedReadBuffer::readBitmap(SkBitmap* bitmap) { |
// FIXME: Once the writer is changed to record the (x,y) offset, |
// they will be used to store the correct portion of the picture. |
SkBitmap subsetBm; |
+#ifdef BUMP_PICTURE_VERSION |
+ int32_t x = fReader.readS32(); |
+ int32_t y = fReader.readS32(); |
+ SkIRect subset = SkIRect::MakeXYWH(x, y, width, height); |
+#else |
SkIRect subset = SkIRect::MakeWH(width, height); |
+#endif |
if (bitmap->extractSubset(&subsetBm, subset)) { |
bitmap->swap(subsetBm); |
return; |