OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "cc/occlusion_tracker.h" | 5 #include "cc/occlusion_tracker.h" |
6 | 6 |
7 #include "cc/layer.h" | 7 #include "cc/layer.h" |
8 #include "cc/layer_animation_controller.h" | 8 #include "cc/layer_animation_controller.h" |
9 #include "cc/layer_impl.h" | 9 #include "cc/layer_impl.h" |
10 #include "cc/layer_tree_host_common.h" | 10 #include "cc/layer_tree_host_common.h" |
(...skipping 259 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
270 return layer; | 270 return layer; |
271 } | 271 } |
272 | 272 |
273 void calcDrawEtc(TestContentLayerImpl* root) | 273 void calcDrawEtc(TestContentLayerImpl* root) |
274 { | 274 { |
275 DCHECK(root == m_root.get()); | 275 DCHECK(root == m_root.get()); |
276 int dummyMaxTextureSize = 512; | 276 int dummyMaxTextureSize = 512; |
277 | 277 |
278 DCHECK(!root->renderSurface()); | 278 DCHECK(!root->renderSurface()); |
279 | 279 |
280 LayerTreeHostCommon::calculateDrawProperties(root, root->bounds(), 1, 1,
dummyMaxTextureSize, false, m_renderSurfaceLayerListImpl); | 280 LayerTreeHostCommon::calculateDrawProperties(root, root->bounds(), 1, 1,
dummyMaxTextureSize, false, m_renderSurfaceLayerListImpl, false); |
281 | 281 |
282 m_layerIterator = m_layerIteratorBegin = Types::TestLayerIterator::begin
(&m_renderSurfaceLayerListImpl); | 282 m_layerIterator = m_layerIteratorBegin = Types::TestLayerIterator::begin
(&m_renderSurfaceLayerListImpl); |
283 } | 283 } |
284 | 284 |
285 void calcDrawEtc(TestContentLayer* root) | 285 void calcDrawEtc(TestContentLayer* root) |
286 { | 286 { |
287 DCHECK(root == m_root.get()); | 287 DCHECK(root == m_root.get()); |
288 int dummyMaxTextureSize = 512; | 288 int dummyMaxTextureSize = 512; |
289 | 289 |
290 DCHECK(!root->renderSurface()); | 290 DCHECK(!root->renderSurface()); |
(...skipping 2759 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3050 hasOcclusionFromOutsideTargetSurface = false; | 3050 hasOcclusionFromOutsideTargetSurface = false; |
3051 EXPECT_RECT_EQ(gfx::Rect(0, 0, 50, 50), occlusion.unoccludedContributing
SurfaceContentRect(smaller, false, gfx::Rect(0, 0, 100, 100), &hasOcclusionFromO
utsideTargetSurface)); | 3051 EXPECT_RECT_EQ(gfx::Rect(0, 0, 50, 50), occlusion.unoccludedContributing
SurfaceContentRect(smaller, false, gfx::Rect(0, 0, 100, 100), &hasOcclusionFromO
utsideTargetSurface)); |
3052 EXPECT_FALSE(hasOcclusionFromOutsideTargetSurface); | 3052 EXPECT_FALSE(hasOcclusionFromOutsideTargetSurface); |
3053 } | 3053 } |
3054 }; | 3054 }; |
3055 | 3055 |
3056 ALL_OCCLUSIONTRACKER_TEST(OcclusionTrackerTestLayerClipIsExternalOcclusion) | 3056 ALL_OCCLUSIONTRACKER_TEST(OcclusionTrackerTestLayerClipIsExternalOcclusion) |
3057 | 3057 |
3058 } // namespace | 3058 } // namespace |
3059 } // namespace cc | 3059 } // namespace cc |
OLD | NEW |