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

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

Issue 2184773002: cc: Move blend_mode to the effect tree (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 4 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
« no previous file with comments | « cc/layers/layer.h ('k') | cc/layers/layer_impl.h » ('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 2010 The Chromium Authors. All rights reserved. 1 // Copyright 2010 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.h" 5 #include "cc/layers/layer.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 1141 matching lines...) Expand 10 before | Expand all | Expand 10 after
1152 // subtree_property_changed_ is propagated to all descendants while building 1152 // subtree_property_changed_ is propagated to all descendants while building
1153 // property trees. So, it is enough to check it only for the current layer. 1153 // property trees. So, it is enough to check it only for the current layer.
1154 if (subtree_property_changed_ || layer_property_changed_) 1154 if (subtree_property_changed_ || layer_property_changed_)
1155 layer->NoteLayerPropertyChanged(); 1155 layer->NoteLayerPropertyChanged();
1156 layer->SetMasksToBounds(inputs_.masks_to_bounds); 1156 layer->SetMasksToBounds(inputs_.masks_to_bounds);
1157 layer->set_main_thread_scrolling_reasons( 1157 layer->set_main_thread_scrolling_reasons(
1158 inputs_.main_thread_scrolling_reasons); 1158 inputs_.main_thread_scrolling_reasons);
1159 layer->SetNonFastScrollableRegion(inputs_.non_fast_scrollable_region); 1159 layer->SetNonFastScrollableRegion(inputs_.non_fast_scrollable_region);
1160 layer->SetTouchEventHandlerRegion(inputs_.touch_event_handler_region); 1160 layer->SetTouchEventHandlerRegion(inputs_.touch_event_handler_region);
1161 layer->SetContentsOpaque(inputs_.contents_opaque); 1161 layer->SetContentsOpaque(inputs_.contents_opaque);
1162 layer->SetBlendMode(inputs_.blend_mode);
1163 layer->SetPosition(inputs_.position); 1162 layer->SetPosition(inputs_.position);
1164 layer->set_should_flatten_transform_from_property_tree( 1163 layer->set_should_flatten_transform_from_property_tree(
1165 should_flatten_transform_from_property_tree_); 1164 should_flatten_transform_from_property_tree_);
1166 layer->set_draw_blend_mode(draw_blend_mode_); 1165 layer->set_draw_blend_mode(draw_blend_mode_);
1167 layer->SetUseParentBackfaceVisibility(inputs_.use_parent_backface_visibility); 1166 layer->SetUseParentBackfaceVisibility(inputs_.use_parent_backface_visibility);
1168 layer->SetUseLocalTransformForBackfaceVisibility( 1167 layer->SetUseLocalTransformForBackfaceVisibility(
1169 use_local_transform_for_backface_visibility_); 1168 use_local_transform_for_backface_visibility_);
1170 layer->SetShouldCheckBackfaceVisibility(should_check_backface_visibility_); 1169 layer->SetShouldCheckBackfaceVisibility(should_check_backface_visibility_);
1171 if (!TransformIsAnimating()) 1170 if (!TransformIsAnimating())
1172 layer->SetTransform(inputs_.transform); 1171 layer->SetTransform(inputs_.transform);
(...skipping 698 matching lines...) Expand 10 before | Expand all | Expand 10 after
1871 ->num_copy_requests_in_subtree; 1870 ->num_copy_requests_in_subtree;
1872 } 1871 }
1873 1872
1874 gfx::Transform Layer::screen_space_transform() const { 1873 gfx::Transform Layer::screen_space_transform() const {
1875 DCHECK_NE(transform_tree_index_, -1); 1874 DCHECK_NE(transform_tree_index_, -1);
1876 return draw_property_utils::ScreenSpaceTransform( 1875 return draw_property_utils::ScreenSpaceTransform(
1877 this, layer_tree_host_->property_trees()->transform_tree); 1876 this, layer_tree_host_->property_trees()->transform_tree);
1878 } 1877 }
1879 1878
1880 } // namespace cc 1879 } // namespace cc
OLDNEW
« no previous file with comments | « cc/layers/layer.h ('k') | cc/layers/layer_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698