| 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 SK_COMMON_FLAGS_H | 8 #ifndef SK_COMMON_FLAGS_H |
| 9 #define SK_COMMON_FLAGS_H | 9 #define SK_COMMON_FLAGS_H |
| 10 | 10 |
| 11 #include "SkCommandLineFlags.h" | 11 #include "SkCommandLineFlags.h" |
| 12 #include "SkTArray.h" |
| 13 #include "SkString.h" |
| 12 | 14 |
| 13 DECLARE_bool(cpu); | 15 DECLARE_bool(cpu); |
| 14 DECLARE_bool(dryRun); | 16 DECLARE_bool(dryRun); |
| 15 DECLARE_bool(gpu); | 17 DECLARE_bool(gpu); |
| 16 DECLARE_string(images); | 18 DECLARE_string(images); |
| 17 DECLARE_string(match); | 19 DECLARE_string(match); |
| 18 DECLARE_bool(quiet); | 20 DECLARE_bool(quiet); |
| 19 DECLARE_bool(resetGpuContext); | 21 DECLARE_bool(resetGpuContext); |
| 20 DECLARE_bool(preAbandonGpuContext); | 22 DECLARE_bool(preAbandonGpuContext); |
| 21 DECLARE_bool(abandonGpuContext); | 23 DECLARE_bool(abandonGpuContext); |
| 22 DECLARE_string(skps); | 24 DECLARE_string(skps); |
| 23 DECLARE_int32(threads); | 25 DECLARE_int32(threads); |
| 24 DECLARE_string(resourcePath); | 26 DECLARE_string(resourcePath); |
| 25 DECLARE_bool(verbose); | 27 DECLARE_bool(verbose); |
| 26 DECLARE_bool(veryVerbose); | 28 DECLARE_bool(veryVerbose); |
| 27 DECLARE_string(writePath); | 29 DECLARE_string(writePath); |
| 28 | 30 |
| 29 DECLARE_string(key); | 31 DECLARE_string(key); |
| 30 DECLARE_string(properties); | 32 DECLARE_string(properties); |
| 31 | 33 |
| 34 namespace SkCommonFlags { |
| 35 /** |
| 36 * Helper to assist in collecting images from --images. |
| 37 * |
| 38 * Populates an input array of strings with paths to images to test. |
| 39 * |
| 40 * If a directory is passed to --images that does not have any supported im
ages (based on file |
| 41 * type), this will exit the program, so the user or bot can rerun using th
e correct directory. |
| 42 * |
| 43 * If a file is passed to --images, assume the user is deliberately testing
this image, regardless |
| 44 * of file type. |
| 45 */ |
| 46 void collectImages(SkTArray<SkString>*); |
| 47 } |
| 48 |
| 32 #endif | 49 #endif |
| OLD | NEW |