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

Side by Side Diff: skia/ext/benchmarking_canvas.h

Issue 664803003: Update from chromium a8e7c94b1b79a0948d05a1fcfff53391d22ce37a (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 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 | « skia/ext/analysis_canvas.h ('k') | skia/ext/benchmarking_canvas.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 (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 SKIA_EXT_BENCHMARKING_CANVAS_H_ 5 #ifndef SKIA_EXT_BENCHMARKING_CANVAS_H_
6 #define SKIA_EXT_BENCHMARKING_CANVAS_H_ 6 #define SKIA_EXT_BENCHMARKING_CANVAS_H_
7 7
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "skia/ext/refptr.h" 9 #include "skia/ext/refptr.h"
10 #include "third_party/skia/include/utils/SkNWayCanvas.h" 10 #include "third_party/skia/include/utils/SkNWayCanvas.h"
11 #include "third_party/skia/src/utils/debugger/SkDebugCanvas.h" 11 #include "third_party/skia/src/utils/debugger/SkDebugCanvas.h"
12 12
13 namespace skia { 13 namespace skia {
14 14
15 class TimingCanvas; 15 class TimingCanvas;
16 16
17 class SK_API BenchmarkingCanvas : public SkNWayCanvas { 17 class SK_API BenchmarkingCanvas : public SkNWayCanvas {
18 public: 18 public:
19 BenchmarkingCanvas(int width, int height); 19 BenchmarkingCanvas(int width, int height);
20 virtual ~BenchmarkingCanvas(); 20 ~BenchmarkingCanvas() override;
21 21
22 // Returns the number of draw commands executed on this canvas. 22 // Returns the number of draw commands executed on this canvas.
23 size_t CommandCount() const; 23 size_t CommandCount() const;
24 24
25 // Get draw command info for a given index. 25 // Get draw command info for a given index.
26 SkDrawCommand* GetCommand(size_t index); 26 SkDrawCommand* GetCommand(size_t index);
27 27
28 // Return the recorded render time (milliseconds) for a draw command index. 28 // Return the recorded render time (milliseconds) for a draw command index.
29 double GetTime(size_t index); 29 double GetTime(size_t index);
30 30
(...skipping 10 matching lines...) Expand all
41 // updating content::SkiaTimingCanvas to accurately override all new methods 41 // updating content::SkiaTimingCanvas to accurately override all new methods
42 // (to avoid timing info indices from getting out of sync), as SkDebugCanvas 42 // (to avoid timing info indices from getting out of sync), as SkDebugCanvas
43 // already does that for us. 43 // already does that for us.
44 44
45 skia::RefPtr<SkDebugCanvas> debug_canvas_; 45 skia::RefPtr<SkDebugCanvas> debug_canvas_;
46 skia::RefPtr<TimingCanvas> timing_canvas_; 46 skia::RefPtr<TimingCanvas> timing_canvas_;
47 }; 47 };
48 48
49 } 49 }
50 #endif // SKIA_EXT_BENCHMARKING_CANVAS_H 50 #endif // SKIA_EXT_BENCHMARKING_CANVAS_H
OLDNEW
« no previous file with comments | « skia/ext/analysis_canvas.h ('k') | skia/ext/benchmarking_canvas.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698