DescriptionMerge 113677 - [chromium] Viewport is not filled when out of texture memory on mac
https://bugs.webkit.org/show_bug.cgi?id=83351
Reviewed by Adrienne Walker.
Source/Platform:
* chromium/public/WebLayerTreeView.h:
(WebLayerTreeView):
Source/WebCore:
Currently we add gutter quads on the NonCompositedContentHost layer,
which lies above another visible layer - the rubberband layer on mac.
For this reason, on mac, gutter quads were disabled, as well as forcing
the NCCH layer to draw, in order to make the rubberband layer appear.
We move the logic for adding gutter quads into CCRenderPass, and add
gutter quads for all pixels that are visible through the viewport.
This allows us to stop special-casing the NCCH layer, and allows us
to skip drawing the layer equally with other layers. We remove the
backgroundCoversViewport() flag entirely.
In order to do this, we fix a bug in the occlusion tracker, that
allowed opaque() layers with skipsDraw to occlude, by making
the visibleContentOpaqueRegion() method on the layer classes
also return the opaque region for non-tiled layers, always use
its value in the occlusion tracker.
Unit test: CCLayerTreeHostImplTest.viewportCovered
* platform/graphics/chromium/LayerChromium.cpp:
(WebCore::LayerChromium::LayerChromium):
(WebCore::LayerChromium::pushPropertiesTo):
(WebCore::LayerChromium::visibleContentOpaqueRegion):
(WebCore):
* platform/graphics/chromium/LayerChromium.h:
(LayerChromium):
* platform/graphics/chromium/TiledLayerChromium.cpp:
(WebCore::TiledLayerChromium::prepareToUpdateTiles):
(WebCore::TiledLayerChromium::visibleContentOpaqueRegion):
* platform/graphics/chromium/cc/CCLayerImpl.cpp:
(WebCore::CCLayerImpl::CCLayerImpl):
(WebCore::CCLayerImpl::visibleContentOpaqueRegion):
(WebCore):
* platform/graphics/chromium/cc/CCLayerImpl.h:
(WebCore::CCLayerImpl::appendQuads):
(CCLayerImpl):
* platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
(WebCore::CCLayerTreeHost::CCLayerTreeHost):
(WebCore::CCLayerTreeHost::finishCommitOnImplThread):
* platform/graphics/chromium/cc/CCLayerTreeHost.h:
(WebCore::CCLayerTreeHost::setBackgroundColor):
(CCLayerTreeHost):
* platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
(WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
* platform/graphics/chromium/cc/CCLayerTreeHostImpl.h:
(WebCore::CCLayerTreeHostImpl::backgroundColor):
(WebCore::CCLayerTreeHostImpl::setBackgroundColor):
(CCLayerTreeHostImpl):
* platform/graphics/chromium/cc/CCOcclusionTracker.cpp:
(WebCore::computeOcclusionBehindLayer):
(WebCore::::markOccludedBehindLayer):
* platform/graphics/chromium/cc/CCOcclusionTracker.h:
(CCOcclusionTrackerBase):
(WebCore::CCOcclusionTrackerBase::computeVisibleRegionInScreen):
* platform/graphics/chromium/cc/CCRenderPass.cpp:
(WebCore::CCRenderPass::appendQuadsToFillScreen):
(WebCore):
* platform/graphics/chromium/cc/CCRenderPass.h:
(WebCore):
(CCRenderPass):
* platform/graphics/chromium/cc/CCTiledLayerImpl.cpp:
(WebCore::CCTiledLayerImpl::appendQuads):
(WebCore::CCTiledLayerImpl::visibleContentOpaqueRegion):
* platform/graphics/chromium/cc/CCTiledLayerImpl.h:
(WebCore::CCTiledLayerImpl::skipsDraw):
(CCTiledLayerImpl):
Source/WebKit/chromium:
* src/NonCompositedContentHost.cpp:
(WebKit::NonCompositedContentHost::NonCompositedContentHost):
(WebKit::NonCompositedContentHost::setBackgroundColor):
* src/WebLayerTreeView.cpp:
(WebKit::WebLayerTreeView::setBackgroundColor):
(WebKit):
* src/WebViewImpl.cpp:
(WebKit::WebViewImpl::setBackgroundColor):
(WebKit):
(WebKit::WebViewImplContentPainter::paint):
(WebKit::WebViewImpl::setIsAcceleratedCompositingActive):
* src/WebViewImpl.h:
(WebCore):
(WebViewImpl):
* tests/CCLayerImplTest.cpp:
(WebCore::TEST):
* tests/CCLayerTreeHostImplTest.cpp:
(WebKitTests::BlendStateCheckLayer::appendQuads):
(WebKitTests::TEST_F):
(WebKitTests):
* tests/CCLayerTreeHostTest.cpp:
(WTF):
(CCLayerTreeHostTestCommit):
(WTF::CCLayerTreeHostTestCommit::CCLayerTreeHostTestCommit):
(WTF::CCLayerTreeHostTestCommit::beginTest):
(WTF::CCLayerTreeHostTestCommit::commitCompleteOnCCThread):
(WTF::CCLayerTreeHostTestCommit::afterTest):
(WTF::TEST_F):
(TestLayerChromium):
* tests/CCOcclusionTrackerTest.cpp:
(WebKitTests::TestContentLayerChromium::TestContentLayerChromium):
(WebKitTests::TestContentLayerChromium::visibleContentOpaqueRegion):
(WebKitTests::TestContentLayerChromium::setOpaqueContentsRect):
(TestContentLayerChromium):
(WebKitTests::TestContentLayerImpl::TestContentLayerImpl):
(TestContentLayerImpl):
(WebKitTests::TestContentLayerImpl::visibleContentOpaqueRegion):
(WebKitTests::TestContentLayerImpl::setOpaqueContentsRect):
* tests/CCTiledLayerImplTest.cpp:
* tests/LayerChromiumTest.cpp:
TBR=danakj@chromium.org
Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=114757
Patch Set 1 #Messages
Total messages: 1 (0 generated)
|