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

Side by Side Diff: cc/trees/proxy_main.cc

Issue 1762823002: Remove runtime toggling of throttling frames (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 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/trees/proxy_main.h ('k') | cc/trees/remote_channel_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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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/proxy_main.h" 5 #include "cc/trees/proxy_main.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <string> 8 #include <string>
9 9
10 #include "base/trace_event/trace_event.h" 10 #include "base/trace_event/trace_event.h"
(...skipping 271 matching lines...) Expand 10 before | Expand all | Expand 10 after
282 282
283 void ProxyMain::SetOutputSurface(OutputSurface* output_surface) { 283 void ProxyMain::SetOutputSurface(OutputSurface* output_surface) {
284 channel_main_->InitializeOutputSurfaceOnImpl(output_surface); 284 channel_main_->InitializeOutputSurfaceOnImpl(output_surface);
285 } 285 }
286 286
287 void ProxyMain::SetVisible(bool visible) { 287 void ProxyMain::SetVisible(bool visible) {
288 TRACE_EVENT1("cc", "ProxyMain::SetVisible", "visible", visible); 288 TRACE_EVENT1("cc", "ProxyMain::SetVisible", "visible", visible);
289 channel_main_->SetVisibleOnImpl(visible); 289 channel_main_->SetVisibleOnImpl(visible);
290 } 290 }
291 291
292 void ProxyMain::SetThrottleFrameProduction(bool throttle) {
293 TRACE_EVENT1("cc", "ProxyMain::SetThrottleFrameProduction", "throttle",
294 throttle);
295 channel_main_->SetThrottleFrameProductionOnImpl(throttle);
296 }
297
298 const RendererCapabilities& ProxyMain::GetRendererCapabilities() const { 292 const RendererCapabilities& ProxyMain::GetRendererCapabilities() const {
299 DCHECK(IsMainThread()); 293 DCHECK(IsMainThread());
300 DCHECK(!layer_tree_host_->output_surface_lost()); 294 DCHECK(!layer_tree_host_->output_surface_lost());
301 return renderer_capabilities_; 295 return renderer_capabilities_;
302 } 296 }
303 297
304 void ProxyMain::SetNeedsAnimate() { 298 void ProxyMain::SetNeedsAnimate() {
305 DCHECK(IsMainThread()); 299 DCHECK(IsMainThread());
306 if (SendCommitRequestToImplThreadIfNeeded(ANIMATE_PIPELINE_STAGE)) { 300 if (SendCommitRequestToImplThreadIfNeeded(ANIMATE_PIPELINE_STAGE)) {
307 TRACE_EVENT_INSTANT0("cc", "ProxyMain::SetNeedsAnimate", 301 TRACE_EVENT_INSTANT0("cc", "ProxyMain::SetNeedsAnimate",
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after
466 return false; 460 return false;
467 channel_main_->SetNeedsCommitOnImpl(); 461 channel_main_->SetNeedsCommitOnImpl();
468 return true; 462 return true;
469 } 463 }
470 464
471 bool ProxyMain::IsMainThread() const { 465 bool ProxyMain::IsMainThread() const {
472 return task_runner_provider_->IsMainThread(); 466 return task_runner_provider_->IsMainThread();
473 } 467 }
474 468
475 } // namespace cc 469 } // namespace cc
OLDNEW
« no previous file with comments | « cc/trees/proxy_main.h ('k') | cc/trees/remote_channel_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698