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

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

Issue 2698793002: cc: Enable use of render surfaces for Android WebView (Closed)
Patch Set: softwaredraw-allow-surfaces: todo-bug Created 3 years, 10 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
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/trees/layer_tree_impl.h" 5 #include "cc/trees/layer_tree_impl.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 969 matching lines...) Expand 10 before | Expand all | Expand 10 after
980 render_surface_layer_list_.clear(); 980 render_surface_layer_list_.clear();
981 981
982 if (layer_list_.empty()) 982 if (layer_list_.empty())
983 return false; 983 return false;
984 984
985 { 985 {
986 base::ElapsedTimer timer; 986 base::ElapsedTimer timer;
987 TRACE_EVENT2( 987 TRACE_EVENT2(
988 "cc", "LayerTreeImpl::UpdateDrawProperties::CalculateDrawProperties", 988 "cc", "LayerTreeImpl::UpdateDrawProperties::CalculateDrawProperties",
989 "IsActive", IsActiveTree(), "SourceFrameNumber", source_frame_number_); 989 "IsActive", IsActiveTree(), "SourceFrameNumber", source_frame_number_);
990 bool can_render_to_separate_surface = 990 // TODO(crbug.com/692780): Remove this option entirely once this get to
991 (!is_in_resourceless_software_draw_mode()); 991 // stable and proves it works.
992 bool can_render_to_separate_surface = true;
992 993
993 // We verify visible rect calculations whenever we verify clip tree 994 // We verify visible rect calculations whenever we verify clip tree
994 // calculations except when this function is explicitly passed a flag asking 995 // calculations except when this function is explicitly passed a flag asking
995 // us to skip it. 996 // us to skip it.
996 bool verify_visible_rect_calculations = 997 bool verify_visible_rect_calculations =
997 force_skip_verify_visible_rect_calculations 998 force_skip_verify_visible_rect_calculations
998 ? false 999 ? false
999 : settings().verify_clip_tree_calculations; 1000 : settings().verify_clip_tree_calculations;
1000 LayerTreeHostCommon::CalcDrawPropsImplInputs inputs( 1001 LayerTreeHostCommon::CalcDrawPropsImplInputs inputs(
1001 layer_list_[0], DrawViewportSize(), 1002 layer_list_[0], DrawViewportSize(),
(...skipping 1091 matching lines...) Expand 10 before | Expand all | Expand 10 after
2093 2094
2094 void LayerTreeImpl::ResetAllChangeTracking() { 2095 void LayerTreeImpl::ResetAllChangeTracking() {
2095 layers_that_should_push_properties_.clear(); 2096 layers_that_should_push_properties_.clear();
2096 // Iterate over all layers, including masks. 2097 // Iterate over all layers, including masks.
2097 for (auto& layer : *layers_) 2098 for (auto& layer : *layers_)
2098 layer->ResetChangeTracking(); 2099 layer->ResetChangeTracking();
2099 property_trees_.ResetAllChangeTracking(); 2100 property_trees_.ResetAllChangeTracking();
2100 } 2101 }
2101 2102
2102 } // namespace cc 2103 } // namespace cc
OLDNEW
« no previous file with comments | « cc/trees/layer_tree_host_unittest.cc ('k') | content/renderer/android/synchronous_compositor_frame_sink.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698