| 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 <ctype.h> | 8 #include <ctype.h> |
| 9 | 9 |
| 10 #include "nanobench.h" | 10 #include "nanobench.h" |
| (...skipping 396 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 407 SkDebugf("Configuration sample count %d exceeds maximum %d.\n", | 407 SkDebugf("Configuration sample count %d exceeds maximum %d.\n", |
| 408 sampleCount, maxSampleCount); | 408 sampleCount, maxSampleCount); |
| 409 return; | 409 return; |
| 410 } | 410 } |
| 411 } else { | 411 } else { |
| 412 SkDebugf("No context was available matching config type and options.
\n"); | 412 SkDebugf("No context was available matching config type and options.
\n"); |
| 413 return; | 413 return; |
| 414 } | 414 } |
| 415 | 415 |
| 416 Config target = { | 416 Config target = { |
| 417 config->getTag(), | 417 gpuConfig->getTag(), |
| 418 Benchmark::kGPU_Backend, | 418 Benchmark::kGPU_Backend, |
| 419 kN32_SkColorType, | 419 kN32_SkColorType, |
| 420 kPremul_SkAlphaType, | 420 kPremul_SkAlphaType, |
| 421 sampleCount, | 421 sampleCount, |
| 422 ctxType, | 422 ctxType, |
| 423 ctxOptions, | 423 ctxOptions, |
| 424 false }; | 424 gpuConfig->getUseDIText() |
| 425 }; |
| 425 | 426 |
| 426 configs->push_back(target); | 427 configs->push_back(target); |
| 427 return; | 428 return; |
| 428 } | 429 } |
| 429 #endif | 430 #endif |
| 430 | 431 |
| 431 #define CPU_CONFIG(name, backend, color, alpha)
\ | 432 #define CPU_CONFIG(name, backend, color, alpha)
\ |
| 432 if (config->getTag().equals(#name)) {
\ | 433 if (config->getTag().equals(#name)) {
\ |
| 433 Config config = { SkString(#name), Benchmark::backend, color, alpha,
0, \ | 434 Config config = { SkString(#name), Benchmark::backend, color, alpha,
0, \ |
| 434 kBogusGLContextType, kBogusGLContextOptions,
\ | 435 kBogusGLContextType, kBogusGLContextOptions,
\ |
| (...skipping 840 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1275 | 1276 |
| 1276 return 0; | 1277 return 0; |
| 1277 } | 1278 } |
| 1278 | 1279 |
| 1279 #if !defined SK_BUILD_FOR_IOS | 1280 #if !defined SK_BUILD_FOR_IOS |
| 1280 int main(int argc, char** argv) { | 1281 int main(int argc, char** argv) { |
| 1281 SkCommandLineFlags::Parse(argc, argv); | 1282 SkCommandLineFlags::Parse(argc, argv); |
| 1282 return nanobench_main(); | 1283 return nanobench_main(); |
| 1283 } | 1284 } |
| 1284 #endif | 1285 #endif |
| OLD | NEW |