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

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

Issue 15058004: cc: Rename VSync to BeginFrame (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Rebase Created 7 years, 7 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/fake_output_surface.cc ('k') | cc/trees/layer_tree_host_impl.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 526 matching lines...) Expand 10 before | Expand all | Expand 10 after
537 bool impl_side_painting) { 537 bool impl_side_painting) {
538 if (threaded) { 538 if (threaded) {
539 impl_thread_.reset(new base::Thread("Compositor")); 539 impl_thread_.reset(new base::Thread("Compositor"));
540 ASSERT_TRUE(impl_thread_->Start()); 540 ASSERT_TRUE(impl_thread_->Start());
541 } 541 }
542 542
543 main_ccthread_ = cc::ThreadImpl::CreateForCurrentThread(); 543 main_ccthread_ = cc::ThreadImpl::CreateForCurrentThread();
544 544
545 delegating_renderer_ = delegating_renderer; 545 delegating_renderer_ = delegating_renderer;
546 546
547 // Spend less time waiting for vsync because the output is mocked out. 547 // Spend less time waiting for BeginFrame because the output is
548 // mocked out.
548 settings_.refresh_rate = 200.0; 549 settings_.refresh_rate = 200.0;
549 if (impl_side_painting) { 550 if (impl_side_painting) {
550 DCHECK(threaded) << 551 DCHECK(threaded) <<
551 "Don't run single thread + impl side painting, it doesn't exist."; 552 "Don't run single thread + impl side painting, it doesn't exist.";
552 settings_.impl_side_painting = true; 553 settings_.impl_side_painting = true;
553 } 554 }
554 InitializeSettings(&settings_); 555 InitializeSettings(&settings_);
555 556
556 main_ccthread_->PostTask( 557 main_ccthread_->PostTask(
557 base::Bind(&LayerTreeTest::DoBeginTest, base::Unretained(this))); 558 base::Bind(&LayerTreeTest::DoBeginTest, base::Unretained(this)));
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
598 599
599 scoped_refptr<cc::ContextProvider> LayerTreeTest:: 600 scoped_refptr<cc::ContextProvider> LayerTreeTest::
600 OffscreenContextProviderForCompositorThread() { 601 OffscreenContextProviderForCompositorThread() {
601 if (!compositor_thread_contexts_ || 602 if (!compositor_thread_contexts_ ||
602 compositor_thread_contexts_->DestroyedOnMainThread()) 603 compositor_thread_contexts_->DestroyedOnMainThread())
603 compositor_thread_contexts_ = FakeContextProvider::Create(); 604 compositor_thread_contexts_ = FakeContextProvider::Create();
604 return compositor_thread_contexts_; 605 return compositor_thread_contexts_;
605 } 606 }
606 607
607 } // namespace cc 608 } // namespace cc
OLDNEW
« no previous file with comments | « cc/test/fake_output_surface.cc ('k') | cc/trees/layer_tree_host_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698