[Webkit-unassigned] [Bug 93174] RenderLayerBacking must call GraphicsLayer::setContentsToImage when the image is changed.
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Fri Aug 3 22:36:01 PDT 2012
https://bugs.webkit.org/show_bug.cgi?id=93174
Simon Fraser (smfr) <simon.fraser at apple.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #156509|review?, commit-queue? |review-, commit-queue-
Flag| |
--- Comment #3 from Simon Fraser (smfr) <simon.fraser at apple.com> 2012-08-03 22:35:59 PST ---
(From update of attachment 156509)
View in context: https://bugs.webkit.org/attachment.cgi?id=156509&action=review
> Source/WebCore/ChangeLog:13
> + Currently, layout indirectly call RenderLayerBacking::updateGraphicsLayerConfiguration()
> + and updateGraphicsLayerConfiguration() indirectly call GraphicsLayer::setContentsToImage().
> + It burdens all accelerated compositing implementations because each implementation
> + should check if the image is changed.
This comment is confusing. updateGraphicsLayerConfiguration() isn't the place where animated GIFs get updated on compositing layers; that happens via RenderBoxModelObject::contentChanged() which ends up in RenderLayerBacking::contentChanged().
> Source/WebCore/rendering/RenderLayerBacking.cpp:1089
> + NativeImagePtr newNativeImagePtr = image->nativeImageForCurrentFrame();
> + if (newNativeImagePtr != m_compositedNativeImagePtr) {
> + m_compositedNativeImagePtr = newNativeImagePtr;
> +
> + // This is a no-op if the layer doesn't have an inner layer for the image.
> + m_graphicsLayer->setContentsToImage(image);
It seems odd to inspect the NativeImagePtr here, but still send the Image down to GraphicsLayer.
This code also makes the assumption that pointer equality on a NativeImagePtr is a valid way to tell if the image is unchanged. That may not hold for all platforms. I think the platform code should continue to make the decision about whether the image has changed.
--
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