Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: c4c680697bdba4208581dc7fd40ffdd202482c08
      
https://github.com/WebKit/WebKit/commit/c4c680697bdba4208581dc7fd40ffdd202482c08
  Author: Antoine Quint <[email protected]>
  Date:   2023-12-07 (Thu, 07 Dec 2023)

  Changed paths:
    M Source/WebCore/platform/animation/AcceleratedEffectStack.h
    M Source/WebCore/platform/animation/AcceleratedEffectStack.mm
    M Source/WebCore/platform/graphics/GraphicsLayer.cpp
    M Source/WebCore/platform/graphics/GraphicsLayer.h
    M Source/WebKit/Shared/RemoteLayerTree/RemoteLayerTreePropertyApplier.mm
    M Source/WebKit/SourcesCocoa.txt
    A Source/WebKit/UIProcess/RemoteLayerTree/RemoteAcceleratedEffectStack.h
    A Source/WebKit/UIProcess/RemoteLayerTree/RemoteAcceleratedEffectStack.mm
    M Source/WebKit/UIProcess/RemoteLayerTree/RemoteLayerTreeDrawingAreaProxy.h
    M Source/WebKit/UIProcess/RemoteLayerTree/RemoteLayerTreeDrawingAreaProxy.mm
    M Source/WebKit/UIProcess/RemoteLayerTree/RemoteLayerTreeHost.h
    M Source/WebKit/UIProcess/RemoteLayerTree/RemoteLayerTreeHost.mm
    M Source/WebKit/UIProcess/RemoteLayerTree/RemoteLayerTreeNode.h
    M Source/WebKit/UIProcess/RemoteLayerTree/RemoteLayerTreeNode.mm
    M Source/WebKit/UIProcess/RemoteLayerTree/RemoteScrollingCoordinatorProxy.h
    M 
Source/WebKit/UIProcess/RemoteLayerTree/ios/RemoteScrollingCoordinatorProxyIOS.h
    M 
Source/WebKit/UIProcess/RemoteLayerTree/ios/RemoteScrollingCoordinatorProxyIOS.mm
    M 
Source/WebKit/UIProcess/RemoteLayerTree/mac/RemoteLayerTreeEventDispatcher.cpp
    M 
Source/WebKit/UIProcess/RemoteLayerTree/mac/RemoteLayerTreeEventDispatcher.h
    M 
Source/WebKit/UIProcess/RemoteLayerTree/mac/RemoteScrollingCoordinatorProxyMac.h
    M 
Source/WebKit/UIProcess/RemoteLayerTree/mac/RemoteScrollingCoordinatorProxyMac.mm
    M Source/WebKit/WebKit.xcodeproj/project.pbxproj

  Log Message:
  -----------
  [threaded-animation-resolution] store accelerated effects and base values in 
the remote layer tree
https://bugs.webkit.org/show_bug.cgi?id=265880

Reviewed by Simon Fraser.

While we correctly encode the `AcceleratedEffectStack` from WebCore to be sent 
over IPC to
the UI process whenever there is a meaningful change, we don't do anything with 
these effects
yet. This patch creates a `RemoteAcceleratedEffectStack` and store effects and 
base values on it
and lays the groundwork for the next patch for the threaded animation 
resolution feature where
we will schedule and resolve animations in the remote layer tree.

On iOS, the `RemoteAcceleratedEffectStack` is owned by a `RemoteLayerTreeNode` 
which will access
on the main thread for animation resolution.

On macOS, the `RemoteAcceleratedEffectStack` is owned by the 
`RemoteLayerTreeEventDispatcher` which
will allow access in a thread-safe manner for animation resolution.

* Source/WebCore/platform/animation/AcceleratedEffectStack.h:
(WebCore::AcceleratedEffectStack::primaryLayerEffects const): Deleted.
(WebCore::AcceleratedEffectStack::backdropLayerEffects const): Deleted.
(WebCore::AcceleratedEffectStack::baseValues): Deleted.
* Source/WebCore/platform/animation/AcceleratedEffectStack.mm:
(WebCore::AcceleratedEffectStack::create):
(WebCore::AcceleratedEffectStack::AcceleratedEffectStack):
(WebCore::AcceleratedEffectStack::setEffects):
(WebCore::AcceleratedEffectStack::~AcceleratedEffectStack): Deleted.
* Source/WebCore/platform/graphics/GraphicsLayer.cpp:
(WebCore::GraphicsLayer::setAcceleratedEffectsAndBaseValues):
* Source/WebCore/platform/graphics/GraphicsLayer.h:
* Source/WebKit/Shared/RemoteLayerTree/RemoteLayerTreePropertyApplier.mm:
(WebKit::RemoteLayerTreePropertyApplier::applyPropertiesToLayer):
* Source/WebKit/SourcesCocoa.txt:
* Source/WebKit/UIProcess/RemoteLayerTree/RemoteAcceleratedEffectStack.h: Added.
* Source/WebKit/UIProcess/RemoteLayerTree/RemoteAcceleratedEffectStack.mm: 
Added.
(WebKit::RemoteAcceleratedEffectStack::create):
(WebKit::RemoteAcceleratedEffectStack::RemoteAcceleratedEffectStack):
* Source/WebKit/UIProcess/RemoteLayerTree/RemoteLayerTreeDrawingAreaProxy.h:
* Source/WebKit/UIProcess/RemoteLayerTree/RemoteLayerTreeDrawingAreaProxy.mm:
(WebKit::RemoteLayerTreeDrawingAreaProxy::animationsWereAddedToNode):
(WebKit::RemoteLayerTreeDrawingAreaProxy::animationsWereRemovedFromNode):
* Source/WebKit/UIProcess/RemoteLayerTree/RemoteLayerTreeHost.h:
* Source/WebKit/UIProcess/RemoteLayerTree/RemoteLayerTreeHost.mm:
(WebKit::RemoteLayerTreeHost::threadedAnimationResolutionEnabled const):
(WebKit::RemoteLayerTreeHost::animationsWereAddedToNode):
(WebKit::RemoteLayerTreeHost::animationsWereRemovedFromNode):
* Source/WebKit/UIProcess/RemoteLayerTree/RemoteLayerTreeNode.h:
(WebKit::RemoteLayerTreeNode::takeEffectStack):
* Source/WebKit/UIProcess/RemoteLayerTree/RemoteLayerTreeNode.mm:
(WebKit::RemoteLayerTreeNode::setAcceleratedEffectsAndBaseValues):
* Source/WebKit/UIProcess/RemoteLayerTree/RemoteScrollingCoordinatorProxy.h:
(WebKit::RemoteScrollingCoordinatorProxy::animationsWereAddedToNode):
(WebKit::RemoteScrollingCoordinatorProxy::animationsWereRemovedFromNode):
* 
Source/WebKit/UIProcess/RemoteLayerTree/ios/RemoteScrollingCoordinatorProxyIOS.h:
* 
Source/WebKit/UIProcess/RemoteLayerTree/ios/RemoteScrollingCoordinatorProxyIOS.mm:
(WebKit::RemoteScrollingCoordinatorProxyIOS::animationsWereAddedToNode):
(WebKit::RemoteScrollingCoordinatorProxyIOS::animationsWereRemovedFromNode):
* 
Source/WebKit/UIProcess/RemoteLayerTree/mac/RemoteLayerTreeEventDispatcher.cpp:
(WebKit::RemoteLayerTreeEventDispatcher::animationsWereAddedToNode):
(WebKit::RemoteLayerTreeEventDispatcher::animationsWereRemovedFromNode):
* Source/WebKit/UIProcess/RemoteLayerTree/mac/RemoteLayerTreeEventDispatcher.h:
* 
Source/WebKit/UIProcess/RemoteLayerTree/mac/RemoteScrollingCoordinatorProxyMac.h:
* 
Source/WebKit/UIProcess/RemoteLayerTree/mac/RemoteScrollingCoordinatorProxyMac.mm:
(WebKit::RemoteScrollingCoordinatorProxyMac::animationsWereAddedToNode):
(WebKit::RemoteScrollingCoordinatorProxyMac::animationsWereRemovedFromNode):
* Source/WebKit/WebKit.xcodeproj/project.pbxproj:

Co-authored-by: Matt Woodrow <[email protected]>
Canonical link: https://commits.webkit.org/271692@main


_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to