scaling API on SkPixmap
BUG=skia:4481
Review URL: https://codereview.chromium.org/1463373002
diff --git a/src/core/SkBitmapController.cpp b/src/core/SkBitmapController.cpp
index 5cfa525..233e811 100644
--- a/src/core/SkBitmapController.cpp
+++ b/src/core/SkBitmapController.cpp
@@ -121,8 +121,10 @@
SkASSERT(fResultBitmap.getPixels());
fResultBitmap.setImmutable();
- if (SkBitmapCache::AddWH(desc, fResultBitmap)) {
- provider.notifyAddedToCache();
+ if (!provider.isVolatile()) {
+ if (SkBitmapCache::AddWH(desc, fResultBitmap)) {
+ provider.notifyAddedToCache();
+ }
}
}