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

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

Issue 2822303003: cc : Compute subtree has copy requests before property tree building (Closed)
Patch Set: . Created 3 years, 8 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/draw_property_utils.h" 5 #include "cc/trees/draw_property_utils.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <vector> 9 #include <vector>
10 10
(...skipping 440 matching lines...) Expand 10 before | Expand all | Expand 10 after
451 451
452 template <typename LayerType> 452 template <typename LayerType>
453 static inline bool LayerShouldBeSkippedInternal( 453 static inline bool LayerShouldBeSkippedInternal(
454 LayerType* layer, 454 LayerType* layer,
455 const TransformTree& transform_tree, 455 const TransformTree& transform_tree,
456 const EffectTree& effect_tree) { 456 const EffectTree& effect_tree) {
457 const TransformNode* transform_node = 457 const TransformNode* transform_node =
458 transform_tree.Node(layer->transform_tree_index()); 458 transform_tree.Node(layer->transform_tree_index());
459 const EffectNode* effect_node = effect_tree.Node(layer->effect_tree_index()); 459 const EffectNode* effect_node = effect_tree.Node(layer->effect_tree_index());
460 460
461 if (effect_node->has_render_surface && 461 if (effect_node->has_render_surface && effect_node->subtree_has_copy_request)
weiliangc 2017/04/19 17:58:48 If subtree_has_copy_request is only useful here, w
jaydasika 2017/04/19 18:15:14 I want to stop creating effect nodes for handling
weiliangc 2017/04/19 21:21:54 If we want to avoid sending those layers over, cou
jaydasika 2017/04/19 21:31:36 Yes, that's the plan I have in mind : skip these l
462 effect_node->num_copy_requests_in_subtree > 0)
463 return false; 462 return false;
464 // If the layer transform is not invertible, it should be skipped. 463 // If the layer transform is not invertible, it should be skipped.
465 // TODO(ajuma): Correctly process subtrees with singular transform for the 464 // TODO(ajuma): Correctly process subtrees with singular transform for the
466 // case where we may animate to a non-singular transform and wish to 465 // case where we may animate to a non-singular transform and wish to
467 // pre-raster. 466 // pre-raster.
468 return !transform_node->node_and_ancestors_are_animated_or_invertible || 467 return !transform_node->node_and_ancestors_are_animated_or_invertible ||
469 effect_node->hidden_by_backface_visibility || !effect_node->is_drawn; 468 effect_node->hidden_by_backface_visibility || !effect_node->is_drawn;
470 } 469 }
471 470
472 template <typename LayerType> 471 template <typename LayerType>
(...skipping 616 matching lines...) Expand 10 before | Expand all | Expand 10 after
1089 void UpdateElasticOverscroll(PropertyTrees* property_trees, 1088 void UpdateElasticOverscroll(PropertyTrees* property_trees,
1090 const Layer* overscroll_elasticity_layer, 1089 const Layer* overscroll_elasticity_layer,
1091 const gfx::Vector2dF& elastic_overscroll) { 1090 const gfx::Vector2dF& elastic_overscroll) {
1092 UpdateElasticOverscrollInternal(property_trees, overscroll_elasticity_layer, 1091 UpdateElasticOverscrollInternal(property_trees, overscroll_elasticity_layer,
1093 elastic_overscroll); 1092 elastic_overscroll);
1094 } 1093 }
1095 1094
1096 } // namespace draw_property_utils 1095 } // namespace draw_property_utils
1097 1096
1098 } // namespace cc 1097 } // namespace cc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698