diff options
Diffstat (limited to 'src/image')
-rw-r--r-- | src/image/SkImage_Gpu.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/image/SkImage_Gpu.cpp b/src/image/SkImage_Gpu.cpp index b4ec0649f2..66fc813d45 100644 --- a/src/image/SkImage_Gpu.cpp +++ b/src/image/SkImage_Gpu.cpp @@ -63,8 +63,7 @@ SkImageInfo SkImage_Gpu::onImageInfo() const { } bool SkImage_Gpu::getROPixels(SkBitmap* dst, SkColorSpace* dstColorSpace, CachingHint chint) const { - const auto desc = SkBitmapCacheDesc::Make(this); - if (SkBitmapCache::Find(desc, dst)) { + if (SkBitmapCache::Find(this->uniqueID(), dst)) { SkASSERT(dst->getGenerationID() == this->uniqueID()); SkASSERT(dst->isImmutable()); SkASSERT(dst->getPixels()); @@ -87,7 +86,7 @@ bool SkImage_Gpu::getROPixels(SkBitmap* dst, SkColorSpace* dstColorSpace, Cachin dst->pixelRef()->setImmutableWithID(this->uniqueID()); if (kAllow_CachingHint == chint) { - SkBitmapCache::Add(desc, *dst); + SkBitmapCache::Add(this->uniqueID(), *dst); fAddedRasterVersionToCache.store(true); } return true; |