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

Unified Diff: src/lazy/SkCachingPixelRef.cpp

Issue 483493003: expose generalized imagecache key (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: remove more dead code Created 6 years, 4 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 | « src/core/SkScaledImageCache.cpp ('k') | tests/ImageCacheTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/lazy/SkCachingPixelRef.cpp
diff --git a/src/lazy/SkCachingPixelRef.cpp b/src/lazy/SkCachingPixelRef.cpp
index 97503e5fcc5771eb2add021d663c060d07ec717d..c59682854bc04e56e47ae9e504606387c95da69e 100644
--- a/src/lazy/SkCachingPixelRef.cpp
+++ b/src/lazy/SkCachingPixelRef.cpp
@@ -6,7 +6,7 @@
*/
#include "SkCachingPixelRef.h"
-#include "SkScaledImageCache.h"
+#include "SkBitmapCache.h"
bool SkCachingPixelRef::Install(SkImageGenerator* generator,
SkBitmap* dst) {
@@ -48,10 +48,8 @@ bool SkCachingPixelRef::onNewLockPixels(LockRec* rec) {
const SkImageInfo& info = this->info();
SkBitmap bitmap;
SkASSERT(NULL == fScaledCacheId);
- fScaledCacheId = SkScaledImageCache::FindAndLock(this->getGenerationID(),
- info.fWidth,
- info.fHeight,
- &bitmap);
+ fScaledCacheId = SkBitmapCache::FindAndLock(this->getGenerationID(), info.fWidth, info.fHeight,
+ &bitmap);
if (NULL == fScaledCacheId) {
// Cache has been purged, must re-decode.
if (!bitmap.allocPixels(info, fRowBytes)) {
@@ -63,10 +61,8 @@ bool SkCachingPixelRef::onNewLockPixels(LockRec* rec) {
fErrorInDecoding = true;
return false;
}
- fScaledCacheId = SkScaledImageCache::AddAndLock(this->getGenerationID(),
- info.fWidth,
- info.fHeight,
- bitmap);
+ fScaledCacheId = SkBitmapCache::AddAndLock(this->getGenerationID(),
+ info.fWidth, info.fHeight, bitmap);
SkASSERT(fScaledCacheId != NULL);
}
« no previous file with comments | « src/core/SkScaledImageCache.cpp ('k') | tests/ImageCacheTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698