| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2012 Google Inc. | 2 * Copyright 2012 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 #include "PathOpsExtendedTest.h" | 7 #include "PathOpsExtendedTest.h" |
| 8 #include "PathOpsThreadedCommon.h" | 8 #include "PathOpsThreadedCommon.h" |
| 9 | 9 |
| 10 static void testSimplifyQuadralateralsMain(PathOpsThreadState* data) | 10 static void testSimplifyQuadralateralsMain(PathOpsThreadState* data) |
| (...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 69 outputProgress(state.fPathStr, pathStr, SkPath::kEvenOdd
_FillType); | 69 outputProgress(state.fPathStr, pathStr, SkPath::kEvenOdd
_FillType); |
| 70 } | 70 } |
| 71 testSimplify(path, true, out, state, pathStr); | 71 testSimplify(path, true, out, state, pathStr); |
| 72 } | 72 } |
| 73 } | 73 } |
| 74 } | 74 } |
| 75 } | 75 } |
| 76 } | 76 } |
| 77 | 77 |
| 78 DEF_TEST(PathOpsSimplifyQuadralateralsThreaded, reporter) { | 78 DEF_TEST(PathOpsSimplifyQuadralateralsThreaded, reporter) { |
| 79 initializeTests(reporter, "testQuadralaterals"); | 79 int threadCount = initializeTests(reporter, "testQuadralaterals"); |
| 80 PathOpsThreadedTestRunner testRunner(reporter); | 80 PathOpsThreadedTestRunner testRunner(reporter, threadCount); |
| 81 for (int a = 0; a < 16; ++a) { | 81 for (int a = 0; a < 16; ++a) { |
| 82 for (int b = a ; b < 16; ++b) { | 82 for (int b = a ; b < 16; ++b) { |
| 83 for (int c = b ; c < 16; ++c) { | 83 for (int c = b ; c < 16; ++c) { |
| 84 for (int d = c; d < 16; ++d) { | 84 for (int d = c; d < 16; ++d) { |
| 85 *testRunner.fRunnables.append() = SkNEW_ARGS(PathOpsThreaded
Runnable, | 85 *testRunner.fRunnables.append() = SkNEW_ARGS(PathOpsThreaded
Runnable, |
| 86 (&testSimplifyQuadralateralsMain, a, b, c, d, &testR
unner)); | 86 (&testSimplifyQuadralateralsMain, a, b, c, d, &testR
unner)); |
| 87 } | 87 } |
| 88 if (!reporter->allowExtendedTest()) goto finish; | 88 if (!reporter->allowExtendedTest()) goto finish; |
| 89 } | 89 } |
| 90 } | 90 } |
| 91 } | 91 } |
| 92 finish: | 92 finish: |
| 93 testRunner.render(); | 93 testRunner.render(); |
| 94 } | 94 } |
| OLD | NEW |