OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2014 Google Inc. | 2 * Copyright 2014 Google Inc. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
6 */ | 6 */ |
7 | 7 |
8 #ifndef SKPBench_DEFINED | 8 #ifndef SKPBench_DEFINED |
9 #define SKPBench_DEFINED | 9 #define SKPBench_DEFINED |
10 | 10 |
11 #include "Benchmark.h" | 11 #include "Benchmark.h" |
12 #include "SkCanvas.h" | 12 #include "SkCanvas.h" |
13 #include "SkPicture.h" | 13 #include "SkPicture.h" |
| 14 #include "SkTDArray.h" |
| 15 |
| 16 class SkSurface; |
14 | 17 |
15 /** | 18 /** |
16 * Runs an SkPicture as a benchmark by repeatedly drawing it scaled inside a dev
ice clip. | 19 * Runs an SkPicture as a benchmark by repeatedly drawing it scaled inside a dev
ice clip. |
17 */ | 20 */ |
18 class SKPBench : public Benchmark { | 21 class SKPBench : public Benchmark { |
19 public: | 22 public: |
20 SKPBench(const char* name, const SkPicture*, const SkIRect& devClip, SkScala
r scale, | 23 SKPBench(const char* name, const SkPicture*, const SkIRect& devClip, SkScala
r scale, |
21 bool useMultiPictureDraw, bool doLooping); | 24 bool useMultiPictureDraw, bool doLooping); |
22 ~SKPBench() override; | 25 ~SKPBench() override; |
23 | 26 |
(...skipping 27 matching lines...) Expand all Loading... |
51 const bool fUseMultiPictureDraw; | 54 const bool fUseMultiPictureDraw; |
52 SkTDArray<SkSurface*> fSurfaces; // for MultiPictureDraw | 55 SkTDArray<SkSurface*> fSurfaces; // for MultiPictureDraw |
53 SkTDArray<SkIRect> fTileRects; // for MultiPictureDraw | 56 SkTDArray<SkIRect> fTileRects; // for MultiPictureDraw |
54 | 57 |
55 const bool fDoLooping; | 58 const bool fDoLooping; |
56 | 59 |
57 typedef Benchmark INHERITED; | 60 typedef Benchmark INHERITED; |
58 }; | 61 }; |
59 | 62 |
60 #endif | 63 #endif |
OLD | NEW |