[chromium] Remove targetRenderSurface concept, give layers a renderTarget which is...
authordanakj@chromium.org <danakj@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 16 Jul 2012 20:39:12 +0000 (20:39 +0000)
committerdanakj@chromium.org <danakj@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 16 Jul 2012 20:39:12 +0000 (20:39 +0000)
commit78ece8395271a3faaed37feded4d74d2483b727f
treeb5c87de997ba7ace9c2df8d31672c65fa23a3f3a
parent5cd0ec9fce8cc9bad85a063d67e0f46b62b88778
[chromium] Remove targetRenderSurface concept, give layers a renderTarget which is the layer whose coordinate space they draw into
https://bugs.webkit.org/show_bug.cgi?id=91288

Reviewed by Adrienne Walker.

Source/WebCore:

Always use pointers to layers when discussing render targets instead of
pointing directly to a RenderSurface.

Covered by existing tests.

* platform/graphics/chromium/LayerChromium.cpp:
(WebCore::LayerChromium::LayerChromium):
(WebCore::LayerChromium::createRenderSurface):
* platform/graphics/chromium/LayerChromium.h:
(WebCore::LayerChromium::renderTarget):
(WebCore::LayerChromium::setRenderTarget):
(LayerChromium):
* platform/graphics/chromium/RenderSurfaceChromium.cpp:
* platform/graphics/chromium/RenderSurfaceChromium.h:
* platform/graphics/chromium/ScrollbarLayerChromium.cpp:
(WebCore::ScrollbarLayerChromium::setTexturePriorities):
* platform/graphics/chromium/TiledLayerChromium.cpp:
(WebCore::TiledLayerChromium::setTexturePrioritiesInRect):
* platform/graphics/chromium/cc/CCLayerImpl.cpp:
(WebCore::CCLayerImpl::CCLayerImpl):
(WebCore::CCLayerImpl::createRenderSurface):
(WebCore::CCLayerImpl::dumpLayerProperties):
* platform/graphics/chromium/cc/CCLayerImpl.h:
(WebCore::CCLayerImpl::renderTarget):
(WebCore::CCLayerImpl::setRenderTarget):
(CCLayerImpl):
* platform/graphics/chromium/cc/CCLayerTreeHostCommon.cpp:
(WebCore::calculateLayerScissorRect):
(WebCore::calculateSurfaceScissorRect):
(WebCore::calculateVisibleContentRect):
(WebCore::computeScrollCompensationForThisLayer):
(WebCore::calculateDrawTransformsInternal):
(WebCore::pointIsClippedBySurfaceOrClipRect):
* platform/graphics/chromium/cc/CCOcclusionTracker.cpp:
(WebCore::::enterLayer):
(WebCore::::leaveLayer):
(WebCore::::enterRenderTarget):
(WebCore::::finishedRenderTarget):
(WebCore):
(WebCore::reduceOcclusionBelowSurface):
(WebCore::::leaveToRenderTarget):
(WebCore::::markOccludedBehindLayer):
(WebCore::::occluded):
(WebCore::::unoccludedContentRect):
(WebCore::::unoccludedContributingSurfaceContentRect):
(WebCore::::layerScissorRectInTargetSurface):
* platform/graphics/chromium/cc/CCOcclusionTracker.h:
(CCOcclusionTrackerBase):
(WebCore::CCOcclusionTrackerBase::StackObject::StackObject):
(StackObject):
* platform/graphics/chromium/cc/CCQuadCuller.cpp:
(WebCore::CCQuadCuller::appendSurface):
* platform/graphics/chromium/cc/CCRenderSurface.cpp:
* platform/graphics/chromium/cc/CCRenderSurface.h:
(CCRenderSurface):

Source/WebKit/chromium:

* tests/CCDamageTrackerTest.cpp:
(WebKitTests::TEST_F):
* tests/CCLayerImplTest.cpp:
(WebCore::TEST):
* tests/CCLayerTreeHostCommonTest.cpp:
* tests/CCOcclusionTrackerTest.cpp:
(WebKitTests::CCOcclusionTrackerTestOverlappingSurfaceSiblings::runMyTest):
(WebKitTests::CCOcclusionTrackerTestOverlappingSurfaceSiblingsWithTwoTransforms::runMyTest):
(WebKitTests::CCOcclusionTrackerTestAnimationOpacity1OnMainThread::runMyTest):
(WebKitTests::CCOcclusionTrackerTestAnimationOpacity0OnMainThread::runMyTest):
(WebKitTests::CCOcclusionTrackerTestAnimationTranslateOnMainThread::runMyTest):
(WebKitTests::CCOcclusionTrackerTestReplicaOccluded::runMyTest):
(WebKitTests::CCOcclusionTrackerTestSurfaceWithReplicaUnoccluded::runMyTest):
(WebKitTests::CCOcclusionTrackerTestSurfaceAndReplicaOccludedDifferently::runMyTest):
(WebKitTests::CCOcclusionTrackerTestSurfaceChildOfSurface::runMyTest):
(WebKitTests::CCOcclusionTrackerTestTopmostSurfaceIsClippedToScissor::runMyTest):
(WebKitTests::CCOcclusionTrackerTestSurfaceChildOfClippingSurface::runMyTest):
* tests/CCQuadCullerTest.cpp:
* tests/CCTiledLayerTestCommon.cpp:
(WebKitTests::FakeTiledLayerChromium::setTexturePriorities):
* tests/LayerChromiumTest.cpp:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@122756 268f45cc-cd09-0410-ab3c-d52691b4dbfc
23 files changed:
Source/WebCore/ChangeLog
Source/WebCore/platform/graphics/chromium/LayerChromium.cpp
Source/WebCore/platform/graphics/chromium/LayerChromium.h
Source/WebCore/platform/graphics/chromium/RenderSurfaceChromium.cpp
Source/WebCore/platform/graphics/chromium/RenderSurfaceChromium.h
Source/WebCore/platform/graphics/chromium/ScrollbarLayerChromium.cpp
Source/WebCore/platform/graphics/chromium/TiledLayerChromium.cpp
Source/WebCore/platform/graphics/chromium/cc/CCLayerImpl.cpp
Source/WebCore/platform/graphics/chromium/cc/CCLayerImpl.h
Source/WebCore/platform/graphics/chromium/cc/CCLayerTreeHostCommon.cpp
Source/WebCore/platform/graphics/chromium/cc/CCOcclusionTracker.cpp
Source/WebCore/platform/graphics/chromium/cc/CCOcclusionTracker.h
Source/WebCore/platform/graphics/chromium/cc/CCQuadCuller.cpp
Source/WebCore/platform/graphics/chromium/cc/CCRenderSurface.cpp
Source/WebCore/platform/graphics/chromium/cc/CCRenderSurface.h
Source/WebKit/chromium/ChangeLog
Source/WebKit/chromium/tests/CCDamageTrackerTest.cpp
Source/WebKit/chromium/tests/CCLayerImplTest.cpp
Source/WebKit/chromium/tests/CCLayerTreeHostCommonTest.cpp
Source/WebKit/chromium/tests/CCOcclusionTrackerTest.cpp
Source/WebKit/chromium/tests/CCQuadCullerTest.cpp
Source/WebKit/chromium/tests/CCTiledLayerTestCommon.cpp
Source/WebKit/chromium/tests/LayerChromiumTest.cpp