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

Unified Diff: src/core/SkBitmapProcState.cpp

Issue 617613003: Speculative revert to diagnose crash in chrome. Revert "Add SkCachedData and use it for SkMipMap" (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years, 2 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/SkBitmapCache.cpp ('k') | src/core/SkCachedData.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkBitmapProcState.cpp
diff --git a/src/core/SkBitmapProcState.cpp b/src/core/SkBitmapProcState.cpp
index 4e9a575e02ec0f2f5424544762f197a14fe06669..6c1dc30449a81ed0a1ddd7686a2cd5eaab5b1a31 100644
--- a/src/core/SkBitmapProcState.cpp
+++ b/src/core/SkBitmapProcState.cpp
@@ -260,10 +260,11 @@ bool SkBitmapProcState::possiblyScaleImage() {
if (scaleSqd > SK_Scalar1) {
fCurrMip.reset(SkMipMapCache::FindAndRef(fOrigBitmap));
if (NULL == fCurrMip.get()) {
- fCurrMip.reset(SkMipMapCache::AddAndRef(fOrigBitmap));
+ fCurrMip.reset(SkMipMap::Build(fOrigBitmap));
if (NULL == fCurrMip.get()) {
return false;
}
+ SkMipMapCache::Add(fOrigBitmap, fCurrMip);
}
SkScalar levelScale = SkScalarInvert(SkScalarSqrt(scaleSqd));
« no previous file with comments | « src/core/SkBitmapCache.cpp ('k') | src/core/SkCachedData.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698