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

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

Issue 135493002: Plumb debug name via debug info (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 11 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 | Annotate | Revision Log
« no previous file with comments | « cc/layers/render_surface_impl.h ('k') | ui/compositor/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/layers/render_surface_impl.h" 5 #include "cc/layers/render_surface_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/strings/stringprintf.h" 10 #include "base/strings/stringprintf.h"
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
46 gfx::RectF drawable_content_rect = 46 gfx::RectF drawable_content_rect =
47 MathUtil::MapClippedRect(draw_transform_, content_rect_); 47 MathUtil::MapClippedRect(draw_transform_, content_rect_);
48 if (owning_layer_->has_replica()) { 48 if (owning_layer_->has_replica()) {
49 drawable_content_rect.Union( 49 drawable_content_rect.Union(
50 MathUtil::MapClippedRect(replica_draw_transform_, content_rect_)); 50 MathUtil::MapClippedRect(replica_draw_transform_, content_rect_));
51 } 51 }
52 52
53 return drawable_content_rect; 53 return drawable_content_rect;
54 } 54 }
55 55
56 std::string RenderSurfaceImpl::Name() const {
57 return base::StringPrintf("RenderSurfaceImpl(id=%i,owner=%s)",
58 owning_layer_->id(),
59 owning_layer_->debug_name().data());
60 }
61
62 int RenderSurfaceImpl::OwningLayerId() const { 56 int RenderSurfaceImpl::OwningLayerId() const {
63 return owning_layer_ ? owning_layer_->id() : 0; 57 return owning_layer_ ? owning_layer_->id() : 0;
64 } 58 }
65 59
66 60
67 void RenderSurfaceImpl::SetClipRect(const gfx::Rect& clip_rect) { 61 void RenderSurfaceImpl::SetClipRect(const gfx::Rect& clip_rect) {
68 if (clip_rect_ == clip_rect) 62 if (clip_rect_ == clip_rect)
69 return; 63 return;
70 64
71 surface_property_changed_ = true; 65 surface_property_changed_ = true;
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
227 for_replica, 221 for_replica,
228 mask_resource_id, 222 mask_resource_id,
229 contents_changed_since_last_frame, 223 contents_changed_since_last_frame,
230 mask_uv_rect, 224 mask_uv_rect,
231 owning_layer_->filters(), 225 owning_layer_->filters(),
232 owning_layer_->background_filters()); 226 owning_layer_->background_filters());
233 quad_sink->Append(quad.PassAs<DrawQuad>(), append_quads_data); 227 quad_sink->Append(quad.PassAs<DrawQuad>(), append_quads_data);
234 } 228 }
235 229
236 } // namespace cc 230 } // namespace cc
OLDNEW
« no previous file with comments | « cc/layers/render_surface_impl.h ('k') | ui/compositor/layer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698