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

Side by Side Diff: cc/layers/layer_impl.cc

Issue 2851193002: cc: Rename LayerImpl::is_drawn_render_surface_layer_list_member (Closed)
Patch Set: Created 3 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
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 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/layers/layer_impl.h" 5 #include "cc/layers/layer_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 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 user_scrollable_vertical_(true), 59 user_scrollable_vertical_(true),
60 should_flatten_transform_from_property_tree_(false), 60 should_flatten_transform_from_property_tree_(false),
61 layer_property_changed_(false), 61 layer_property_changed_(false),
62 may_contain_video_(false), 62 may_contain_video_(false),
63 masks_to_bounds_(false), 63 masks_to_bounds_(false),
64 contents_opaque_(false), 64 contents_opaque_(false),
65 use_parent_backface_visibility_(false), 65 use_parent_backface_visibility_(false),
66 use_local_transform_for_backface_visibility_(false), 66 use_local_transform_for_backface_visibility_(false),
67 should_check_backface_visibility_(false), 67 should_check_backface_visibility_(false),
68 draws_content_(false), 68 draws_content_(false),
69 is_drawn_render_surface_layer_list_member_(false), 69 contributes_to_drawn_render_surface_(false),
70 was_ever_ready_since_last_transform_animation_(true), 70 was_ever_ready_since_last_transform_animation_(true),
71 background_color_(0), 71 background_color_(0),
72 safe_opaque_background_color_(0), 72 safe_opaque_background_color_(0),
73 transform_tree_index_(TransformTree::kInvalidNodeId), 73 transform_tree_index_(TransformTree::kInvalidNodeId),
74 effect_tree_index_(EffectTree::kInvalidNodeId), 74 effect_tree_index_(EffectTree::kInvalidNodeId),
75 clip_tree_index_(ClipTree::kInvalidNodeId), 75 clip_tree_index_(ClipTree::kInvalidNodeId),
76 scroll_tree_index_(ScrollTree::kInvalidNodeId), 76 scroll_tree_index_(ScrollTree::kInvalidNodeId),
77 current_draw_mode_(DRAW_MODE_NONE), 77 current_draw_mode_(DRAW_MODE_NONE),
78 mutable_properties_(MutableProperty::kNone), 78 mutable_properties_(MutableProperty::kNone),
79 debug_info_(nullptr), 79 debug_info_(nullptr),
(...skipping 778 matching lines...) Expand 10 before | Expand all | Expand 10 after
858 } 858 }
859 859
860 size_t LayerImpl::GPUMemoryUsageInBytes() const { return 0; } 860 size_t LayerImpl::GPUMemoryUsageInBytes() const { return 0; }
861 861
862 void LayerImpl::RunMicroBenchmark(MicroBenchmarkImpl* benchmark) { 862 void LayerImpl::RunMicroBenchmark(MicroBenchmarkImpl* benchmark) {
863 benchmark->RunOnLayer(this); 863 benchmark->RunOnLayer(this);
864 } 864 }
865 865
866 gfx::Transform LayerImpl::DrawTransform() const { 866 gfx::Transform LayerImpl::DrawTransform() const {
867 // Only drawn layers have up-to-date draw properties. 867 // Only drawn layers have up-to-date draw properties.
868 if (!is_drawn_render_surface_layer_list_member()) { 868 if (!contributes_to_drawn_render_surface()) {
869 if (GetPropertyTrees()->non_root_surfaces_enabled) { 869 if (GetPropertyTrees()->non_root_surfaces_enabled) {
870 return draw_property_utils::DrawTransform(this, GetTransformTree(), 870 return draw_property_utils::DrawTransform(this, GetTransformTree(),
871 GetEffectTree()); 871 GetEffectTree());
872 } else { 872 } else {
873 return draw_property_utils::ScreenSpaceTransform(this, 873 return draw_property_utils::ScreenSpaceTransform(this,
874 GetTransformTree()); 874 GetTransformTree());
875 } 875 }
876 } 876 }
877 877
878 return draw_properties().target_space_transform; 878 return draw_properties().target_space_transform;
879 } 879 }
880 880
881 gfx::Transform LayerImpl::ScreenSpaceTransform() const { 881 gfx::Transform LayerImpl::ScreenSpaceTransform() const {
882 // Only drawn layers have up-to-date draw properties. 882 // Only drawn layers have up-to-date draw properties.
883 if (!is_drawn_render_surface_layer_list_member()) { 883 if (!contributes_to_drawn_render_surface()) {
884 return draw_property_utils::ScreenSpaceTransform(this, GetTransformTree()); 884 return draw_property_utils::ScreenSpaceTransform(this, GetTransformTree());
885 } 885 }
886 886
887 return draw_properties().screen_space_transform; 887 return draw_properties().screen_space_transform;
888 } 888 }
889 889
890 bool LayerImpl::CanUseLCDText() const { 890 bool LayerImpl::CanUseLCDText() const {
891 if (layer_tree_impl()->settings().layers_always_allowed_lcd_text) 891 if (layer_tree_impl()->settings().layers_always_allowed_lcd_text)
892 return true; 892 return true;
893 if (!layer_tree_impl()->settings().can_use_lcd_text) 893 if (!layer_tree_impl()->settings().can_use_lcd_text)
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
979 979
980 ScrollTree& LayerImpl::GetScrollTree() const { 980 ScrollTree& LayerImpl::GetScrollTree() const {
981 return GetPropertyTrees()->scroll_tree; 981 return GetPropertyTrees()->scroll_tree;
982 } 982 }
983 983
984 TransformTree& LayerImpl::GetTransformTree() const { 984 TransformTree& LayerImpl::GetTransformTree() const {
985 return GetPropertyTrees()->transform_tree; 985 return GetPropertyTrees()->transform_tree;
986 } 986 }
987 987
988 } // namespace cc 988 } // namespace cc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698