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

Unified Diff: src/pathops/SkPathOpsSimplify.cpp

Issue 21359002: path ops work in progress (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: remove space Created 7 years, 3 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 | « src/pathops/SkPathOpsQuad.cpp ('k') | src/pathops/SkPathOpsSpan.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/pathops/SkPathOpsSimplify.cpp
diff --git a/src/pathops/SkPathOpsSimplify.cpp b/src/pathops/SkPathOpsSimplify.cpp
index 488778904f1bfa2ab2bb893eb3f9b751a9e0f397..76e34130895c56348e70d65524cbae0f68a8186c 100644
--- a/src/pathops/SkPathOpsSimplify.cpp
+++ b/src/pathops/SkPathOpsSimplify.cpp
@@ -17,8 +17,8 @@ static bool bridgeWinding(SkTArray<SkOpContour*, true>& contourList, SkPathWrite
do {
int index, endIndex;
bool topDone;
- SkOpSegment* current = FindSortableTop(contourList, &firstContour, &index, &endIndex,
- &topLeft, &topUnsortable, &topDone, false);
+ SkOpSegment* current = FindSortableTop(contourList, SkOpAngle::kUnaryWinding, &firstContour,
+ &index, &endIndex, &topLeft, &topUnsortable, &topDone);
if (!current) {
if (topUnsortable || !topDone) {
topUnsortable = false;
@@ -149,7 +149,7 @@ static bool bridgeXor(SkTArray<SkOpContour*, true>& contourList, SkPathWriter* s
// FIXME : add this as a member of SkPath
bool Simplify(const SkPath& path, SkPath* result) {
#if DEBUG_SORT || DEBUG_SWAP_TOP
- gDebugSortCount = gDebugSortCountDefault;
+ SkPathOpsDebug::gSortCount = SkPathOpsDebug::gSortCountDefault;
#endif
// returns 1 for evenodd, -1 for winding, regardless of inverse-ness
SkPath::FillType fillType = path.isInverseFillType() ? SkPath::kInverseEvenOdd_FillType
@@ -186,6 +186,7 @@ bool Simplify(const SkPath& path, SkPath* result) {
CoincidenceCheck(&contourList, 0);
FixOtherTIndex(&contourList);
CheckEnds(&contourList);
+ CheckTiny(&contourList);
SortSegments(&contourList);
#if DEBUG_ACTIVE_SPANS || DEBUG_ACTIVE_SPANS_FIRST_ONLY
DebugShowActiveSpans(contourList);
« no previous file with comments | « src/pathops/SkPathOpsQuad.cpp ('k') | src/pathops/SkPathOpsSpan.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698