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

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

Issue 1387003002: cc: Make property trees support resourceless draw mode (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@DontReparentUnclippedClipNodes
Patch Set: Created 5 years, 2 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_host.h" 5 #include "cc/trees/layer_tree_host.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <stack> 8 #include <stack>
9 #include <string> 9 #include <string>
10 10
(...skipping 764 matching lines...) Expand 10 before | Expand all | Expand 10 after
775 LayerTreeHostCommon::UpdateRenderSurfaces( 775 LayerTreeHostCommon::UpdateRenderSurfaces(
776 root_layer, can_render_to_separate_surface, identity_transform, 776 root_layer, can_render_to_separate_surface, identity_transform,
777 preserves_2d_axis_alignment); 777 preserves_2d_axis_alignment);
778 { 778 {
779 TRACE_EVENT0(TRACE_DISABLED_BY_DEFAULT("cc.debug.cdp-perf"), 779 TRACE_EVENT0(TRACE_DISABLED_BY_DEFAULT("cc.debug.cdp-perf"),
780 "LayerTreeHostCommon::ComputeVisibleRectsWithPropertyTrees"); 780 "LayerTreeHostCommon::ComputeVisibleRectsWithPropertyTrees");
781 BuildPropertyTreesAndComputeVisibleRects( 781 BuildPropertyTreesAndComputeVisibleRects(
782 root_layer, page_scale_layer, inner_viewport_scroll_layer_.get(), 782 root_layer, page_scale_layer, inner_viewport_scroll_layer_.get(),
783 outer_viewport_scroll_layer_.get(), page_scale_factor_, 783 outer_viewport_scroll_layer_.get(), page_scale_factor_,
784 device_scale_factor_, gfx::Rect(device_viewport_size_), 784 device_scale_factor_, gfx::Rect(device_viewport_size_),
785 identity_transform, &property_trees_, &update_layer_list); 785 identity_transform, can_render_to_separate_surface, &property_trees_,
786 &update_layer_list);
786 } 787 }
787 788
788 for (const auto& layer : update_layer_list) 789 for (const auto& layer : update_layer_list)
789 layer->SavePaintProperties(); 790 layer->SavePaintProperties();
790 791
791 base::AutoReset<bool> painting(&in_paint_layer_contents_, true); 792 base::AutoReset<bool> painting(&in_paint_layer_contents_, true);
792 bool did_paint_content = false; 793 bool did_paint_content = false;
793 for (const auto& layer : update_layer_list) { 794 for (const auto& layer : update_layer_list) {
794 did_paint_content |= layer->Update(); 795 did_paint_content |= layer->Update();
795 content_is_suitable_for_gpu_rasterization_ &= 796 content_is_suitable_for_gpu_rasterization_ &=
(...skipping 427 matching lines...) Expand 10 before | Expand all | Expand 10 after
1223 return animation_host_ ? animation_host_->HasAnyAnimation(layer->id()) 1224 return animation_host_ ? animation_host_->HasAnyAnimation(layer->id())
1224 : false; 1225 : false;
1225 } 1226 }
1226 1227
1227 bool LayerTreeHost::HasActiveAnimation(const Layer* layer) const { 1228 bool LayerTreeHost::HasActiveAnimation(const Layer* layer) const {
1228 return animation_host_ ? animation_host_->HasActiveAnimation(layer->id()) 1229 return animation_host_ ? animation_host_->HasActiveAnimation(layer->id())
1229 : false; 1230 : false;
1230 } 1231 }
1231 1232
1232 } // namespace cc 1233 } // namespace cc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698