[Chromium] Implement tile-sized painting using SkPicture.
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 6 Dec 2011 22:37:12 +0000 (22:37 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 6 Dec 2011 22:37:12 +0000 (22:37 +0000)
commit71e06ab47a20fd23318a2c874a8a2b50c4b08cbc
treea7b3e04f9a15242fbca53e2e10f19d944938d978
parent93808bafa86ca49e3689c959bf233cdc013aabd9
[Chromium] Implement tile-sized painting using SkPicture.
https://bugs.webkit.org/show_bug.cgi?id=71869

Patch by David Reveman <reveman@chromium.org> on 2011-12-06
Reviewed by James Robinson.

Source/WebCore:

Add texture uploader that paints tile-sized chunks using SkPicture
recording and playback. Expose setting which allows this texture
updater to be enabled.

No new tests. Covered by existing tests.

* WebCore.gypi:
* platform/graphics/chromium/BitmapSkPictureCanvasLayerTextureUpdater.cpp: Added.
(WebCore::BitmapSkPictureCanvasLayerTextureUpdater::Texture::Texture):
(WebCore::BitmapSkPictureCanvasLayerTextureUpdater::Texture::prepareRect):
(WebCore::BitmapSkPictureCanvasLayerTextureUpdater::Texture::updateRect):
(WebCore::BitmapSkPictureCanvasLayerTextureUpdater::create):
(WebCore::BitmapSkPictureCanvasLayerTextureUpdater::BitmapSkPictureCanvasLayerTextureUpdater):
(WebCore::BitmapSkPictureCanvasLayerTextureUpdater::~BitmapSkPictureCanvasLayerTextureUpdater):
(WebCore::BitmapSkPictureCanvasLayerTextureUpdater::createTexture):
(WebCore::BitmapSkPictureCanvasLayerTextureUpdater::sampledTexelFormat):
(WebCore::BitmapSkPictureCanvasLayerTextureUpdater::prepareToUpdate):
(WebCore::BitmapSkPictureCanvasLayerTextureUpdater::paintContentsRect):
(WebCore::BitmapSkPictureCanvasLayerTextureUpdater::updateTextureRect):
* platform/graphics/chromium/BitmapSkPictureCanvasLayerTextureUpdater.h: Added.
(WebCore::BitmapSkPictureCanvasLayerTextureUpdater::Texture::textureUpdater):
(WebCore::BitmapSkPictureCanvasLayerTextureUpdater::orientation):
* platform/graphics/chromium/ContentLayerChromium.cpp:
(WebCore::ContentLayerChromium::createTextureUpdater):
* platform/graphics/chromium/cc/CCLayerTreeHost.h:
(WebCore::CCSettings::CCSettings):

Source/WebKit/chromium:

Add perTilePainting setting that is used by compositor to determine
what texture uploader to use.

* public/WebSettings.h:
* src/WebSettingsImpl.cpp:
(WebKit::WebSettingsImpl::WebSettingsImpl):
(WebKit::WebSettingsImpl::setPerTilePainting):
* src/WebSettingsImpl.h:
(WebKit::WebSettingsImpl::perTilePainting):
* src/WebViewImpl.cpp:
(WebKit::WebViewImpl::setIsAcceleratedCompositingActive):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@102181 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/WebCore.gypi
Source/WebCore/platform/graphics/chromium/BitmapSkPictureCanvasLayerTextureUpdater.cpp [new file with mode: 0644]
Source/WebCore/platform/graphics/chromium/BitmapSkPictureCanvasLayerTextureUpdater.h [new file with mode: 0644]
Source/WebCore/platform/graphics/chromium/ContentLayerChromium.cpp
Source/WebCore/platform/graphics/chromium/cc/CCLayerTreeHost.h
Source/WebKit/chromium/ChangeLog
Source/WebKit/chromium/public/WebSettings.h
Source/WebKit/chromium/src/WebSettingsImpl.cpp
Source/WebKit/chromium/src/WebSettingsImpl.h
Source/WebKit/chromium/src/WebViewImpl.cpp