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

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

Issue 2337913003: Fork cc::OutputSurface into cc::CompositorFrameSink. (Closed)
Patch Set: cfsfork: android-vulkan Created 4 years, 3 months 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/test/layer_tree_test.h ('k') | cc/test/stub_layer_tree_host_client.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 "base/location.h" 8 #include "base/location.h"
9 #include "base/memory/ptr_util.h" 9 #include "base/memory/ptr_util.h"
10 #include "base/run_loop.h" 10 #include "base/run_loop.h"
11 #include "base/single_thread_task_runner.h" 11 #include "base/single_thread_task_runner.h"
12 #include "base/threading/thread_task_runner_handle.h" 12 #include "base/threading/thread_task_runner_handle.h"
13 #include "cc/animation/animation.h" 13 #include "cc/animation/animation.h"
14 #include "cc/animation/animation_host.h" 14 #include "cc/animation/animation_host.h"
15 #include "cc/animation/element_animations.h" 15 #include "cc/animation/element_animations.h"
16 #include "cc/animation/timing_function.h" 16 #include "cc/animation/timing_function.h"
17 #include "cc/base/switches.h" 17 #include "cc/base/switches.h"
18 #include "cc/blimp/image_serialization_processor.h" 18 #include "cc/blimp/image_serialization_processor.h"
19 #include "cc/input/input_handler.h" 19 #include "cc/input/input_handler.h"
20 #include "cc/layers/layer.h" 20 #include "cc/layers/layer.h"
21 #include "cc/layers/layer_impl.h" 21 #include "cc/layers/layer_impl.h"
22 #include "cc/output/buffer_to_texture_target_map.h" 22 #include "cc/output/buffer_to_texture_target_map.h"
23 #include "cc/proto/compositor_message_to_impl.pb.h" 23 #include "cc/proto/compositor_message_to_impl.pb.h"
24 #include "cc/test/animation_test_common.h" 24 #include "cc/test/animation_test_common.h"
25 #include "cc/test/begin_frame_args_test.h" 25 #include "cc/test/begin_frame_args_test.h"
26 #include "cc/test/fake_external_begin_frame_source.h" 26 #include "cc/test/fake_external_begin_frame_source.h"
27 #include "cc/test/fake_image_serialization_processor.h" 27 #include "cc/test/fake_image_serialization_processor.h"
28 #include "cc/test/fake_layer_tree_host_client.h" 28 #include "cc/test/fake_layer_tree_host_client.h"
29 #include "cc/test/fake_output_surface.h" 29 #include "cc/test/fake_output_surface.h"
30 #include "cc/test/test_compositor_frame_sink.h"
30 #include "cc/test/test_context_provider.h" 31 #include "cc/test/test_context_provider.h"
31 #include "cc/test/test_delegating_output_surface.h"
32 #include "cc/test/test_shared_bitmap_manager.h" 32 #include "cc/test/test_shared_bitmap_manager.h"
33 #include "cc/trees/layer_tree_host_client.h" 33 #include "cc/trees/layer_tree_host_client.h"
34 #include "cc/trees/layer_tree_host_impl.h" 34 #include "cc/trees/layer_tree_host_impl.h"
35 #include "cc/trees/layer_tree_host_single_thread_client.h" 35 #include "cc/trees/layer_tree_host_single_thread_client.h"
36 #include "cc/trees/layer_tree_impl.h" 36 #include "cc/trees/layer_tree_impl.h"
37 #include "cc/trees/proxy_impl.h" 37 #include "cc/trees/proxy_impl.h"
38 #include "cc/trees/proxy_main.h" 38 #include "cc/trees/proxy_main.h"
39 #include "cc/trees/remote_channel_impl.h" 39 #include "cc/trees/remote_channel_impl.h"
40 #include "cc/trees/single_thread_proxy.h" 40 #include "cc/trees/single_thread_proxy.h"
41 #include "cc/trees/threaded_channel.h" 41 #include "cc/trees/threaded_channel.h"
(...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after
221 } 221 }
222 } 222 }
223 223
224 void ActivateSyncTree() override { 224 void ActivateSyncTree() override {
225 test_hooks_->WillActivateTreeOnThread(this); 225 test_hooks_->WillActivateTreeOnThread(this);
226 LayerTreeHostImpl::ActivateSyncTree(); 226 LayerTreeHostImpl::ActivateSyncTree();
227 DCHECK(!pending_tree()); 227 DCHECK(!pending_tree());
228 test_hooks_->DidActivateTreeOnThread(this); 228 test_hooks_->DidActivateTreeOnThread(this);
229 } 229 }
230 230
231 bool InitializeRenderer(OutputSurface* output_surface) override { 231 bool InitializeRenderer(CompositorFrameSink* compositor_frame_sink) override {
232 bool success = LayerTreeHostImpl::InitializeRenderer(output_surface); 232 bool success = LayerTreeHostImpl::InitializeRenderer(compositor_frame_sink);
233 test_hooks_->InitializedRendererOnThread(this, success); 233 test_hooks_->InitializedRendererOnThread(this, success);
234 return success; 234 return success;
235 } 235 }
236 236
237 void SetVisible(bool visible) override { 237 void SetVisible(bool visible) override {
238 LayerTreeHostImpl::SetVisible(visible); 238 LayerTreeHostImpl::SetVisible(visible);
239 test_hooks_->DidSetVisibleOnImplTree(this, visible); 239 test_hooks_->DidSetVisibleOnImplTree(this, visible);
240 } 240 }
241 241
242 bool AnimateLayers(base::TimeTicks monotonic_time) override { 242 bool AnimateLayers(base::TimeTicks monotonic_time) override {
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
293 void ApplyViewportDeltas(const gfx::Vector2dF& inner_delta, 293 void ApplyViewportDeltas(const gfx::Vector2dF& inner_delta,
294 const gfx::Vector2dF& outer_delta, 294 const gfx::Vector2dF& outer_delta,
295 const gfx::Vector2dF& elastic_overscroll_delta, 295 const gfx::Vector2dF& elastic_overscroll_delta,
296 float page_scale, 296 float page_scale,
297 float top_controls_delta) override { 297 float top_controls_delta) override {
298 test_hooks_->ApplyViewportDeltas(inner_delta, outer_delta, 298 test_hooks_->ApplyViewportDeltas(inner_delta, outer_delta,
299 elastic_overscroll_delta, page_scale, 299 elastic_overscroll_delta, page_scale,
300 top_controls_delta); 300 top_controls_delta);
301 } 301 }
302 302
303 void RequestNewOutputSurface() override { 303 void RequestNewCompositorFrameSink() override {
304 test_hooks_->RequestNewOutputSurface(); 304 test_hooks_->RequestNewCompositorFrameSink();
305 } 305 }
306 306
307 void DidInitializeOutputSurface() override { 307 void DidInitializeCompositorFrameSink() override {
308 test_hooks_->DidInitializeOutputSurface(); 308 test_hooks_->DidInitializeCompositorFrameSink();
309 } 309 }
310 310
311 void DidFailToInitializeOutputSurface() override { 311 void DidFailToInitializeCompositorFrameSink() override {
312 test_hooks_->DidFailToInitializeOutputSurface(); 312 test_hooks_->DidFailToInitializeCompositorFrameSink();
313 RequestNewOutputSurface(); 313 RequestNewCompositorFrameSink();
314 } 314 }
315 315
316 void WillCommit() override { test_hooks_->WillCommit(); } 316 void WillCommit() override { test_hooks_->WillCommit(); }
317 317
318 void DidCommit() override { test_hooks_->DidCommit(); } 318 void DidCommit() override { test_hooks_->DidCommit(); }
319 319
320 void DidCommitAndDrawFrame() override { 320 void DidCommitAndDrawFrame() override {
321 test_hooks_->DidCommitAndDrawFrame(); 321 test_hooks_->DidCommitAndDrawFrame();
322 } 322 }
323 323
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
432 LayerTreeHost::InitParams* params, 432 LayerTreeHost::InitParams* params,
433 CompositorMode mode) 433 CompositorMode mode)
434 : LayerTreeHost(params, mode), 434 : LayerTreeHost(params, mode),
435 test_hooks_(test_hooks), 435 test_hooks_(test_hooks),
436 test_started_(false) {} 436 test_started_(false) {}
437 437
438 TestHooks* test_hooks_; 438 TestHooks* test_hooks_;
439 bool test_started_; 439 bool test_started_;
440 }; 440 };
441 441
442 class LayerTreeTestDelegatingOutputSurfaceClient 442 class LayerTreeTestCompositorFrameSinkClient
443 : public TestDelegatingOutputSurfaceClient { 443 : public TestCompositorFrameSinkClient {
444 public: 444 public:
445 explicit LayerTreeTestDelegatingOutputSurfaceClient(TestHooks* hooks) 445 explicit LayerTreeTestCompositorFrameSinkClient(TestHooks* hooks)
446 : hooks_(hooks) {} 446 : hooks_(hooks) {}
447 447
448 // TestDelegatingOutputSurfaceClient implementation. 448 // TestCompositorFrameSinkClient implementation.
449 void DisplayReceivedCompositorFrame(const CompositorFrame& frame) override { 449 void DisplayReceivedCompositorFrame(const CompositorFrame& frame) override {
450 hooks_->DisplayReceivedCompositorFrameOnThread(frame); 450 hooks_->DisplayReceivedCompositorFrameOnThread(frame);
451 } 451 }
452 void DisplayWillDrawAndSwap(bool will_draw_and_swap, 452 void DisplayWillDrawAndSwap(bool will_draw_and_swap,
453 const RenderPassList& render_passes) override { 453 const RenderPassList& render_passes) override {
454 hooks_->DisplayWillDrawAndSwapOnThread(will_draw_and_swap, render_passes); 454 hooks_->DisplayWillDrawAndSwapOnThread(will_draw_and_swap, render_passes);
455 } 455 }
456 void DisplayDidDrawAndSwap() override { 456 void DisplayDidDrawAndSwap() override {
457 hooks_->DisplayDidDrawAndSwapOnThread(); 457 hooks_->DisplayDidDrawAndSwapOnThread();
458 } 458 }
459 459
460 private: 460 private:
461 TestHooks* hooks_; 461 TestHooks* hooks_;
462 }; 462 };
463 463
464 LayerTreeTest::LayerTreeTest() 464 LayerTreeTest::LayerTreeTest()
465 : image_serialization_processor_( 465 : image_serialization_processor_(
466 base::WrapUnique(new FakeImageSerializationProcessor)), 466 base::WrapUnique(new FakeImageSerializationProcessor)),
467 delegating_output_surface_client_( 467 compositor_frame_sink_client_(
468 new LayerTreeTestDelegatingOutputSurfaceClient(this)), 468 new LayerTreeTestCompositorFrameSinkClient(this)),
469 weak_factory_(this) { 469 weak_factory_(this) {
470 main_thread_weak_ptr_ = weak_factory_.GetWeakPtr(); 470 main_thread_weak_ptr_ = weak_factory_.GetWeakPtr();
471 471
472 // Tests should timeout quickly unless --cc-layer-tree-test-no-timeout was 472 // Tests should timeout quickly unless --cc-layer-tree-test-no-timeout was
473 // specified (for running in a debugger). 473 // specified (for running in a debugger).
474 base::CommandLine* command_line = base::CommandLine::ForCurrentProcess(); 474 base::CommandLine* command_line = base::CommandLine::ForCurrentProcess();
475 if (!command_line->HasSwitch(switches::kCCLayerTreeTestNoTimeout)) 475 if (!command_line->HasSwitch(switches::kCCLayerTreeTestNoTimeout))
476 timeout_seconds_ = 5; 476 timeout_seconds_ = 5;
477 if (command_line->HasSwitch(switches::kCCLayerTreeTestLongTimeout)) 477 if (command_line->HasSwitch(switches::kCCLayerTreeTestLongTimeout))
478 timeout_seconds_ = 5 * 60; 478 timeout_seconds_ = 5 * 60;
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after
597 main_thread_weak_ptr_)); 597 main_thread_weak_ptr_));
598 } 598 }
599 599
600 void LayerTreeTest::PostNextCommitWaitsForActivationToMainThread() { 600 void LayerTreeTest::PostNextCommitWaitsForActivationToMainThread() {
601 main_task_runner_->PostTask( 601 main_task_runner_->PostTask(
602 FROM_HERE, 602 FROM_HERE,
603 base::Bind(&LayerTreeTest::DispatchNextCommitWaitsForActivation, 603 base::Bind(&LayerTreeTest::DispatchNextCommitWaitsForActivation,
604 main_thread_weak_ptr_)); 604 main_thread_weak_ptr_));
605 } 605 }
606 606
607 std::unique_ptr<OutputSurface> 607 std::unique_ptr<CompositorFrameSink>
608 LayerTreeTest::ReleaseOutputSurfaceOnLayerTreeHost() { 608 LayerTreeTest::ReleaseCompositorFrameSinkOnLayerTreeHost() {
609 if (IsRemoteTest()) { 609 if (IsRemoteTest()) {
610 DCHECK(remote_client_layer_tree_host_); 610 DCHECK(remote_client_layer_tree_host_);
611 return remote_client_layer_tree_host_->ReleaseOutputSurface(); 611 return remote_client_layer_tree_host_->ReleaseCompositorFrameSink();
612 } 612 }
613 return layer_tree_host_->ReleaseOutputSurface(); 613 return layer_tree_host_->ReleaseCompositorFrameSink();
614 } 614 }
615 615
616 void LayerTreeTest::SetVisibleOnLayerTreeHost(bool visible) { 616 void LayerTreeTest::SetVisibleOnLayerTreeHost(bool visible) {
617 layer_tree_host_->SetVisible(visible); 617 layer_tree_host_->SetVisible(visible);
618 618
619 if (IsRemoteTest()) { 619 if (IsRemoteTest()) {
620 DCHECK(remote_client_layer_tree_host_); 620 DCHECK(remote_client_layer_tree_host_);
621 remote_client_layer_tree_host_->SetVisible(visible); 621 remote_client_layer_tree_host_->SetVisible(visible);
622 } 622 }
623 } 623 }
(...skipping 10 matching lines...) Expand all
634 if (IsRemoteTest()) { 634 if (IsRemoteTest()) {
635 DCHECK(impl_thread_); 635 DCHECK(impl_thread_);
636 layer_tree_host_ = LayerTreeHostForTesting::Create( 636 layer_tree_host_ = LayerTreeHostForTesting::Create(
637 this, mode_, client_.get(), &remote_proto_channel_bridge_.channel_main, 637 this, mode_, client_.get(), &remote_proto_channel_bridge_.channel_main,
638 nullptr, nullptr, task_graph_runner_.get(), settings_, 638 nullptr, nullptr, task_graph_runner_.get(), settings_,
639 base::ThreadTaskRunnerHandle::Get(), nullptr, nullptr, 639 base::ThreadTaskRunnerHandle::Get(), nullptr, nullptr,
640 image_serialization_processor_.get()); 640 image_serialization_processor_.get());
641 DCHECK(remote_proto_channel_bridge_.channel_main.HasReceiver()); 641 DCHECK(remote_proto_channel_bridge_.channel_main.HasReceiver());
642 642
643 LayerTreeSettings settings = settings_; 643 LayerTreeSettings settings = settings_;
644 settings.abort_commit_before_output_surface_creation = false; 644 settings.abort_commit_before_compositor_frame_sink_creation = false;
645 remote_client_layer_tree_host_ = LayerTreeHostForTesting::Create( 645 remote_client_layer_tree_host_ = LayerTreeHostForTesting::Create(
646 this, mode_, client_.get(), &remote_proto_channel_bridge_.channel_impl, 646 this, mode_, client_.get(), &remote_proto_channel_bridge_.channel_impl,
647 nullptr, nullptr, task_graph_runner_.get(), settings, 647 nullptr, nullptr, task_graph_runner_.get(), settings,
648 base::ThreadTaskRunnerHandle::Get(), impl_thread_->task_runner(), 648 base::ThreadTaskRunnerHandle::Get(), impl_thread_->task_runner(),
649 nullptr, image_serialization_processor_.get()); 649 nullptr, image_serialization_processor_.get());
650 DCHECK(remote_proto_channel_bridge_.channel_impl.HasReceiver()); 650 DCHECK(remote_proto_channel_bridge_.channel_impl.HasReceiver());
651 } else { 651 } else {
652 layer_tree_host_ = LayerTreeHostForTesting::Create( 652 layer_tree_host_ = LayerTreeHostForTesting::Create(
653 this, mode_, client_.get(), nullptr, shared_bitmap_manager_.get(), 653 this, mode_, client_.get(), nullptr, shared_bitmap_manager_.get(),
654 gpu_memory_buffer_manager_.get(), task_graph_runner_.get(), settings_, 654 gpu_memory_buffer_manager_.get(), task_graph_runner_.get(), settings_,
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after
812 task_graph_runner_.reset(new TestTaskGraphRunner); 812 task_graph_runner_.reset(new TestTaskGraphRunner);
813 813
814 // Spend less time waiting for BeginFrame because the output is 814 // Spend less time waiting for BeginFrame because the output is
815 // mocked out. 815 // mocked out.
816 settings_.renderer_settings.refresh_rate = 200.0; 816 settings_.renderer_settings.refresh_rate = 200.0;
817 settings_.background_animation_rate = 200.0; 817 settings_.background_animation_rate = 200.0;
818 settings_.verify_clip_tree_calculations = true; 818 settings_.verify_clip_tree_calculations = true;
819 settings_.verify_transform_tree_calculations = true; 819 settings_.verify_transform_tree_calculations = true;
820 settings_.renderer_settings.buffer_to_texture_target_map = 820 settings_.renderer_settings.buffer_to_texture_target_map =
821 DefaultBufferToTextureTargetMapForTesting(); 821 DefaultBufferToTextureTargetMapForTesting();
822 // The TestDelegatingOutputSurface will provide a BeginFrameSource. 822 // The TestCompositorFrameSink will provide a BeginFrameSource.
823 settings_.use_output_surface_begin_frame_source = true; 823 settings_.use_compositor_frame_sink_begin_frame_source = true;
824 InitializeSettings(&settings_); 824 InitializeSettings(&settings_);
825 DCHECK(settings_.use_output_surface_begin_frame_source); 825 DCHECK(settings_.use_compositor_frame_sink_begin_frame_source);
826 DCHECK(!settings_.use_external_begin_frame_source); 826 DCHECK(!settings_.use_external_begin_frame_source);
827 827
828 base::ThreadTaskRunnerHandle::Get()->PostTask( 828 base::ThreadTaskRunnerHandle::Get()->PostTask(
829 FROM_HERE, 829 FROM_HERE,
830 base::Bind(&LayerTreeTest::DoBeginTest, base::Unretained(this))); 830 base::Bind(&LayerTreeTest::DoBeginTest, base::Unretained(this)));
831 831
832 base::RunLoop().Run(); 832 base::RunLoop().Run();
833 DestroyLayerTreeHost(); 833 DestroyLayerTreeHost();
834 834
835 timeout_.Cancel(); 835 timeout_.Cancel();
836 836
837 ASSERT_FALSE(layer_tree_host_.get()); 837 ASSERT_FALSE(layer_tree_host_.get());
838 client_ = nullptr; 838 client_ = nullptr;
839 if (timed_out_) { 839 if (timed_out_) {
840 FAIL() << "Test timed out"; 840 FAIL() << "Test timed out";
841 return; 841 return;
842 } 842 }
843 AfterTest(); 843 AfterTest();
844 } 844 }
845 845
846 void LayerTreeTest::RequestNewOutputSurface() { 846 void LayerTreeTest::RequestNewCompositorFrameSink() {
847 scoped_refptr<TestContextProvider> shared_context_provider = 847 scoped_refptr<TestContextProvider> shared_context_provider =
848 TestContextProvider::Create(); 848 TestContextProvider::Create();
849 scoped_refptr<TestContextProvider> worker_context_provider = 849 scoped_refptr<TestContextProvider> worker_context_provider =
850 TestContextProvider::CreateWorker(); 850 TestContextProvider::CreateWorker();
851 851
852 auto delegating_output_surface = CreateDelegatingOutputSurface( 852 auto compositor_frame_sink = CreateCompositorFrameSink(
853 std::move(shared_context_provider), std::move(worker_context_provider)); 853 std::move(shared_context_provider), std::move(worker_context_provider));
854 delegating_output_surface->SetClient(delegating_output_surface_client_.get()); 854 compositor_frame_sink->SetClient(compositor_frame_sink_client_.get());
855 855
856 if (IsRemoteTest()) { 856 if (IsRemoteTest()) {
857 DCHECK(remote_client_layer_tree_host_); 857 DCHECK(remote_client_layer_tree_host_);
858 remote_client_layer_tree_host_->SetOutputSurface( 858 remote_client_layer_tree_host_->SetCompositorFrameSink(
859 std::move(delegating_output_surface)); 859 std::move(compositor_frame_sink));
860 } else { 860 } else {
861 layer_tree_host_->SetOutputSurface(std::move(delegating_output_surface)); 861 layer_tree_host_->SetCompositorFrameSink(std::move(compositor_frame_sink));
862 } 862 }
863 } 863 }
864 864
865 std::unique_ptr<TestDelegatingOutputSurface> 865 std::unique_ptr<TestCompositorFrameSink>
866 LayerTreeTest::CreateDelegatingOutputSurface( 866 LayerTreeTest::CreateCompositorFrameSink(
867 scoped_refptr<ContextProvider> compositor_context_provider, 867 scoped_refptr<ContextProvider> compositor_context_provider,
868 scoped_refptr<ContextProvider> worker_context_provider) { 868 scoped_refptr<ContextProvider> worker_context_provider) {
869 bool synchronous_composite = 869 bool synchronous_composite =
870 !HasImplThread() && 870 !HasImplThread() &&
871 !layer_tree_host()->GetSettings().single_thread_proxy_scheduler; 871 !layer_tree_host()->GetSettings().single_thread_proxy_scheduler;
872 // Disable reclaim resources by default to act like the Display lives 872 // Disable reclaim resources by default to act like the Display lives
873 // out-of-process. 873 // out-of-process.
874 bool force_disable_reclaim_resources = true; 874 bool force_disable_reclaim_resources = true;
875 return base::MakeUnique<TestDelegatingOutputSurface>( 875 return base::MakeUnique<TestCompositorFrameSink>(
876 compositor_context_provider, std::move(worker_context_provider), 876 compositor_context_provider, std::move(worker_context_provider),
877 CreateDisplayOutputSurface(compositor_context_provider), 877 CreateDisplayOutputSurface(compositor_context_provider),
878 shared_bitmap_manager(), gpu_memory_buffer_manager(), 878 shared_bitmap_manager(), gpu_memory_buffer_manager(),
879 layer_tree_host()->GetSettings().renderer_settings, 879 layer_tree_host()->GetSettings().renderer_settings,
880 ImplThreadTaskRunner(), synchronous_composite, 880 ImplThreadTaskRunner(), synchronous_composite,
881 force_disable_reclaim_resources); 881 force_disable_reclaim_resources);
882 } 882 }
883 883
884 std::unique_ptr<OutputSurface> LayerTreeTest::CreateDisplayOutputSurface( 884 std::unique_ptr<OutputSurface> LayerTreeTest::CreateDisplayOutputSurface(
885 scoped_refptr<ContextProvider> compositor_context_provider) { 885 scoped_refptr<ContextProvider> compositor_context_provider) {
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
920 } 920 }
921 921
922 LayerTreeHost* LayerTreeTest::remote_client_layer_tree_host() { 922 LayerTreeHost* LayerTreeTest::remote_client_layer_tree_host() {
923 DCHECK(IsRemoteTest()); 923 DCHECK(IsRemoteTest());
924 DCHECK(task_runner_provider()->IsMainThread() || 924 DCHECK(task_runner_provider()->IsMainThread() ||
925 task_runner_provider()->IsMainThreadBlocked()); 925 task_runner_provider()->IsMainThreadBlocked());
926 return remote_client_layer_tree_host_.get(); 926 return remote_client_layer_tree_host_.get();
927 } 927 }
928 928
929 } // namespace cc 929 } // namespace cc
OLDNEW
« no previous file with comments | « cc/test/layer_tree_test.h ('k') | cc/test/stub_layer_tree_host_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698