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

Unified Diff: tests/PathOpsDQuadTest.cpp

Issue 52653002: pathops work in progress (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: add raster vs gpu test Created 7 years, 1 month 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/PathOpsCubicQuadIntersectionTest.cpp ('k') | tests/PathOpsDTriangleTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/PathOpsDQuadTest.cpp
diff --git a/tests/PathOpsDQuadTest.cpp b/tests/PathOpsDQuadTest.cpp
index 5921b695782398911abef0ad0eb142e034c5162f..e6f1deb72f1688d1f0c48c80c65b66569a1570ef 100644
--- a/tests/PathOpsDQuadTest.cpp
+++ b/tests/PathOpsDQuadTest.cpp
@@ -5,7 +5,9 @@
* found in the LICENSE file.
*/
#include "PathOpsTestCommon.h"
+#include "SkPath.h"
#include "SkPathOpsQuad.h"
+#include "SkRRect.h"
#include "Test.h"
static const SkDQuad tests[] = {
@@ -21,7 +23,7 @@ static const SkDPoint inPoint[]= {
{1, 0.8},
{1.8, 1},
{1.5, 1},
- {0.5, 0.5},
+ {0.4999, 0.5}, // was 0.5, 0.5; points on the hull are considered outside
};
static const SkDPoint outPoint[]= {
@@ -51,5 +53,16 @@ static void PathOpsDQuadTest(skiatest::Reporter* reporter) {
}
}
+static void PathOpsRRectTest(skiatest::Reporter* reporter) {
+ SkPath path;
+ SkRRect rRect;
+ SkRect rect = {135, 143, 250, 177};
+ SkVector radii[4] = {{8, 8}, {8, 8}, {0, 0}, {0, 0}};
+ rRect.setRectRadii(rect, radii);
+ path.addRRect(rRect);
+}
+
#include "TestClassDef.h"
DEFINE_TESTCLASS_SHORT(PathOpsDQuadTest)
+
+DEFINE_TESTCLASS_SHORT(PathOpsRRectTest)
« no previous file with comments | « tests/PathOpsCubicQuadIntersectionTest.cpp ('k') | tests/PathOpsDTriangleTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698