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

Unified Diff: tests/PathOpsSimplifyTest.cpp

Issue 1111333002: compute initial winding from projected rays (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: add missing test reference Created 5 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tests/PathOpsQuadIntersectionTest.cpp ('k') | tests/PathOpsSkpTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/PathOpsSimplifyTest.cpp
diff --git a/tests/PathOpsSimplifyTest.cpp b/tests/PathOpsSimplifyTest.cpp
index 599fb1a7850e630c89de64e7884bca676dd9469c..3aad45d069f52b2a02a6ebb4e4ce19cb12332eeb 100644
--- a/tests/PathOpsSimplifyTest.cpp
+++ b/tests/PathOpsSimplifyTest.cpp
@@ -4726,11 +4726,39 @@ static void testQuads64(skiatest::Reporter* reporter,const char* filename) {
testSimplify(reporter, path, filename);
}
+static void testTriangle1(skiatest::Reporter* reporter,const char* filename) {
+ SkPath path;
+ path.moveTo(0, 0);
+ path.lineTo(1, 0);
+ path.lineTo(2, 3);
+ path.close();
+ path.moveTo(0, 0);
+ path.lineTo(1, 2);
+ path.lineTo(1, 0);
+ path.close();
+ testSimplify(reporter, path, filename);
+}
+
+static void testTriangle2(skiatest::Reporter* reporter,const char* filename) {
+ SkPath path;
+ path.moveTo(0, 0);
+ path.lineTo(1, 0);
+ path.lineTo(0, 1);
+ path.close();
+ path.moveTo(2, 0);
+ path.lineTo(0, 2);
+ path.lineTo(2, 2);
+ path.close();
+ testSimplify(reporter, path, filename);
+}
+
static void (*skipTest)(skiatest::Reporter* , const char* filename) = 0;
static void (*firstTest)(skiatest::Reporter* , const char* filename) = 0;
static void (*stopTest)(skiatest::Reporter* , const char* filename) = 0;
static TestDesc tests[] = {
+ TEST(testTriangle2),
+ TEST(testTriangle1),
TEST(testQuads64),
TEST(testQuads63),
TEST(testQuads62),
« no previous file with comments | « tests/PathOpsQuadIntersectionTest.cpp ('k') | tests/PathOpsSkpTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698