| OLD | NEW |
| 1 // Copyright 2011 The Chromium Authors. All rights reserved. | 1 // Copyright 2011 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/trees/layer_tree_host_impl.h" | 5 #include "cc/trees/layer_tree_host_impl.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <algorithm> | 9 #include <algorithm> |
| 10 #include <cmath> | 10 #include <cmath> |
| (...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 109 reduce_memory_result_(true) { | 109 reduce_memory_result_(true) { |
| 110 media::InitializeMediaLibrary(); | 110 media::InitializeMediaLibrary(); |
| 111 } | 111 } |
| 112 | 112 |
| 113 LayerTreeSettings DefaultSettings() { | 113 LayerTreeSettings DefaultSettings() { |
| 114 LayerTreeSettings settings; | 114 LayerTreeSettings settings; |
| 115 settings.minimum_occlusion_tracking_size = gfx::Size(); | 115 settings.minimum_occlusion_tracking_size = gfx::Size(); |
| 116 settings.renderer_settings.texture_id_allocation_chunk_size = 1; | 116 settings.renderer_settings.texture_id_allocation_chunk_size = 1; |
| 117 settings.gpu_rasterization_enabled = true; | 117 settings.gpu_rasterization_enabled = true; |
| 118 settings.verify_clip_tree_calculations = true; | 118 settings.verify_clip_tree_calculations = true; |
| 119 settings.verify_visible_rect_calculations = true; |
| 119 settings.verify_transform_tree_calculations = true; | 120 settings.verify_transform_tree_calculations = true; |
| 120 settings.renderer_settings.buffer_to_texture_target_map = | 121 settings.renderer_settings.buffer_to_texture_target_map = |
| 121 DefaultBufferToTextureTargetMapForTesting(); | 122 DefaultBufferToTextureTargetMapForTesting(); |
| 122 return settings; | 123 return settings; |
| 123 } | 124 } |
| 124 | 125 |
| 125 void SetUp() override { | 126 void SetUp() override { |
| 126 CreateHostImpl(DefaultSettings(), CreateCompositorFrameSink()); | 127 CreateHostImpl(DefaultSettings(), CreateCompositorFrameSink()); |
| 127 } | 128 } |
| 128 | 129 |
| (...skipping 11129 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 11258 EXPECT_TRUE(host_impl_->use_gpu_rasterization()); | 11259 EXPECT_TRUE(host_impl_->use_gpu_rasterization()); |
| 11259 | 11260 |
| 11260 // Re-initialize with a software output surface. | 11261 // Re-initialize with a software output surface. |
| 11261 compositor_frame_sink_ = FakeCompositorFrameSink::CreateSoftware(); | 11262 compositor_frame_sink_ = FakeCompositorFrameSink::CreateSoftware(); |
| 11262 host_impl_->InitializeRenderer(compositor_frame_sink_.get()); | 11263 host_impl_->InitializeRenderer(compositor_frame_sink_.get()); |
| 11263 EXPECT_FALSE(host_impl_->use_gpu_rasterization()); | 11264 EXPECT_FALSE(host_impl_->use_gpu_rasterization()); |
| 11264 } | 11265 } |
| 11265 | 11266 |
| 11266 } // namespace | 11267 } // namespace |
| 11267 } // namespace cc | 11268 } // namespace cc |
| OLD | NEW |