| 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 #include "Benchmark.h" | 8 #include "Benchmark.h" |
| 9 #include "SkCanvas.h" | 9 #include "SkCanvas.h" |
| 10 #include "SkPaint.h" | 10 #include "SkPaint.h" |
| 11 #include "SkPath.h" |
| 11 #include "SkString.h" | 12 #include "SkString.h" |
| 12 | 13 |
| 13 struct BezierRec { | 14 struct BezierRec { |
| 14 SkCanvas* fCanvas; | 15 SkCanvas* fCanvas; |
| 15 SkPaint fPaint; | 16 SkPaint fPaint; |
| 16 SkPath fQuad; | 17 SkPath fQuad; |
| 17 SkPath fCubic; | 18 SkPath fCubic; |
| 18 }; | 19 }; |
| 19 | 20 |
| 20 typedef const char* (*DrawProc)(const BezierRec*, int); | 21 typedef const char* (*DrawProc)(const BezierRec*, int); |
| (...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 92 typedef Benchmark INHERITED; | 93 typedef Benchmark INHERITED; |
| 93 }; | 94 }; |
| 94 | 95 |
| 95 DEF_BENCH( return new BezierBench(SkPaint::kButt_Cap, SkPaint::kRound_Join, 2, d
raw_quad); ) | 96 DEF_BENCH( return new BezierBench(SkPaint::kButt_Cap, SkPaint::kRound_Join, 2, d
raw_quad); ) |
| 96 DEF_BENCH( return new BezierBench(SkPaint::kSquare_Cap, SkPaint::kBevel_Join, 10
, draw_quad); ) | 97 DEF_BENCH( return new BezierBench(SkPaint::kSquare_Cap, SkPaint::kBevel_Join, 10
, draw_quad); ) |
| 97 DEF_BENCH( return new BezierBench(SkPaint::kRound_Cap, SkPaint::kMiter_Join, 50,
draw_quad); ) | 98 DEF_BENCH( return new BezierBench(SkPaint::kRound_Cap, SkPaint::kMiter_Join, 50,
draw_quad); ) |
| 98 | 99 |
| 99 DEF_BENCH( return new BezierBench(SkPaint::kButt_Cap, SkPaint::kRound_Join, 2, d
raw_cubic); ) | 100 DEF_BENCH( return new BezierBench(SkPaint::kButt_Cap, SkPaint::kRound_Join, 2, d
raw_cubic); ) |
| 100 DEF_BENCH( return new BezierBench(SkPaint::kSquare_Cap, SkPaint::kBevel_Join, 10
, draw_cubic); ) | 101 DEF_BENCH( return new BezierBench(SkPaint::kSquare_Cap, SkPaint::kBevel_Join, 10
, draw_cubic); ) |
| 101 DEF_BENCH( return new BezierBench(SkPaint::kRound_Cap, SkPaint::kMiter_Join, 50,
draw_cubic); ) | 102 DEF_BENCH( return new BezierBench(SkPaint::kRound_Cap, SkPaint::kMiter_Join, 50,
draw_cubic); ) |
| OLD | NEW |