OLD | NEW |
1 | 1 |
2 /* | 2 /* |
3 * Copyright 2011 Google Inc. | 3 * Copyright 2011 Google Inc. |
4 * | 4 * |
5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
7 */ | 7 */ |
8 | 8 |
9 #if SK_SUPPORT_GPU | 9 #if SK_SUPPORT_GPU |
10 #include "GrContext.h" | 10 #include "GrContext.h" |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
50 } | 50 } |
51 | 51 |
52 class Iter { | 52 class Iter { |
53 public: | 53 public: |
54 Iter() : fBench(BenchRegistry::Head()) {} | 54 Iter() : fBench(BenchRegistry::Head()) {} |
55 | 55 |
56 SkBenchmark* next() { | 56 SkBenchmark* next() { |
57 if (fBench) { | 57 if (fBench) { |
58 BenchRegistry::Factory f = fBench->factory(); | 58 BenchRegistry::Factory f = fBench->factory(); |
59 fBench = fBench->next(); | 59 fBench = fBench->next(); |
60 return f(NULL); | 60 return f(); |
61 } | 61 } |
62 return NULL; | 62 return NULL; |
63 } | 63 } |
64 | 64 |
65 private: | 65 private: |
66 const BenchRegistry* fBench; | 66 const BenchRegistry* fBench; |
67 }; | 67 }; |
68 | 68 |
69 class AutoPrePostDraw { | 69 class AutoPrePostDraw { |
70 public: | 70 public: |
(...skipping 557 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
628 gContextFactory.destroyContexts(); | 628 gContextFactory.destroyContexts(); |
629 #endif | 629 #endif |
630 return 0; | 630 return 0; |
631 } | 631 } |
632 | 632 |
633 #if !defined(SK_BUILD_FOR_IOS) && !defined(SK_BUILD_FOR_NACL) | 633 #if !defined(SK_BUILD_FOR_IOS) && !defined(SK_BUILD_FOR_NACL) |
634 int main(int argc, char * const argv[]) { | 634 int main(int argc, char * const argv[]) { |
635 return tool_main(argc, (char**) argv); | 635 return tool_main(argc, (char**) argv); |
636 } | 636 } |
637 #endif | 637 #endif |
OLD | NEW |