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

Side by Side Diff: content/renderer/gpu/render_widget_compositor.cc

Issue 290563005: Do SetNeedsCommit() instead of Composite() in threaded mode. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: composite: . Created 6 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 | Annotate | Revision Log
« no previous file with comments | « content/renderer/gpu/render_widget_compositor.h ('k') | ui/compositor/compositor.cc » ('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 (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 "content/renderer/gpu/render_widget_compositor.h" 5 #include "content/renderer/gpu/render_widget_compositor.h"
6 6
7 #include <limits> 7 #include <limits>
8 #include <string> 8 #include <string>
9 9
10 #if defined(OS_ANDROID) 10 #if defined(OS_ANDROID)
(...skipping 337 matching lines...) Expand 10 before | Expand all | Expand 10 after
348 } 348 }
349 349
350 bool RenderWidgetCompositor::BeginMainFrameRequested() const { 350 bool RenderWidgetCompositor::BeginMainFrameRequested() const {
351 return layer_tree_host_->BeginMainFrameRequested(); 351 return layer_tree_host_->BeginMainFrameRequested();
352 } 352 }
353 353
354 void RenderWidgetCompositor::UpdateAnimations(base::TimeTicks time) { 354 void RenderWidgetCompositor::UpdateAnimations(base::TimeTicks time) {
355 layer_tree_host_->UpdateClientAnimations(time); 355 layer_tree_host_->UpdateClientAnimations(time);
356 } 356 }
357 357
358 void RenderWidgetCompositor::Composite(base::TimeTicks frame_begin_time) {
359 layer_tree_host_->Composite(frame_begin_time);
360 }
361
362 void RenderWidgetCompositor::SetNeedsDisplayOnAllLayers() { 358 void RenderWidgetCompositor::SetNeedsDisplayOnAllLayers() {
363 layer_tree_host_->SetNeedsDisplayOnAllLayers(); 359 layer_tree_host_->SetNeedsDisplayOnAllLayers();
364 } 360 }
365 361
366 void RenderWidgetCompositor::SetRasterizeOnlyVisibleContent() { 362 void RenderWidgetCompositor::SetRasterizeOnlyVisibleContent() {
367 cc::LayerTreeDebugState current = layer_tree_host_->debug_state(); 363 cc::LayerTreeDebugState current = layer_tree_host_->debug_state();
368 current.rasterize_only_visible_content = true; 364 current.rasterize_only_visible_content = true;
369 layer_tree_host_->SetDebugState(current); 365 layer_tree_host_->SetDebugState(current);
370 } 366 }
371 367
(...skipping 320 matching lines...) Expand 10 before | Expand all | Expand 10 after
692 widget_->OnSwapBuffersAborted(); 688 widget_->OnSwapBuffersAborted();
693 } 689 }
694 690
695 void RenderWidgetCompositor::RateLimitSharedMainThreadContext() { 691 void RenderWidgetCompositor::RateLimitSharedMainThreadContext() {
696 cc::ContextProvider* provider = 692 cc::ContextProvider* provider =
697 RenderThreadImpl::current()->SharedMainThreadContextProvider().get(); 693 RenderThreadImpl::current()->SharedMainThreadContextProvider().get();
698 provider->ContextGL()->RateLimitOffscreenContextCHROMIUM(); 694 provider->ContextGL()->RateLimitOffscreenContextCHROMIUM();
699 } 695 }
700 696
701 } // namespace content 697 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/gpu/render_widget_compositor.h ('k') | ui/compositor/compositor.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698