[Qt][WK2] Make TiledDrawingArea request tiles only in the direction the viewport...
authorjocelyn.turcotte@nokia.com <jocelyn.turcotte@nokia.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 7 Sep 2011 17:35:21 +0000 (17:35 +0000)
committerjocelyn.turcotte@nokia.com <jocelyn.turcotte@nokia.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 7 Sep 2011 17:35:21 +0000 (17:35 +0000)
commitc23c62574c72fb8896d84e60132e88c78d5c0b6a
tree0e4a62f51fb16bdfd3dee53c4933143cb5139c72
parent419a19faff2881d781aced3459b1b774faa5a153
[Qt][WK2] Make TiledDrawingArea request tiles only in the direction the viewport is panned to.
https://bugs.webkit.org/show_bug.cgi?id=67606

Source/WebCore:

Reviewed by Noam Rosenthal.

TiledBackingStore previously used different values for horizontal and vertial multiplication
to calculate the cover area.
This patch replaces this mechanism, used to give a bigger panning range to vertical panning,
with the possibility to use the motion vector of the viewport to request tiles ahead instead.
This allows economies on rendering resources as tiles won't be rendered beside the trajectory
of the viewport.

* platform/graphics/TiledBackingStore.cpp:
(WebCore::TiledBackingStore::TiledBackingStore):
(WebCore::TiledBackingStore::setKeepAndCoverAreaMultipliers):
(WebCore::TiledBackingStore::setCoverAreaFocusVector):
(WebCore::TiledBackingStore::createTiles):
(WebCore::TiledBackingStore::calculateKeepRect):
(WebCore::TiledBackingStore::calculateCoverRect):
* platform/graphics/TiledBackingStore.h:
(WebCore::TiledBackingStore::getKeepAndCoverAreaMultipliers):

Source/WebKit/qt:

TiledBackingStore previously used different values for horizontal and vertial multiplication
to calculate the cover area.
This patch replaces this mechanism, used to give a bigger panning range to vertical panning,
with the possibility to use the motion vector of the viewport to request tiles ahead instead.
This allows economies on rendering resources as tiles won't be rendered beside the trajectory
of the viewport.

* Api/qwebpage.cpp:
(QWebPagePrivate::dynamicPropertyChangeEvent):

Source/WebKit2:

TiledBackingStore previously used different values for horizontal and vertial multiplication
to calculate the cover area.
This patch replaces this mechanism, used to give a bigger panning range to vertical panning,
with the possibility to use the motion vector of the viewport to request tiles ahead instead.
This allows economies on rendering resources as tiles won't be rendered beside the trajectory
of the viewport.

* UIProcess/API/qt/qtouchwebview.cpp:
(QTouchWebViewPrivate::QTouchWebViewPrivate):
(QTouchWebViewPrivate::_q_viewportMotionVectorChanged):
* UIProcess/API/qt/qtouchwebview.h:
* UIProcess/API/qt/qtouchwebview_p.h:
* UIProcess/TiledDrawingAreaProxy.cpp:
(WebKit::TiledDrawingAreaProxy::setVisibleContentRectMotionVector):
* UIProcess/TiledDrawingAreaProxy.h:
* UIProcess/qt/ViewportInteractionEngine.cpp:
(WebKit::ViewportInteractionEngine::panGestureRequestUpdate):
(WebKit::ViewportInteractionEngine::panGestureEnded):
(WebKit::ViewportInteractionEngine::pinchGestureStarted):
* UIProcess/qt/ViewportInteractionEngine.h:
* UIProcess/qt/qtouchwebpageproxy.cpp:
(QTouchWebPageProxy::setVisibleContentRectMotionVector):
* UIProcess/qt/qtouchwebpageproxy.h:
* WebProcess/WebPage/DrawingArea.h:
(WebKit::DrawingArea::setVisibleContentRectMotionVector):
* WebProcess/WebPage/DrawingArea.messages.in:
* WebProcess/WebPage/TiledDrawingArea.cpp:
(WebKit::TiledDrawingArea::setVisibleContentRectMotionVector):
* WebProcess/WebPage/TiledDrawingArea.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@94685 268f45cc-cd09-0410-ab3c-d52691b4dbfc
19 files changed:
Source/WebCore/ChangeLog
Source/WebCore/platform/graphics/TiledBackingStore.cpp
Source/WebCore/platform/graphics/TiledBackingStore.h
Source/WebKit/qt/Api/qwebpage.cpp
Source/WebKit/qt/ChangeLog
Source/WebKit2/ChangeLog
Source/WebKit2/UIProcess/API/qt/qtouchwebview.cpp
Source/WebKit2/UIProcess/API/qt/qtouchwebview.h
Source/WebKit2/UIProcess/API/qt/qtouchwebview_p.h
Source/WebKit2/UIProcess/TiledDrawingAreaProxy.cpp
Source/WebKit2/UIProcess/TiledDrawingAreaProxy.h
Source/WebKit2/UIProcess/qt/ViewportInteractionEngine.cpp
Source/WebKit2/UIProcess/qt/ViewportInteractionEngine.h
Source/WebKit2/UIProcess/qt/qtouchwebpageproxy.cpp
Source/WebKit2/UIProcess/qt/qtouchwebpageproxy.h
Source/WebKit2/WebProcess/WebPage/DrawingArea.h
Source/WebKit2/WebProcess/WebPage/DrawingArea.messages.in
Source/WebKit2/WebProcess/WebPage/TiledDrawingArea.cpp
Source/WebKit2/WebProcess/WebPage/TiledDrawingArea.h