[Webkit-unassigned] [Bug 106842] adding support for DiscardablePixelRef for caching lazily decoded images

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Jan 24 12:33:58 PST 2013


https://bugs.webkit.org/show_bug.cgi?id=106842





--- Comment #44 from Hin-Chung Lam <hclam at google.com>  2013-01-24 12:35:51 PST ---
(In reply to comment #38)
> (From update of attachment 184061 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=184061&action=review
> 
> Uploading a new patch to include recent changes to WebDiscardableMemory and the fix for race conditions. PTAL
> 
> >> Source/WebCore/platform/graphics/chromium/DiscardablePixelRef.cpp:42
> >> +    // unlockPixels() will be called when the image decoder goes away.
> > 
> > Does it mean that lock to DiscardablePixelRef is held for the entire lifetime of ImageDecoder?
> 
> Yes. In ImageDecodingStore::insertAndLockCache(), when the decoder is going away, the SkBitmap associated with the imageDecoder will also gone. That's when the unlockPixels() gets called.
> Since ImageFrameGenerator::decode() assigned that SkBitmap to another Skbitmap(fullSizeBitmap), so the fullSizeBitmap will have its own count on lock/unlockpixels().

I'm still confused with this statement.

SkBitmap doesn't call SkPixelRef::lockPixels() on its own, it is called only when needed isn't it? Let's have  VC today, I don't want to block you for too long.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


More information about the webkit-unassigned mailing list