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

Side by Side Diff: cc/playback/display_item.h

Issue 1423653005: Further plumb visual rect into cc:DisplayItemList. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix clip recorder params in omnibox. Created 5 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
« no previous file with comments | « cc/playback/compositing_display_item.cc ('k') | cc/playback/display_item_list.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 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 #ifndef CC_PLAYBACK_DISPLAY_ITEM_H_ 5 #ifndef CC_PLAYBACK_DISPLAY_ITEM_H_
6 #define CC_PLAYBACK_DISPLAY_ITEM_H_ 6 #define CC_PLAYBACK_DISPLAY_ITEM_H_
7 7
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "cc/base/cc_export.h" 9 #include "cc/base/cc_export.h"
10 #include "cc/debug/traced_value.h" 10 #include "cc/debug/traced_value.h"
(...skipping 18 matching lines...) Expand all
29 is_suitable_for_gpu_rasterization_ = is_suitable_for_gpu_rasterization; 29 is_suitable_for_gpu_rasterization_ = is_suitable_for_gpu_rasterization;
30 approximate_op_count_ = approximate_op_count; 30 approximate_op_count_ = approximate_op_count;
31 external_memory_usage_ = external_memory_usage; 31 external_memory_usage_ = external_memory_usage;
32 } 32 }
33 33
34 virtual void ToProtobuf(proto::DisplayItem* proto) const = 0; 34 virtual void ToProtobuf(proto::DisplayItem* proto) const = 0;
35 virtual void FromProtobuf(const proto::DisplayItem& proto) = 0; 35 virtual void FromProtobuf(const proto::DisplayItem& proto) = 0;
36 virtual void Raster(SkCanvas* canvas, 36 virtual void Raster(SkCanvas* canvas,
37 const gfx::Rect& canvas_target_playback_rect, 37 const gfx::Rect& canvas_target_playback_rect,
38 SkPicture::AbortCallback* callback) const = 0; 38 SkPicture::AbortCallback* callback) const = 0;
39 virtual void AsValueInto(base::trace_event::TracedValue* array) const = 0; 39 virtual void AsValueInto(const gfx::Rect& visual_rect,
40 base::trace_event::TracedValue* array) const = 0;
40 41
41 bool is_suitable_for_gpu_rasterization() const { 42 bool is_suitable_for_gpu_rasterization() const {
42 return is_suitable_for_gpu_rasterization_; 43 return is_suitable_for_gpu_rasterization_;
43 } 44 }
44 int approximate_op_count() const { return approximate_op_count_; } 45 int approximate_op_count() const { return approximate_op_count_; }
45 size_t external_memory_usage() const { return external_memory_usage_; } 46 size_t external_memory_usage() const { return external_memory_usage_; }
46 47
47 protected: 48 protected:
48 DisplayItem(); 49 DisplayItem();
49 50
50 bool is_suitable_for_gpu_rasterization_; 51 bool is_suitable_for_gpu_rasterization_;
51 int approximate_op_count_; 52 int approximate_op_count_;
52 53
53 // The size, in bytes, of the memory owned by this display item but not 54 // The size, in bytes, of the memory owned by this display item but not
54 // allocated within it (e.g. held through scoped_ptr or vector). 55 // allocated within it (e.g. held through scoped_ptr or vector).
55 size_t external_memory_usage_; 56 size_t external_memory_usage_;
56 }; 57 };
57 58
58 } // namespace cc 59 } // namespace cc
59 60
60 #endif // CC_PLAYBACK_DISPLAY_ITEM_H_ 61 #endif // CC_PLAYBACK_DISPLAY_ITEM_H_
OLDNEW
« no previous file with comments | « cc/playback/compositing_display_item.cc ('k') | cc/playback/display_item_list.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698