Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(53)

Side by Side Diff: cc/test/layer_tree_test.cc

Issue 656263003: cc: Move GpuMemoryBufferManager interface to gpu namespace. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: gn build fix Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « cc/surfaces/display.cc ('k') | cc/test/test_gpu_memory_buffer_manager.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/test/layer_tree_test.h" 5 #include "cc/test/layer_tree_test.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "cc/animation/animation.h" 8 #include "cc/animation/animation.h"
9 #include "cc/animation/animation_registrar.h" 9 #include "cc/animation/animation_registrar.h"
10 #include "cc/animation/layer_animation_controller.h" 10 #include "cc/animation/layer_animation_controller.h"
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
107 107
108 // Adapts LayerTreeHostImpl for test. Runs real code, then invokes test hooks. 108 // Adapts LayerTreeHostImpl for test. Runs real code, then invokes test hooks.
109 class LayerTreeHostImplForTesting : public LayerTreeHostImpl { 109 class LayerTreeHostImplForTesting : public LayerTreeHostImpl {
110 public: 110 public:
111 static scoped_ptr<LayerTreeHostImplForTesting> Create( 111 static scoped_ptr<LayerTreeHostImplForTesting> Create(
112 TestHooks* test_hooks, 112 TestHooks* test_hooks,
113 const LayerTreeSettings& settings, 113 const LayerTreeSettings& settings,
114 LayerTreeHostImplClient* host_impl_client, 114 LayerTreeHostImplClient* host_impl_client,
115 Proxy* proxy, 115 Proxy* proxy,
116 SharedBitmapManager* shared_bitmap_manager, 116 SharedBitmapManager* shared_bitmap_manager,
117 GpuMemoryBufferManager* gpu_memory_buffer_manager, 117 gpu::GpuMemoryBufferManager* gpu_memory_buffer_manager,
118 RenderingStatsInstrumentation* stats_instrumentation) { 118 RenderingStatsInstrumentation* stats_instrumentation) {
119 return make_scoped_ptr( 119 return make_scoped_ptr(
120 new LayerTreeHostImplForTesting(test_hooks, 120 new LayerTreeHostImplForTesting(test_hooks,
121 settings, 121 settings,
122 host_impl_client, 122 host_impl_client,
123 proxy, 123 proxy,
124 shared_bitmap_manager, 124 shared_bitmap_manager,
125 gpu_memory_buffer_manager, 125 gpu_memory_buffer_manager,
126 stats_instrumentation)); 126 stats_instrumentation));
127 } 127 }
128 128
129 protected: 129 protected:
130 LayerTreeHostImplForTesting( 130 LayerTreeHostImplForTesting(
131 TestHooks* test_hooks, 131 TestHooks* test_hooks,
132 const LayerTreeSettings& settings, 132 const LayerTreeSettings& settings,
133 LayerTreeHostImplClient* host_impl_client, 133 LayerTreeHostImplClient* host_impl_client,
134 Proxy* proxy, 134 Proxy* proxy,
135 SharedBitmapManager* shared_bitmap_manager, 135 SharedBitmapManager* shared_bitmap_manager,
136 GpuMemoryBufferManager* gpu_memory_buffer_manager, 136 gpu::GpuMemoryBufferManager* gpu_memory_buffer_manager,
137 RenderingStatsInstrumentation* stats_instrumentation) 137 RenderingStatsInstrumentation* stats_instrumentation)
138 : LayerTreeHostImpl(settings, 138 : LayerTreeHostImpl(settings,
139 host_impl_client, 139 host_impl_client,
140 proxy, 140 proxy,
141 stats_instrumentation, 141 stats_instrumentation,
142 shared_bitmap_manager, 142 shared_bitmap_manager,
143 gpu_memory_buffer_manager, 143 gpu_memory_buffer_manager,
144 0), 144 0),
145 test_hooks_(test_hooks), 145 test_hooks_(test_hooks),
146 block_notify_ready_to_activate_for_testing_(false), 146 block_notify_ready_to_activate_for_testing_(false),
(...skipping 568 matching lines...) Expand 10 before | Expand all | Expand 10 after
715 return -1; 715 return -1;
716 } 716 }
717 717
718 void LayerTreeTest::DestroyLayerTreeHost() { 718 void LayerTreeTest::DestroyLayerTreeHost() {
719 if (layer_tree_host_ && layer_tree_host_->root_layer()) 719 if (layer_tree_host_ && layer_tree_host_->root_layer())
720 layer_tree_host_->root_layer()->SetLayerTreeHost(NULL); 720 layer_tree_host_->root_layer()->SetLayerTreeHost(NULL);
721 layer_tree_host_ = nullptr; 721 layer_tree_host_ = nullptr;
722 } 722 }
723 723
724 } // namespace cc 724 } // namespace cc
OLDNEW
« no previous file with comments | « cc/surfaces/display.cc ('k') | cc/test/test_gpu_memory_buffer_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698