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

Side by Side Diff: tests/PathOpsSkpClipTest.cpp

Issue 19183003: path ops near exact (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: remove unused static function Created 7 years, 5 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 | Annotate | Revision Log
« no previous file with comments | « tests/PathOpsQuadLineIntersectionTest.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #include "PathOpsExtendedTest.h" 1 #include "PathOpsExtendedTest.h"
2 #include "PathOpsThreadedCommon.h" 2 #include "PathOpsThreadedCommon.h"
3 #include "SkBitmap.h" 3 #include "SkBitmap.h"
4 #include "SkDevice.h" 4 #include "SkDevice.h"
5 #include "SkCanvas.h" 5 #include "SkCanvas.h"
6 #include "SkImageDecoder.h" 6 #include "SkImageDecoder.h"
7 #include "SkImageEncoder.h" 7 #include "SkImageEncoder.h"
8 #include "SkStream.h" 8 #include "SkStream.h"
9 #include "SkOSFile.h" 9 #include "SkOSFile.h"
10 #include "SkPicture.h" 10 #include "SkPicture.h"
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 bool useOp = i ? true : false; 81 bool useOp = i ? true : false;
82 canvas.setAllowSimplifyClip(useOp); 82 canvas.setAllowSimplifyClip(useOp);
83 pic->draw(&canvas); 83 pic->draw(&canvas);
84 SkString outFile; 84 SkString outFile;
85 make_filepath(&outFile, useOp ? outSkpClipDir : outOldClipDir, pngName); 85 make_filepath(&outFile, useOp ? outSkpClipDir : outOldClipDir, pngName);
86 SkImageEncoder::EncodeFile(outFile.c_str(), bitmap, SkImageEncoder::kPNG _Type, 100); 86 SkImageEncoder::EncodeFile(outFile.c_str(), bitmap, SkImageEncoder::kPNG _Type, 100);
87 } 87 }
88 SkDELETE(pic); 88 SkDELETE(pic);
89 } 89 }
90 90
91 const char skipBefore[] = "http___health_com.skp"; 91 const char skipBefore[] = "http___kkiste_to.skp";
92 92
93 static void PathOpsSkpClipTest(skiatest::Reporter* reporter) { 93 static void PathOpsSkpClipTest(skiatest::Reporter* reporter) {
94 SkOSFile::Iter iter(pictDir, "skp"); 94 SkOSFile::Iter iter(pictDir, "skp");
95 SkString filename; 95 SkString filename;
96 int testCount = 0; 96 int testCount = 0;
97 while (iter.next(&filename)) { 97 while (iter.next(&filename)) {
98 if (strcmp(filename.c_str(), skipBefore) < 0) { 98 if (strcmp(filename.c_str(), skipBefore) < 0) {
99 continue; 99 continue;
100 } 100 }
101 testOne(filename); 101 testOne(filename);
(...skipping 29 matching lines...) Expand all
131 if (strcmp(filename.c_str(), skipBefore) < 0) { 131 if (strcmp(filename.c_str(), skipBefore) < 0) {
132 continue; 132 continue;
133 } 133 }
134 *testRunner.fRunnables.append() = SkNEW_ARGS(PathOpsThreadedRunnable, 134 *testRunner.fRunnables.append() = SkNEW_ARGS(PathOpsThreadedRunnable,
135 (&testSkpClipMain, filename.c_str(), &testRunner)); 135 (&testSkpClipMain, filename.c_str(), &testRunner));
136 reporter->bumpTestCount(); 136 reporter->bumpTestCount();
137 } 137 }
138 testRunner.render(); 138 testRunner.render();
139 } 139 }
140 140
141 static void PathOpsSkpClipTestOne(skiatest::Reporter* reporter) { 141 static void PathOpsSkpClipOneOffTest(skiatest::Reporter* reporter) {
142 SkString filename(skipBefore); 142 SkString filename(skipBefore);
143 testOne(filename); 143 testOne(filename);
144 } 144 }
145 145
146 #include "TestClassDef.h" 146 #include "TestClassDef.h"
147 DEFINE_TESTCLASS_SHORT(PathOpsSkpClipTest) 147 DEFINE_TESTCLASS_SHORT(PathOpsSkpClipTest)
148 148
149 DEFINE_TESTCLASS_SHORT(PathOpsSkpClipTestOne) 149 DEFINE_TESTCLASS_SHORT(PathOpsSkpClipOneOffTest)
150 150
151 DEFINE_TESTCLASS_SHORT(PathOpsSkpClipThreadedTest) 151 DEFINE_TESTCLASS_SHORT(PathOpsSkpClipThreadedTest)
OLDNEW
« no previous file with comments | « tests/PathOpsQuadLineIntersectionTest.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698