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

Side by Side Diff: cc/resources/picture.h

Issue 25353009: telemetry: Refactored rasterize_and_record measurement. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Made BenchmarkInstrumentation a class. Created 7 years, 2 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/picture_layer.cc ('k') | cc/resources/picture.cc » ('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 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 #ifndef CC_RESOURCES_PICTURE_H_ 5 #ifndef CC_RESOURCES_PICTURE_H_
6 #define CC_RESOURCES_PICTURE_H_ 6 #define CC_RESOURCES_PICTURE_H_
7 7
8 #include <string> 8 #include <string>
9 #include <utility> 9 #include <utility>
10 #include <vector> 10 #include <vector>
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
61 void Record(ContentLayerClient* client, 61 void Record(ContentLayerClient* client,
62 const SkTileGridPicture::TileGridInfo& tile_grid_info); 62 const SkTileGridPicture::TileGridInfo& tile_grid_info);
63 63
64 // Gather pixel refs from recording. 64 // Gather pixel refs from recording.
65 void GatherPixelRefs(const SkTileGridPicture::TileGridInfo& tile_grid_info); 65 void GatherPixelRefs(const SkTileGridPicture::TileGridInfo& tile_grid_info);
66 66
67 // Has Record() been called yet? 67 // Has Record() been called yet?
68 bool HasRecording() const { return picture_.get() != NULL; } 68 bool HasRecording() const { return picture_.get() != NULL; }
69 69
70 // Apply this contents scale and raster the content rect into the canvas. 70 // Apply this contents scale and raster the content rect into the canvas.
71 void Raster(SkCanvas* canvas, 71 int Raster(SkCanvas* canvas,
72 SkDrawPictureCallback* callback, 72 SkDrawPictureCallback* callback,
73 gfx::Rect content_rect, 73 gfx::Rect content_rect,
74 float contents_scale); 74 float contents_scale);
75 75
76 // Draw the picture directly into the given canvas, without applying any 76 // Draw the picture directly into the given canvas, without applying any
77 // clip/scale/layer transformations. 77 // clip/scale/layer transformations.
78 void Replay(SkCanvas* canvas); 78 void Replay(SkCanvas* canvas);
79 79
80 scoped_ptr<base::Value> AsValue() const; 80 scoped_ptr<base::Value> AsValue() const;
81 81
82 class CC_EXPORT PixelRefIterator { 82 class CC_EXPORT PixelRefIterator {
83 public: 83 public:
84 PixelRefIterator(); 84 PixelRefIterator();
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
147 AsTraceableRecordData() const; 147 AsTraceableRecordData() const;
148 148
149 friend class base::RefCountedThreadSafe<Picture>; 149 friend class base::RefCountedThreadSafe<Picture>;
150 friend class PixelRefIterator; 150 friend class PixelRefIterator;
151 DISALLOW_COPY_AND_ASSIGN(Picture); 151 DISALLOW_COPY_AND_ASSIGN(Picture);
152 }; 152 };
153 153
154 } // namespace cc 154 } // namespace cc
155 155
156 #endif // CC_RESOURCES_PICTURE_H_ 156 #endif // CC_RESOURCES_PICTURE_H_
OLDNEW
« no previous file with comments | « cc/layers/picture_layer.cc ('k') | cc/resources/picture.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698