Title: [119696] trunk/Source
- Revision
- 119696
- Author
- [email protected]
- Date
- 2012-06-07 02:26:37 -0700 (Thu, 07 Jun 2012)
Log Message
Unreviewed, rolling out r119689.
http://trac.webkit.org/changeset/119689
https://bugs.webkit.org/show_bug.cgi?id=88516
it broke didDrawNotCalledOnScissoredLayer webkit_unit_test
(Requested by loislo on #webkit).
Patch by Sheriff Bot <[email protected]> on 2012-06-07
Source/WebCore:
* platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
(WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
(WebCore::CCLayerTreeHostImpl::didDrawAllLayers):
Source/WebKit/chromium:
* tests/CCLayerTreeHostImplTest.cpp:
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (119695 => 119696)
--- trunk/Source/WebCore/ChangeLog 2012-06-07 09:11:08 UTC (rev 119695)
+++ trunk/Source/WebCore/ChangeLog 2012-06-07 09:26:37 UTC (rev 119696)
@@ -1,3 +1,16 @@
+2012-06-07 Sheriff Bot <[email protected]>
+
+ Unreviewed, rolling out r119689.
+ http://trac.webkit.org/changeset/119689
+ https://bugs.webkit.org/show_bug.cgi?id=88516
+
+ it broke didDrawNotCalledOnScissoredLayer webkit_unit_test
+ (Requested by loislo on #webkit).
+
+ * platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp:
+ (WebCore::CCLayerTreeHostImpl::calculateRenderPasses):
+ (WebCore::CCLayerTreeHostImpl::didDrawAllLayers):
+
2012-06-07 Ami Fischman <[email protected]>
Plumb CORS attribute information from HTMLMediaElement to media players so it can be used
Modified: trunk/Source/WebCore/platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp (119695 => 119696)
--- trunk/Source/WebCore/platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp 2012-06-07 09:11:08 UTC (rev 119695)
+++ trunk/Source/WebCore/platform/graphics/chromium/cc/CCLayerTreeHostImpl.cpp 2012-06-07 09:26:37 UTC (rev 119696)
@@ -261,11 +261,6 @@
}
}
-static inline bool shouldDrawLayer(CCLayerImpl* layer)
-{
- return !layer->visibleLayerRect().isEmpty() && !layer->scissorRect().isEmpty();
-}
-
bool CCLayerTreeHostImpl::calculateRenderPasses(CCRenderPassList& passes, CCLayerList& renderSurfaceLayerList)
{
ASSERT(passes.isEmpty());
@@ -310,7 +305,7 @@
if (it.representsContributingRenderSurface() && !it->renderSurface()->scissorRect().isEmpty()) {
CCRenderPass* contributingRenderPass = surfacePassMap.get(it->renderSurface());
pass->appendQuadsForRenderSurfaceLayer(*it, contributingRenderPass, &occlusionTracker);
- } else if (it.representsItself() && shouldDrawLayer(*it)) {
+ } else if (it.representsItself() && !it->visibleLayerRect().isEmpty() && !it->scissorRect().isEmpty()) {
it->willDraw(m_layerRenderer.get(), context());
pass->appendQuadsForLayer(*it, &occlusionTracker, hadMissingTiles);
}
@@ -440,7 +435,7 @@
CCLayerIteratorType end = CCLayerIteratorType::end(&frame.renderSurfaceLayerList);
for (CCLayerIteratorType it = CCLayerIteratorType::begin(&frame.renderSurfaceLayerList); it != end; ++it) {
- if (it.representsItself() && shouldDrawLayer(*it))
+ if (it.representsItself() && !it->visibleLayerRect().isEmpty())
it->didDraw();
}
}
Modified: trunk/Source/WebKit/chromium/ChangeLog (119695 => 119696)
--- trunk/Source/WebKit/chromium/ChangeLog 2012-06-07 09:11:08 UTC (rev 119695)
+++ trunk/Source/WebKit/chromium/ChangeLog 2012-06-07 09:26:37 UTC (rev 119696)
@@ -1,3 +1,14 @@
+2012-06-07 Sheriff Bot <[email protected]>
+
+ Unreviewed, rolling out r119689.
+ http://trac.webkit.org/changeset/119689
+ https://bugs.webkit.org/show_bug.cgi?id=88516
+
+ it broke didDrawNotCalledOnScissoredLayer webkit_unit_test
+ (Requested by loislo on #webkit).
+
+ * tests/CCLayerTreeHostImplTest.cpp:
+
2012-06-07 Ami Fischman <[email protected]>
Plumb CORS attribute information from HTMLMediaElement to media players so it can be used
Modified: trunk/Source/WebKit/chromium/tests/CCLayerTreeHostImplTest.cpp (119695 => 119696)
--- trunk/Source/WebKit/chromium/tests/CCLayerTreeHostImplTest.cpp 2012-06-07 09:11:08 UTC (rev 119695)
+++ trunk/Source/WebKit/chromium/tests/CCLayerTreeHostImplTest.cpp 2012-06-07 09:26:37 UTC (rev 119696)
@@ -454,12 +454,6 @@
bool didDrawCalled() const { return m_didDrawCalled; }
bool willDrawCalled() const { return m_willDrawCalled; }
- void clearDidDrawCheck()
- {
- m_didDrawCalled = false;
- m_willDrawCalled = false;
- }
-
protected:
explicit DidDrawCheckLayer(int id)
: CCTiledLayerImpl(id)
@@ -1417,59 +1411,6 @@
}
}
-TEST_F(CCLayerTreeHostImplTest, didDrawNotCalledOnScissoredLayer)
-{
- CCSettings settings;
- settings.partialSwapEnabled = true;
-
- RefPtr<CCGraphicsContext> context = CCGraphicsContext::create3D(GraphicsContext3DPrivate::createGraphicsContextFromWebContext(adoptPtr(new PartialSwapContext()), GraphicsContext3D::RenderDirectlyToHostWindow));
- OwnPtr<CCLayerTreeHostImpl> myHostImpl = CCLayerTreeHostImpl::create(settings, this);
- myHostImpl->initializeLayerRenderer(context.release(), UnthrottledUploader);
- myHostImpl->setViewportSize(IntSize(10, 10));
-
- myHostImpl->setRootLayer(DidDrawCheckLayer::create(0));
- DidDrawCheckLayer* root = static_cast<DidDrawCheckLayer*>(myHostImpl->rootLayer());
- root->setMasksToBounds(true);
-
- root->addChild(DidDrawCheckLayer::create(1));
- DidDrawCheckLayer* layer = static_cast<DidDrawCheckLayer*>(root->children()[0].get());
-
- CCLayerTreeHostImpl::FrameData frame;
-
- EXPECT_FALSE(root->willDrawCalled());
- EXPECT_FALSE(root->didDrawCalled());
- EXPECT_FALSE(layer->willDrawCalled());
- EXPECT_FALSE(layer->didDrawCalled());
-
- // We should draw everything the first frame.
- EXPECT_TRUE(myHostImpl->prepareToDraw(frame));
- myHostImpl->drawLayers(frame);
- myHostImpl->didDrawAllLayers(frame);
-
- EXPECT_TRUE(root->willDrawCalled());
- EXPECT_TRUE(root->didDrawCalled());
- EXPECT_TRUE(layer->willDrawCalled());
- EXPECT_TRUE(layer->didDrawCalled());
-
- root->clearDidDrawCheck();
- layer->clearDidDrawCheck();
-
- EXPECT_FALSE(root->willDrawCalled());
- EXPECT_FALSE(root->didDrawCalled());
- EXPECT_FALSE(layer->willDrawCalled());
- EXPECT_FALSE(layer->didDrawCalled());
-
- // Drawing again, we should scissor out everything since there is no damage.
- EXPECT_TRUE(myHostImpl->prepareToDraw(frame));
- myHostImpl->drawLayers(frame);
- myHostImpl->didDrawAllLayers(frame);
-
- EXPECT_FALSE(root->willDrawCalled());
- EXPECT_FALSE(root->didDrawCalled());
- EXPECT_FALSE(layer->willDrawCalled());
- EXPECT_FALSE(layer->didDrawCalled());
-}
-
// Make sure that context lost notifications are propagated through the tree.
class ContextLostNotificationCheckLayer : public CCLayerImpl {
public:
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes