Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(524)

Side by Side Diff: tests/PathOpsTightBoundsTest.cpp

Issue 1037573004: cumulative pathops patch (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: fix pathopsinverse gm Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « tests/PathOpsThreeWayTest.cpp ('k') | tools/pathops_sorter.htm » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2013 Google Inc. 2 * Copyright 2013 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 #include "SkCanvas.h" 9 #include "SkCanvas.h"
10 #include "SkRandom.h" 10 #include "SkRandom.h"
11 #include "SkTArray.h"
12 #include "SkTSort.h" 11 #include "SkTSort.h"
13 #include "Test.h" 12 #include "Test.h"
14 13
15 static void testTightBoundsLines(PathOpsThreadState* data) { 14 static void testTightBoundsLines(PathOpsThreadState* data) {
16 SkRandom ran; 15 SkRandom ran;
17 for (int index = 0; index < 1000; ++index) { 16 for (int index = 0; index < 1000; ++index) {
18 SkPath path; 17 SkPath path;
19 int contourCount = ran.nextRangeU(1, 10); 18 int contourCount = ran.nextRangeU(1, 10);
20 for (int cIndex = 0; cIndex < contourCount; ++cIndex) { 19 for (int cIndex = 0; cIndex < contourCount; ++cIndex) {
21 int lineCount = ran.nextRangeU(1, 10); 20 int lineCount = ran.nextRangeU(1, 10);
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after
114 PathOpsThreadedTestRunner testRunner(reporter); 113 PathOpsThreadedTestRunner testRunner(reporter);
115 int outerCount = reporter->allowExtendedTest() ? 100 : 1; 114 int outerCount = reporter->allowExtendedTest() ? 100 : 1;
116 for (int index = 0; index < outerCount; ++index) { 115 for (int index = 0; index < outerCount; ++index) {
117 for (int idx2 = 0; idx2 < 10; ++idx2) { 116 for (int idx2 = 0; idx2 < 10; ++idx2) {
118 *testRunner.fRunnables.append() = SkNEW_ARGS(PathOpsThreadedRunnable , 117 *testRunner.fRunnables.append() = SkNEW_ARGS(PathOpsThreadedRunnable ,
119 (&testTightBoundsQuads, 0, 0, 0, 0, &testRunner)); 118 (&testTightBoundsQuads, 0, 0, 0, 0, &testRunner));
120 } 119 }
121 } 120 }
122 testRunner.render(); 121 testRunner.render();
123 } 122 }
OLDNEW
« no previous file with comments | « tests/PathOpsThreeWayTest.cpp ('k') | tools/pathops_sorter.htm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698