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

Side by Side Diff: cc/layer_tree_impl.cc

Issue 11639050: cc: Support mask layers in impl-side painting (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years 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 | Annotate | Revision Log
« no previous file with comments | « cc/layer_tree_impl.h ('k') | cc/picture_layer.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 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/layer_tree_impl.h" 5 #include "cc/layer_tree_impl.h"
6 6
7 #include "base/debug/trace_event.h" 7 #include "base/debug/trace_event.h"
8 #include "cc/layer_tree_host_common.h" 8 #include "cc/layer_tree_host_common.h"
9 #include "cc/layer_tree_host_impl.h" 9 #include "cc/layer_tree_host_impl.h"
10 #include "ui/gfx/vector2d_conversions.h" 10 #include "ui/gfx/vector2d_conversions.h"
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
119 layer_tree_host_impl_->implTransform()); 119 layer_tree_host_impl_->implTransform());
120 } 120 }
121 121
122 { 122 {
123 TRACE_EVENT0("cc", "LayerTreeImpl::UpdateDrawProperties"); 123 TRACE_EVENT0("cc", "LayerTreeImpl::UpdateDrawProperties");
124 LayerTreeHostCommon::calculateDrawProperties( 124 LayerTreeHostCommon::calculateDrawProperties(
125 RootLayer(), 125 RootLayer(),
126 device_viewport_size(), 126 device_viewport_size(),
127 device_scale_factor(), 127 device_scale_factor(),
128 pinch_zoom_viewport().pageScaleFactor(), 128 pinch_zoom_viewport().pageScaleFactor(),
129 layer_tree_host_impl_->rendererCapabilities().maxTextureSize, 129 MaxTextureSize(),
130 settings().canUseLCDText, 130 settings().canUseLCDText,
131 render_surface_layer_list_); 131 render_surface_layer_list_);
132 } 132 }
133 } 133 }
134 134
135 static void ClearRenderSurfacesOnLayerImplRecursive(LayerImpl* current) 135 static void ClearRenderSurfacesOnLayerImplRecursive(LayerImpl* current)
136 { 136 {
137 DCHECK(current); 137 DCHECK(current);
138 for (size_t i = 0; i < current->children().size(); ++i) 138 for (size_t i = 0; i < current->children().size(); ++i)
139 ClearRenderSurfacesOnLayerImplRecursive(current->children()[i]); 139 ClearRenderSurfacesOnLayerImplRecursive(current->children()[i]);
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
210 return tree->LayerById(id); 210 return tree->LayerById(id);
211 } 211 }
212 212
213 LayerImpl* LayerTreeImpl::FindPendingTreeLayerById(int id) { 213 LayerImpl* LayerTreeImpl::FindPendingTreeLayerById(int id) {
214 LayerTreeImpl* tree = layer_tree_host_impl_->pendingTree(); 214 LayerTreeImpl* tree = layer_tree_host_impl_->pendingTree();
215 if (!tree) 215 if (!tree)
216 return NULL; 216 return NULL;
217 return tree->LayerById(id); 217 return tree->LayerById(id);
218 } 218 }
219 219
220 int LayerTreeImpl::MaxTextureSize() const {
221 return layer_tree_host_impl_->rendererCapabilities().maxTextureSize;
222 }
223
220 void LayerTreeImpl::SetNeedsRedraw() { 224 void LayerTreeImpl::SetNeedsRedraw() {
221 layer_tree_host_impl_->setNeedsRedraw(); 225 layer_tree_host_impl_->setNeedsRedraw();
222 } 226 }
223 227
224 void LayerTreeImpl::SetNeedsUpdateDrawProperties() { 228 void LayerTreeImpl::SetNeedsUpdateDrawProperties() {
225 layer_tree_host_impl_->setNeedsUpdateDrawProperties(); 229 layer_tree_host_impl_->setNeedsUpdateDrawProperties();
226 } 230 }
227 231
228 const LayerTreeDebugState& LayerTreeImpl::debug_state() const { 232 const LayerTreeDebugState& LayerTreeImpl::debug_state() const {
229 return layer_tree_host_impl_->debugState(); 233 return layer_tree_host_impl_->debugState();
(...skipping 21 matching lines...) Expand all
251 255
252 AnimationRegistrar* LayerTreeImpl::animationRegistrar() const { 256 AnimationRegistrar* LayerTreeImpl::animationRegistrar() const {
253 return layer_tree_host_impl_->animationRegistrar(); 257 return layer_tree_host_impl_->animationRegistrar();
254 } 258 }
255 259
256 const PinchZoomViewport& LayerTreeImpl::pinch_zoom_viewport() const { 260 const PinchZoomViewport& LayerTreeImpl::pinch_zoom_viewport() const {
257 return layer_tree_host_impl_->pinchZoomViewport(); 261 return layer_tree_host_impl_->pinchZoomViewport();
258 } 262 }
259 263
260 } // namespace cc 264 } // namespace cc
OLDNEW
« no previous file with comments | « cc/layer_tree_impl.h ('k') | cc/picture_layer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698