[WK2][Qt] Move Accelerated Composite animations to UIProcess
authorigor.oliveira@openbossa.org <igor.oliveira@openbossa.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 19 Nov 2011 02:23:32 +0000 (02:23 +0000)
committerigor.oliveira@openbossa.org <igor.oliveira@openbossa.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 19 Nov 2011 02:23:32 +0000 (02:23 +0000)
commit1ba9ce9e79c88241178cec706f2a4cc22c3a08a0
tree280b0d255cc79a0e92c996b6af9da78beae264e1
parent9bf63ddfddefbe5d5850f5675aa2ea7180888d7e
[WK2][Qt] Move Accelerated Composite animations to UIProcess
https://bugs.webkit.org/show_bug.cgi?id=72753

Source/WebCore:

Add helper method to synchronize animations in TextureMapper.

Reviewed by Noam Rosenthal.

* platform/graphics/texmap/TextureMapperNode.cpp:
(WebCore::TextureMapperNode::syncAnimationsRecursively):
* platform/graphics/texmap/TextureMapperNode.h:

Source/WebKit2:

Currently, all the accelerated compositing animations are applied in WebProcess and
for each frame generated, WebProcess needs to sync with UIProcess.

This patch moves the accelerated compositing animations to UIProcess reducing the
amount of synchronization messages between WebProcess and UIProcess, this is done
sending animations information to UIProcess.

Reviewed by Noam Rosenthal.

* Shared/WebCoreArgumentCoders.cpp:
(CoreIPC::::encode):
(CoreIPC::::decode):

Encode/Decode RefPtr<Animation> instead of Animation class. This facilitates
the data serialization.

* Shared/WebCoreArgumentCoders.h:
* Shared/WebLayerTreeInfo.cpp:
(WebKit::WebLayerInfo::encode):
(WebKit::WebLayerInfo::decode):
(WebKit::WebLayerAnimation::encode):
(WebKit::WebLayerAnimation::decode):

Create WebLayerAnimation struct, it is used to send animation information
to UIProcess.

* Shared/WebLayerTreeInfo.h:
(WebKit::WebLayerAnimation::WebLayerAnimation):
* UIProcess/LayerTreeHostProxy.h:
* UIProcess/qt/LayerTreeHostProxyQt.cpp:
(WebKit::LayerTreeHostProxy::LayerTreeHostProxy):
(WebKit::LayerTreeHostProxy::paintToCurrentGLContext):
(WebKit::LayerTreeHostProxy::updateSceneGraphUpdateTimerFired):
(WebKit::LayerTreeHostProxy::syncLayerParameters):
* WebProcess/WebCoreSupport/WebGraphicsLayer.cpp:
(WebCore::WebGraphicsLayer::addAnimation):
(WebCore::WebGraphicsLayer::pauseAnimation):
(WebCore::WebGraphicsLayer::removeAnimation):
(WebCore::WebGraphicsLayer::syncCompositingStateForThisLayerOnly):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@100834 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/platform/graphics/texmap/TextureMapperNode.cpp
Source/WebCore/platform/graphics/texmap/TextureMapperNode.h
Source/WebKit2/ChangeLog
Source/WebKit2/Shared/WebCoreArgumentCoders.cpp
Source/WebKit2/Shared/WebCoreArgumentCoders.h
Source/WebKit2/Shared/WebLayerTreeInfo.cpp
Source/WebKit2/Shared/WebLayerTreeInfo.h
Source/WebKit2/UIProcess/LayerTreeHostProxy.h
Source/WebKit2/UIProcess/qt/LayerTreeHostProxyQt.cpp
Source/WebKit2/WebProcess/WebCoreSupport/WebGraphicsLayer.cpp