• Home
  • Raw
  • Download

Lines Matching +full:- +full:- +full:agree +full:- +full:tos

4  * Use of this source code is governed by a BSD-style license that can be
43 do { if (cond) log->record(SkPathOpsDebug::kFail_Glitch, coin); } while (false)
47 do { if (cond) log->record(SkPathOpsDebug::kFail_Glitch, span); } while (false)
50 do { if (cond) log->record(SkPathOpsDebug::kReturnFalse_Glitch, span); \
117 glitch->fBase = nullptr; in recordCommon()
118 glitch->fSuspect = nullptr; in recordCommon()
119 glitch->fSegment = nullptr; in recordCommon()
120 glitch->fOppSegment = nullptr; in recordCommon()
121 glitch->fCoinSpan = nullptr; in recordCommon()
122 glitch->fEndSpan = nullptr; in recordCommon()
123 glitch->fOppSpan = nullptr; in recordCommon()
124 glitch->fOppEndSpan = nullptr; in recordCommon()
125 glitch->fStartT = SK_ScalarNaN; in recordCommon()
126 glitch->fEndT = SK_ScalarNaN; in recordCommon()
127 glitch->fOppStartT = SK_ScalarNaN; in recordCommon()
128 glitch->fOppEndT = SK_ScalarNaN; in recordCommon()
129 glitch->fPt = { SK_ScalarNaN, SK_ScalarNaN }; in recordCommon()
130 glitch->fType = type; in recordCommon()
137 glitch->fBase = base; in record()
138 glitch->fSuspect = suspect; in record()
144 glitch->fBase = base; in record()
145 glitch->fCoinSpan = ptT; in record()
151 glitch->fCoinSpan = coin->coinPtTStart(); in record()
152 glitch->fEndSpan = coin->coinPtTEnd(); in record()
154 glitch->fOppSpan = opp->coinPtTStart(); in record()
155 glitch->fOppEndSpan = opp->coinPtTEnd(); in record()
162 glitch->fBase = base; in record()
163 glitch->fSegment = seg; in record()
164 glitch->fStartT = t; in record()
165 glitch->fPt = pt; in record()
171 glitch->fBase = base; in record()
172 glitch->fStartT = t; in record()
173 glitch->fPt = pt; in record()
179 glitch->fCoinSpan = coin->coinPtTStart(); in record()
180 glitch->fEndSpan = coin->coinPtTEnd(); in record()
181 glitch->fEndSpan = endSpan; in record()
182 glitch->fOppSpan = coinSpan; in record()
183 glitch->fOppEndSpan = endSpan; in record()
189 glitch->fBase = base; in record()
190 glitch->fCoinSpan = coin->coinPtTStart(); in record()
191 glitch->fEndSpan = coin->coinPtTEnd(); in record()
197 glitch->fCoinSpan = ptTS; in record()
198 glitch->fEndSpan = ptTE; in record()
199 glitch->fOppSpan = oPtTS; in record()
200 glitch->fOppEndSpan = oPtTE; in record()
206 glitch->fSegment = seg; in record()
207 glitch->fStartT = startT; in record()
208 glitch->fEndT = endT; in record()
209 glitch->fOppSegment = oppSeg; in record()
210 glitch->fOppStartT = oppStartT; in record()
211 glitch->fOppEndT = oppEndT; in record()
217 glitch->fSegment = seg; in record()
218 glitch->fBase = span; in record()
223 glitch->fStartT = t; in record()
224 glitch->fBase = span; in record()
229 glitch->fSegment = seg; in record()
235 glitch->fCoinSpan = coin->coinPtTStart(); in record()
236 glitch->fEndSpan = ptT; in record()
247 this->add(dict.fDict[index]); in add()
255 if (entry->fIteration == key.fIteration && entry->fLineNumber == key.fLineNumber) { in add()
256 SkASSERT(!strcmp(entry->fFunctionName, key.fFunctionName)); in add()
257 if (entry->fGlitchType == kUninitialized_Glitch) { in add()
258 entry->fGlitchType = key.fGlitchType; in add()
273 /* result |= */ contour->debugMissingCoincidence(glitches); in missing_coincidence()
274 } while ((contour = contour->next())); in missing_coincidence()
281 contour->debugMoveMultiples(glitches); in move_multiples()
282 } while ((contour = contour->next())); in move_multiples()
289 contour->debugMoveNearby(glitches); in move_nearby()
290 } while ((contour = contour->next())); in move_nearby()
314 fCoincidence->debugAddExpanded(&glitches); in debugAddToCoinChangedDict()
317 fCoincidence->debugAddMissing(&glitches, &added); in debugAddToCoinChangedDict()
319 fCoincidence->debugAddEndMovedSpans(&glitches); in debugAddToCoinChangedDict()
321 fCoincidence->debugCorrectEnds(&glitches); in debugAddToCoinChangedDict()
323 fCoincidence->debugExpand(&glitches); in debugAddToCoinChangedDict()
327 fCoincidence->debugMark(&glitches); in debugAddToCoinChangedDict()
345 contour->debugShowActiveSpans(&str); in ShowActiveSpans()
346 } while ((contour = contour->next())); in ShowActiveSpans()
351 SkDebugf("%.*s", (int) (end - s + 1), s); in ShowActiveSpans()
362 contourList->globalState()->debugSetCheckHealth(true); in CheckHealth()
367 const SkOpCoincidence* coincidence = contour->globalState()->coincidence(); in CheckHealth()
368 coincidence->debugCheckValid(&glitches); // don't call validate; spans may be inconsistent in CheckHealth()
370 contour->debugCheckHealth(&glitches); in CheckHealth()
371 contour->debugMissingCoincidence(&glitches); in CheckHealth()
372 } while ((contour = contour->next())); in CheckHealth()
374 coincidence->debugAddMissing(&glitches, &added); in CheckHealth()
375 coincidence->debugExpand(&glitches); in CheckHealth()
376 coincidence->debugAddExpanded(&glitches); in CheckHealth()
377 coincidence->debugMark(&glitches); in CheckHealth()
384 SkDebugf(mask & (1 << index) ? "x" : "-"); in CheckHealth()
386 SkDebugf(" %s\n", contourList->globalState()->debugCoinDictEntry().fFunctionName); in CheckHealth()
391 SkDebugf(" seg/base=%d/%d", glitch.fBase->segment()->debugID(), in CheckHealth()
392 glitch.fBase->debugID()); in CheckHealth()
395 SkDebugf(" seg/base=%d/%d", glitch.fSuspect->segment()->debugID(), in CheckHealth()
396 glitch.fSuspect->debugID()); in CheckHealth()
399 SkDebugf(" segment=%d", glitch.fSegment->debugID()); in CheckHealth()
402 SkDebugf(" coinSeg/Span/PtT=%d/%d/%d", glitch.fCoinSpan->segment()->debugID(), in CheckHealth()
403 glitch.fCoinSpan->span()->debugID(), glitch.fCoinSpan->debugID()); in CheckHealth()
406 SkDebugf(" endSpan=%d", glitch.fEndSpan->debugID()); in CheckHealth()
409 SkDebugf(" oppSeg/Span/PtT=%d/%d/%d", glitch.fOppSpan->segment()->debugID(), in CheckHealth()
410 glitch.fOppSpan->span()->debugID(), glitch.fOppSpan->debugID()); in CheckHealth()
413 SkDebugf(" oppEndSpan=%d", glitch.fOppEndSpan->debugID()); in CheckHealth()
422 SkDebugf(" segment=%d", glitch.fOppSegment->debugID()); in CheckHealth()
437 contourList->globalState()->debugSetCheckHealth(false); in CheckHealth()
502 memmove(&str[idx + 2], &str[idx + 1], len - idx); in MathematicaIze()
512 return wind > SK_MinS32 + 0xFFFF && wind < SK_MaxS32 - 0xFFFF; in ValidWind()
576 if (fDebugLoopCount[index] >= i->debugLoopCount(looper)) { in debugAddLoopCount()
579 fDebugLoopCount[index] = i->debugLoopCount(looper); in debugAddLoopCount()
580 fDebugWorstVerb[index * 2] = wt.segment()->verb(); in debugAddLoopCount()
581 fDebugWorstVerb[index * 2 + 1] = wn.segment()->verb(); in debugAddLoopCount()
584 (SkPathOpsVerbToPoints(wt.segment()->verb()) + 1) * sizeof(SkPoint)); in debugAddLoopCount()
586 (SkPathOpsVerbToPoints(wn.segment()->verb()) + 1) * sizeof(SkPoint)); in debugAddLoopCount()
590 i->debugResetLoopCount(); in debugAddLoopCount()
595 if (fDebugLoopCount[index] >= local->fDebugLoopCount[index]) { in debugDoYourWorst()
598 fDebugLoopCount[index] = local->fDebugLoopCount[index]; in debugDoYourWorst()
599 fDebugWorstVerb[index * 2] = local->fDebugWorstVerb[index * 2]; in debugDoYourWorst()
600 fDebugWorstVerb[index * 2 + 1] = local->fDebugWorstVerb[index * 2 + 1]; in debugDoYourWorst()
601 memcpy(&fDebugWorstPts[index * 2 * 4], &local->fDebugWorstPts[index * 2 * 4], in debugDoYourWorst()
603 fDebugWorstWeight[index * 2] = local->fDebugWorstWeight[index * 2]; in debugDoYourWorst()
604 fDebugWorstWeight[index * 2 + 1] = local->fDebugWorstWeight[index * 2 + 1]; in debugDoYourWorst()
606 local->debugResetLoopCounts(); in debugDoYourWorst()
618 if (index < ptCount - 1) { in dump_curve()
663 writable->setPhase(phase); in debugSetPhase()
666 SkPathOpsDebug::CoinDictEntry* entry = &writable->fCoinDictEntry; in debugSetPhase()
667 writable->fPreviousFuncName = entry->fFunctionName; in debugSetPhase()
668 entry->fIteration = iteration; in debugSetPhase()
669 entry->fLineNumber = lineNo; in debugSetPhase()
670 entry->fGlitchType = SkPathOpsDebug::kUninitialized_Glitch; in debugSetPhase()
671 entry->fFunctionName = funcName; in debugSetPhase()
672 writable->fCoinVisitedDict.add(*entry); in debugSetPhase()
673 writable->debugAddToCoinChangedDict(); in debugSetPhase()
724 // commented-out lines keep this in sync with addT()
727 SkPoint pt = this->ptAtT(t); in debugAddT()
730 const SkOpPtT* result = span->ptT(); in debugAddT()
731 if (t == result->fT || this->match(result, this, t, pt)) { in debugAddT()
732 // span->bumpSpanAdds(); in debugAddT()
735 if (t < result->fT) { in debugAddT()
736 const SkOpSpan* prev = result->span()->prev(); in debugAddT()
739 this->globalState()->setAllocatedOpSpan(); in debugAddT()
740 // span->init(this, prev, t, pt); in debugAddT()
741 this->debugValidate(); in debugAddT()
744 // span->segment()->debugID(), span->debugID()); in debugAddT()
746 // span->bumpSpanAdds(); in debugAddT()
750 } while ((span = span->upCast()->next())); in debugAddT()
761 const SkOpAngle* angle = base->fromAngle(); in debugCheckAngleCoin()
762 if (angle && angle->debugCheckCoincidence()) { in debugCheckAngleCoin()
763 angle->debugCheckNearCoincidence(); in debugCheckAngleCoin()
765 if (base->final()) { in debugCheckAngleCoin()
768 span = base->upCast(); in debugCheckAngleCoin()
769 angle = span->toAngle(); in debugCheckAngleCoin()
770 if (angle && angle->debugCheckCoincidence()) { in debugCheckAngleCoin()
771 angle->debugCheckNearCoincidence(); in debugCheckAngleCoin()
773 } while ((base = span->next())); in debugCheckAngleCoin()
785 // commented-out lines keep this in sync with clearAll()
789 this->debugClearOne(span, glitches); in debugClearAll()
790 } while ((span = span->next()->upCastable())); in debugClearAll()
791 this->globalState()->coincidence()->debugRelease(glitches, this); in debugClearAll()
794 // commented-out lines keep this in sync with clearOne()
796 if (span->windValue()) glitches->record(SkPathOpsDebug::kCollapsedWindValue_Glitch, span); in debugClearOne()
797 if (span->oppValue()) glitches->record(SkPathOpsDebug::kCollapsedOppValue_Glitch, span); in debugClearOne()
798 if (!span->done()) glitches->record(SkPathOpsDebug::kCollapsedDone_Glitch, span); in debugClearOne()
804 SkOpSpan* span = this->head(); in debugLastAngle()
806 if (span->toAngle()) { in debugLastAngle()
808 result = span->toAngle(); in debugLastAngle()
810 } while ((span = span->next()->upCastable())); in debugLastAngle()
816 // commented-out lines keep this in sync with ClearVisited
820 const SkOpPtT* ptT = span->ptT(), * stopPtT = ptT; in DebugClearVisited()
821 while ((ptT = ptT->next()) != stopPtT) { in DebugClearVisited()
822 const SkOpSegment* opp = ptT->segment(); in DebugClearVisited()
823 opp->resetDebugVisited(); in DebugClearVisited()
825 } while (!span->final() && (span = span->upCast()->next())); in DebugClearVisited()
830 // commented-out lines keep this in sync with missingCoincidence()
836 // A-B intersect at a point 1; A-C and B-C intersect at point 2, so near
838 // Even though A-B correctly do not detect an intersection at point 2,
841 if (this->done()) { in debugMissingCoincidence()
848 const SkOpPtT* ptT = spanBase->ptT(), * spanStopPtT = ptT; in debugMissingCoincidence()
849 SkASSERT(ptT->span() == spanBase); in debugMissingCoincidence()
850 while ((ptT = ptT->next()) != spanStopPtT) { in debugMissingCoincidence()
851 if (ptT->deleted()) { in debugMissingCoincidence()
854 const SkOpSegment* opp = ptT->span()->segment(); in debugMissingCoincidence()
855 if (opp->done()) { in debugMissingCoincidence()
859 if (!opp->debugVisited()) { in debugMissingCoincidence()
865 if (ptT->segment() == this) { in debugMissingCoincidence()
868 const SkOpSpan* span = spanBase->upCastable(); in debugMissingCoincidence()
871 …if (span && span->segment() != opp && span->containsCoincidence(opp)) { // debug has additional c… in debugMissingCoincidence()
874 …if (spanBase->segment() != opp && spanBase->containsCoinEnd(opp)) { // debug has additional condi… in debugMissingCoincidence()
880 const SkOpSpan* priorTest = spanBase->prev(); in debugMissingCoincidence()
882 priorStopPtT = priorPtT = priorTest->ptT(); in debugMissingCoincidence()
883 while ((priorPtT = priorPtT->next()) != priorStopPtT) { in debugMissingCoincidence()
884 if (priorPtT->deleted()) { in debugMissingCoincidence()
887 const SkOpSegment* segment = priorPtT->span()->segment(); in debugMissingCoincidence()
894 priorTest = priorTest->prev(); in debugMissingCoincidence()
902 const SkOpPtT* oppStart = prior->ptT(); in debugMissingCoincidence()
903 const SkOpPtT* oppEnd = spanBase->ptT(); in debugMissingCoincidence()
904 bool swapped = priorPtT->fT > ptT->fT; in debugMissingCoincidence()
910 const SkOpCoincidence* coincidence = this->globalState()->coincidence(); in debugMissingCoincidence()
911 const SkOpPtT* rootPriorPtT = priorPtT->span()->ptT(); in debugMissingCoincidence()
912 const SkOpPtT* rootPtT = ptT->span()->ptT(); in debugMissingCoincidence()
913 const SkOpPtT* rootOppStart = oppStart->span()->ptT(); in debugMissingCoincidence()
914 const SkOpPtT* rootOppEnd = oppEnd->span()->ptT(); in debugMissingCoincidence()
915 if (coincidence->contains(rootPriorPtT, rootPtT, rootOppStart, rootOppEnd)) { in debugMissingCoincidence()
922 // rootPriorPtT->debugID(), rootPtT->debugID(), rootOppStart->debugID(), in debugMissingCoincidence()
923 // rootOppEnd->debugID()); in debugMissingCoincidence()
925 log->record(SkPathOpsDebug::kMissingCoin_Glitch, priorPtT, ptT, oppStart, oppEnd); in debugMissingCoincidence()
926 // coincidences->add(rootPriorPtT, rootPtT, rootOppStart, rootOppEnd); in debugMissingCoincidence()
929 // SkASSERT(coincidences->contains(rootPriorPtT, rootPtT, rootOppStart, rootOppEnd); in debugMissingCoincidence()
939 } while ((spanBase = spanBase->final() ? nullptr : spanBase->upCast()->next())); in debugMissingCoincidence()
944 // commented-out lines keep this in sync with moveMultiples()
950 int addCount = test->spanAddsCount(); in debugMoveMultiples()
955 const SkOpPtT* startPtT = test->ptT(); in debugMoveMultiples()
958 const SkOpSpanBase* oppSpan = testPtT->span(); in debugMoveMultiples()
959 if (oppSpan->spanAddsCount() == addCount) { in debugMoveMultiples()
962 if (oppSpan->deleted()) { in debugMoveMultiples()
965 const SkOpSegment* oppSegment = oppSpan->segment(); in debugMoveMultiples()
972 while ((oppPrev = oppPrev->prev())) { in debugMoveMultiples()
973 if (!roughly_equal(oppPrev->t(), oppSpan->t())) { in debugMoveMultiples()
976 if (oppPrev->spanAddsCount() == addCount) { in debugMoveMultiples()
979 if (oppPrev->deleted()) { in debugMoveMultiples()
986 while ((oppNext = oppNext->final() ? nullptr : oppNext->upCast()->next())) { in debugMoveMultiples()
987 if (!roughly_equal(oppNext->t(), oppSpan->t())) { in debugMoveMultiples()
990 if (oppNext->spanAddsCount() == addCount) { in debugMoveMultiples()
993 if (oppNext->deleted()) { in debugMoveMultiples()
1008 const SkOpPtT* oppStartPtT = oppTest->ptT(); in debugMoveMultiples()
1010 while ((oppPtT = oppPtT->next()) != oppStartPtT) { in debugMoveMultiples()
1011 const SkOpSegment* oppPtTSegment = oppPtT->segment(); in debugMoveMultiples()
1017 if (matchPtT->segment() == oppPtTSegment) { in debugMoveMultiples()
1020 } while ((matchPtT = matchPtT->next()) != startPtT); in debugMoveMultiples()
1023 oppSegment->debugValidate(); in debugMoveMultiples()
1024 oppTest->debugMergeMatches(glitches, oppSpan); in debugMoveMultiples()
1025 oppTest->debugAddOpp(glitches, oppSpan); in debugMoveMultiples()
1026 oppSegment->debugValidate(); in debugMoveMultiples()
1031 } while (oppTest != oppLast && (oppTest = oppTest->upCast()->next())); in debugMoveMultiples()
1032 } while ((testPtT = testPtT->next()) != startPtT); in debugMoveMultiples()
1035 } while ((test = test->final() ? nullptr : test->upCast()->next())); in debugMoveMultiples()
1040 // commented-out lines keep this in sync with moveNearby()
1047 const SkOpPtT* ptT = spanBase->ptT(); in debugMoveNearby()
1049 while ((ptT = ptT->next()) != headPtT) { in debugMoveNearby()
1050 const SkOpSpanBase* test = ptT->span(); in debugMoveNearby()
1051 if (ptT->segment() == this && !ptT->deleted() && test != spanBase in debugMoveNearby()
1052 && test->ptT() == ptT) { in debugMoveNearby()
1053 if (test->final()) { in debugMoveNearby()
1055 glitches->record(SkPathOpsDebug::kMoveNearbyClearAll_Glitch, this); in debugMoveNearby()
1058 glitches->record(SkPathOpsDebug::kMoveNearbyReleaseFinal_Glitch, spanBase, ptT); in debugMoveNearby()
1059 } else if (test->prev()) { in debugMoveNearby()
1060 glitches->record(SkPathOpsDebug::kMoveNearbyRelease_Glitch, test, headPtT); in debugMoveNearby()
1065 spanBase = spanBase->upCast()->next(); in debugMoveNearby()
1066 } while (!spanBase->final()); in debugMoveNearby()
1071 const SkOpSpanBase* test = spanBase->upCast()->next(); in debugMoveNearby()
1073 if (!this->spansNearby(spanBase, test, &found)) { in debugMoveNearby()
1074 glitches->record(SkPathOpsDebug::kMoveNearbyMergeFinal_Glitch, test); in debugMoveNearby()
1077 if (test->final()) { in debugMoveNearby()
1078 if (spanBase->prev()) { in debugMoveNearby()
1079 glitches->record(SkPathOpsDebug::kMoveNearbyMergeFinal_Glitch, test); in debugMoveNearby()
1081 glitches->record(SkPathOpsDebug::kMoveNearbyClearAll2_Glitch, this); in debugMoveNearby()
1085 glitches->record(SkPathOpsDebug::kMoveNearbyMerge_Glitch, spanBase); in debugMoveNearby()
1089 } while (!spanBase->final()); in debugMoveNearby()
1095 this->init(this->fPts, this->fWeight, this->contour(), this->verb()); in debugReset()
1114 SkASSERT((t - fDebugBaseMin > 0) == (fDebugLastMin - fDebugBaseMin > 0)); in debugSetCoinT()
1124 int lastId = -1; in debugShowActiveSpans()
1125 double lastT = -1; in debugShowActiveSpans()
1128 if (span->done()) { in debugShowActiveSpans()
1131 if (lastId == this->debugID() && lastT == span->t()) { in debugShowActiveSpans()
1134 lastId = this->debugID(); in debugShowActiveSpans()
1135 lastT = span->t(); in debugShowActiveSpans()
1136 str->appendf("%s id=%d", __FUNCTION__, this->debugID()); in debugShowActiveSpans()
1139 this->subDivide(span, span->next(), &curvePart); in debugShowActiveSpans()
1141 str->appendf(" (%1.9g,%1.9g", pts[0].fX, pts[0].fY); in debugShowActiveSpans()
1143 str->appendf(" %1.9g,%1.9g", pts[vIndex].fX, pts[vIndex].fY); in debugShowActiveSpans()
1146 str->appendf(" %1.9gf", curvePart.fConic.fWeight); in debugShowActiveSpans()
1148 str->appendf(") t=%1.9g tEnd=%1.9g", span->t(), span->next()->t()); in debugShowActiveSpans()
1149 if (span->windSum() == SK_MinS32) { in debugShowActiveSpans()
1150 str->appendf(" windSum=?"); in debugShowActiveSpans()
1152 str->appendf(" windSum=%d", span->windSum()); in debugShowActiveSpans()
1154 if (span->oppValue() && span->oppSum() == SK_MinS32) { in debugShowActiveSpans()
1155 str->appendf(" oppSum=?"); in debugShowActiveSpans()
1156 } else if (span->oppValue() || span->oppSum() != SK_MinS32) { in debugShowActiveSpans()
1157 str->appendf(" oppSum=%d", span->oppSum()); in debugShowActiveSpans()
1159 str->appendf(" windValue=%d", span->windValue()); in debugShowActiveSpans()
1160 if (span->oppValue() || span->oppSum() != SK_MinS32) { in debugShowActiveSpans()
1161 str->appendf(" oppValue=%d", span->oppValue()); in debugShowActiveSpans()
1163 str->appendf("\n"); in debugShowActiveSpans()
1164 } while ((span = span->next()->upCastable())); in debugShowActiveSpans()
1170 const SkPoint& pt = span->ptT()->fPt; in debugShowNewWinding()
1171 SkDebugf("%s id=%d", fun, this->debugID()); in debugShowNewWinding()
1177 span->t(), span->debugID(), pt.fX, pt.fY, span->next()->t()); in debugShowNewWinding()
1184 if (span->windSum() == SK_MinS32) { in debugShowNewWinding()
1187 SkDebugf("%d", span->windSum()); in debugShowNewWinding()
1189 SkDebugf(" windValue=%d\n", span->windValue()); in debugShowNewWinding()
1194 const SkPoint& pt = span->ptT()->fPt; in debugShowNewWinding()
1195 SkDebugf("%s id=%d", fun, this->debugID()); in debugShowNewWinding()
1201 span->t(), span->debugID(), pt.fX, pt.fY, span->next()->t()); in debugShowNewWinding()
1214 if (span->oppSum() == SK_MinS32) { in debugShowNewWinding()
1217 SkDebugf("%d", span->oppSum()); in debugShowNewWinding()
1220 if (span->windSum() == SK_MinS32) { in debugShowNewWinding()
1223 SkDebugf("%d", span->windSum()); in debugShowNewWinding()
1225 SkDebugf(" windValue=%d oppValue=%d\n", span->windValue(), span->oppValue()); in debugShowNewWinding()
1232 This should be rarely called -- the test below is thorough and time consuming.
1239 const SkOpSegment* testSegment = test->segment(); in debugCheckNearCoincidence()
1240 double testStartT = test->start()->t(); in debugCheckNearCoincidence()
1241 SkDPoint testStartPt = testSegment->dPtAtT(testStartT); in debugCheckNearCoincidence()
1242 double testEndT = test->end()->t(); in debugCheckNearCoincidence()
1243 SkDPoint testEndPt = testSegment->dPtAtT(testEndT); in debugCheckNearCoincidence()
1245 SkDebugf("%s testLenSq=%1.9g id=%d\n", __FUNCTION__, testLenSq, testSegment->debugID()); in debugCheckNearCoincidence()
1248 while ((next = next->fNext) != this) { in debugCheckNearCoincidence()
1249 SkOpSegment* nextSegment = next->segment(); in debugCheckNearCoincidence()
1250 double testMidDistSq = testSegment->distSq(testMidT, next); in debugCheckNearCoincidence()
1251 double testEndDistSq = testSegment->distSq(testEndT, next); in debugCheckNearCoincidence()
1252 double nextStartT = next->start()->t(); in debugCheckNearCoincidence()
1253 SkDPoint nextStartPt = nextSegment->dPtAtT(nextStartT); in debugCheckNearCoincidence()
1255 double nextEndT = next->end()->t(); in debugCheckNearCoincidence()
1257 double nextMidDistSq = nextSegment->distSq(nextMidT, test); in debugCheckNearCoincidence()
1258 double nextEndDistSq = nextSegment->distSq(nextEndT, test); in debugCheckNearCoincidence()
1260 testSegment->debugID(), nextSegment->debugID()); in debugCheckNearCoincidence()
1265 SkDPoint nextEndPt = nextSegment->dPtAtT(nextEndT); in debugCheckNearCoincidence()
1270 test = test->fNext; in debugCheckNearCoincidence()
1271 } while (test->fNext != this); in debugCheckNearCoincidence()
1278 switch (this->segment()->verb()) { in debugPart()
1281 this->segment()->debugID()); in debugPart()
1285 this->segment()->debugID()); in debugPart()
1290 this->segment()->debugID()); in debugPart()
1294 this->segment()->debugID()); in debugPart()
1308 next->dumpOne(true); in debugLoop()
1310 next = next->fNext; in debugLoop()
1314 next->debugValidate(); in debugLoop()
1315 next = next->fNext; in debugLoop()
1322 if (this->globalState()->debugCheckHealth()) { in debugValidate()
1331 int lastXor = -1; in debugValidate()
1332 int lastOppXor = -1; in debugValidate()
1334 if (next->unorderable()) { in debugValidate()
1337 const SkOpSpan* minSpan = next->start()->starter(next->end()); in debugValidate()
1338 if (minSpan->windValue() == SK_MinS32) { in debugValidate()
1341 bool op = next->segment()->operand(); in debugValidate()
1342 bool isXor = next->segment()->isXor(); in debugValidate()
1343 bool oppXor = next->segment()->oppXor(); in debugValidate()
1344 SkASSERT(!DEBUG_LIMIT_WIND_SUM || between(0, minSpan->windValue(), DEBUG_LIMIT_WIND_SUM)); in debugValidate()
1346 || between(-DEBUG_LIMIT_WIND_SUM, minSpan->oppValue(), DEBUG_LIMIT_WIND_SUM)); in debugValidate()
1348 SkASSERT(lastXor == -1 || lastXor == (int) useXor); in debugValidate()
1350 wind += next->debugSign() * (op ? minSpan->oppValue() : minSpan->windValue()); in debugValidate()
1355 SkASSERT(lastOppXor == -1 || lastOppXor == (int) useXor); in debugValidate()
1357 opp += next->debugSign() * (op ? minSpan->windValue() : minSpan->oppValue()); in debugValidate()
1361 next = next->fNext; in debugValidate()
1374 // SkASSERT_RELEASE(next->fSegment->debugContains(next)); in debugValidateNext()
1376 next = next->next(); in debugValidateNext()
1391 SkASSERT(coinPtTEnd()->span() == over || !SkOpGlobalState::DebugRunFail()); in debugStartCheck()
1392 SkASSERT(oppPtTEnd()->span() == outer || !SkOpGlobalState::DebugRunFail()); in debugStartCheck()
1397 // sets the span's end to the ptT referenced by the previous-next
1401 const SkOpPtT* origPtT = (this->*getEnd)(); in debugCorrectOneEnd()
1402 const SkOpSpanBase* origSpan = origPtT->span(); in debugCorrectOneEnd()
1403 const SkOpSpan* prev = origSpan->prev(); in debugCorrectOneEnd()
1404 const SkOpPtT* testPtT = prev ? prev->next()->ptT() in debugCorrectOneEnd()
1405 : origSpan->upCast()->next()->prev()->ptT(); in debugCorrectOneEnd()
1407 log->record(SkPathOpsDebug::kCorrectEnd_Glitch, this, origPtT, testPtT); in debugCorrectOneEnd()
1412 /* Commented-out lines keep this in sync with correctEnds */
1415 // makes all span ends agree with the segment's spans that define them
1417 this->debugCorrectOneEnd(log, &SkCoincidentSpans::coinPtTStart, nullptr); in debugCorrectEnds()
1418 this->debugCorrectOneEnd(log, &SkCoincidentSpans::coinPtTEnd, nullptr); in debugCorrectEnds()
1419 this->debugCorrectOneEnd(log, &SkCoincidentSpans::oppPtTStart, nullptr); in debugCorrectEnds()
1420 this->debugCorrectOneEnd(log, &SkCoincidentSpans::oppPtTEnd, nullptr); in debugCorrectEnds()
1423 /* Commented-out lines keep this in sync with expand */
1427 const SkOpSegment* segment = coinPtTStart()->segment(); in debugExpand()
1428 const SkOpSegment* oppSegment = oppPtTStart()->segment(); in debugExpand()
1430 const SkOpSpan* start = coinPtTStart()->span()->upCast(); in debugExpand()
1431 const SkOpSpan* prev = start->prev(); in debugExpand()
1433 if (!prev || !(oppPtT = prev->contains(oppSegment))) { in debugExpand()
1436 double midT = (prev->t() + start->t()) / 2; in debugExpand()
1437 if (!segment->isClose(midT, oppSegment)) { in debugExpand()
1440 if (log) log->record(SkPathOpsDebug::kExpandCoin_Glitch, this, prev->ptT(), oppPtT); in debugExpand()
1444 const SkOpSpanBase* end = coinPtTEnd()->span(); in debugExpand()
1445 SkOpSpanBase* next = end->final() ? nullptr : end->upCast()->next(); in debugExpand()
1446 if (next && next->deleted()) { in debugExpand()
1450 if (!next || !(oppPtT = next->contains(oppSegment))) { in debugExpand()
1453 double midT = (end->t() + next->t()) / 2; in debugExpand()
1454 if (!segment->isClose(midT, oppSegment)) { in debugExpand()
1457 if (log) log->record(SkPathOpsDebug::kExpandCoin_Glitch, this, next->ptT(), oppPtT); in debugExpand()
1465 const SkOpPtT* testPtT = testSpan->ptT(); in debugAddEndMovedSpans()
1467 const SkOpSegment* baseSeg = base->segment(); in debugAddEndMovedSpans()
1468 while ((testPtT = testPtT->next()) != stopPtT) { in debugAddEndMovedSpans()
1469 const SkOpSegment* testSeg = testPtT->segment(); in debugAddEndMovedSpans()
1470 if (testPtT->deleted()) { in debugAddEndMovedSpans()
1476 if (testPtT->span()->ptT() != testPtT) { in debugAddEndMovedSpans()
1479 if (this->contains(baseSeg, testSeg, testPtT->fT)) { in debugAddEndMovedSpans()
1482 // intersect perp with base->ptT() with testPtT->segment() in debugAddEndMovedSpans()
1483 SkDVector dxdy = baseSeg->dSlopeAtT(base->t()); in debugAddEndMovedSpans()
1484 const SkPoint& pt = base->pt(); in debugAddEndMovedSpans()
1485 SkDLine ray = {{{pt.fX, pt.fY}, {pt.fX + dxdy.fY, pt.fY - dxdy.fX}}}; in debugAddEndMovedSpans()
1487 (*CurveIntersectRay[testSeg->verb()])(testSeg->pts(), testSeg->weight(), ray, &i); in debugAddEndMovedSpans()
1498 SkOpPtT* oppStart = writableSeg->addT(t); in debugAddEndMovedSpans()
1503 oppStart->span()->addOpp(writableBase); in debugAddEndMovedSpans()
1504 if (oppStart->deleted()) { in debugAddEndMovedSpans()
1507 SkOpSegment* coinSeg = base->segment(); in debugAddEndMovedSpans()
1508 SkOpSegment* oppSeg = oppStart->segment(); in debugAddEndMovedSpans()
1511 coinTs = base->t(); in debugAddEndMovedSpans()
1512 coinTe = testSpan->t(); in debugAddEndMovedSpans()
1513 oppTs = oppStart->fT; in debugAddEndMovedSpans()
1514 oppTe = testPtT->fT; in debugAddEndMovedSpans()
1518 coinTs = oppStart->fT; in debugAddEndMovedSpans()
1519 coinTe = testPtT->fT; in debugAddEndMovedSpans()
1520 oppTs = base->t(); in debugAddEndMovedSpans()
1521 oppTe = testSpan->t(); in debugAddEndMovedSpans()
1529 this->debugAddOrOverlap(log, coinSeg, oppSeg, coinTs, coinTe, oppTs, oppTe, &added); in debugAddEndMovedSpans()
1537 FAIL_IF_COIN(!ptT->span()->upCastable(), ptT->span()); in debugAddEndMovedSpans()
1538 const SkOpSpan* base = ptT->span()->upCast(); in debugAddEndMovedSpans()
1539 const SkOpSpan* prev = base->prev(); in debugAddEndMovedSpans()
1540 FAIL_IF_COIN(!prev, ptT->span()); in debugAddEndMovedSpans()
1541 if (!prev->isCanceled()) { in debugAddEndMovedSpans()
1542 this->debugAddEndMovedSpans(log, base, base->prev()); in debugAddEndMovedSpans()
1544 if (!base->isCanceled()) { in debugAddEndMovedSpans()
1545 this->debugAddEndMovedSpans(log, base, base->next()); in debugAddEndMovedSpans()
1551 is not the endpoint (i.e., there's an implied line connecting B-end and A)
1554 ptT list on B-segment adjacent to the B-end/A ptT loop (not in the loop, but
1556 coincident pair. If so, check for a new coincident span between B-end/A ptT loop
1567 if (span->coinPtTStart()->fPt != span->oppPtTStart()->fPt) { in debugAddEndMovedSpans()
1568 FAIL_IF_COIN(1 == span->coinPtTStart()->fT, span); in debugAddEndMovedSpans()
1569 bool onEnd = span->coinPtTStart()->fT == 0; in debugAddEndMovedSpans()
1570 bool oOnEnd = zero_or_one(span->oppPtTStart()->fT); in debugAddEndMovedSpans()
1573 this->debugAddEndMovedSpans(log, span->oppPtTStart()); in debugAddEndMovedSpans()
1576 this->debugAddEndMovedSpans(log, span->coinPtTStart()); in debugAddEndMovedSpans()
1579 if (span->coinPtTEnd()->fPt != span->oppPtTEnd()->fPt) { in debugAddEndMovedSpans()
1580 bool onEnd = span->coinPtTEnd()->fT == 1; in debugAddEndMovedSpans()
1581 bool oOnEnd = zero_or_one(span->oppPtTEnd()->fT); in debugAddEndMovedSpans()
1584 this->debugAddEndMovedSpans(log, span->oppPtTEnd()); in debugAddEndMovedSpans()
1587 this->debugAddEndMovedSpans(log, span->coinPtTEnd()); in debugAddEndMovedSpans()
1590 } while ((span = span->next())); in debugAddEndMovedSpans()
1591 // this->restoreHead(); in debugAddEndMovedSpans()
1595 /* Commented-out lines keep this in sync with addExpanded */
1600 const SkCoincidentSpans* coin = this->fHead; in debugAddExpanded()
1605 const SkOpPtT* startPtT = coin->coinPtTStart(); in debugAddExpanded()
1606 const SkOpPtT* oStartPtT = coin->oppPtTStart(); in debugAddExpanded()
1607 double priorT = startPtT->fT; in debugAddExpanded()
1608 double oPriorT = oStartPtT->fT; in debugAddExpanded()
1609 FAIL_IF_COIN(!startPtT->contains(oStartPtT), coin); in debugAddExpanded()
1610 SkOPASSERT(coin->coinPtTEnd()->contains(coin->oppPtTEnd())); in debugAddExpanded()
1611 const SkOpSpanBase* start = startPtT->span(); in debugAddExpanded()
1612 const SkOpSpanBase* oStart = oStartPtT->span(); in debugAddExpanded()
1613 const SkOpSpanBase* end = coin->coinPtTEnd()->span(); in debugAddExpanded()
1614 const SkOpSpanBase* oEnd = coin->oppPtTEnd()->span(); in debugAddExpanded()
1615 FAIL_IF_COIN(oEnd->deleted(), coin); in debugAddExpanded()
1616 FAIL_IF_COIN(!start->upCastable(), coin); in debugAddExpanded()
1617 const SkOpSpanBase* test = start->upCast()->next(); in debugAddExpanded()
1618 FAIL_IF_COIN(!coin->flipped() && !oStart->upCastable(), coin); in debugAddExpanded()
1619 const SkOpSpanBase* oTest = coin->flipped() ? oStart->prev() : oStart->upCast()->next(); in debugAddExpanded()
1621 const SkOpSegment* seg = start->segment(); in debugAddExpanded()
1622 const SkOpSegment* oSeg = oStart->segment(); in debugAddExpanded()
1624 const SkOpPtT* containedOpp = test->ptT()->contains(oSeg); in debugAddExpanded()
1625 const SkOpPtT* containedThis = oTest->ptT()->contains(seg); in debugAddExpanded()
1627 // choose the ends, or the first common pt-t list shared by both in debugAddExpanded()
1630 nextT = test->t(); in debugAddExpanded()
1631 oNextT = containedOpp->fT; in debugAddExpanded()
1633 nextT = containedThis->fT; in debugAddExpanded()
1634 oNextT = oTest->t(); in debugAddExpanded()
1636 // iterate through until a pt-t list found that contains the other in debugAddExpanded()
1640 FAIL_IF_COIN(!walk->upCastable(), coin); in debugAddExpanded()
1641 walk = walk->upCast()->next(); in debugAddExpanded()
1642 } while (!(walkOpp = walk->ptT()->contains(oSeg)) in debugAddExpanded()
1643 && walk != coin->coinPtTEnd()->span()); in debugAddExpanded()
1645 nextT = walk->t(); in debugAddExpanded()
1646 oNextT = walkOpp->fT; in debugAddExpanded()
1649 double startRange = nextT - priorT; in debugAddExpanded()
1651 double startPart = (test->t() - priorT) / startRange; in debugAddExpanded()
1652 double oStartRange = oNextT - oPriorT; in debugAddExpanded()
1654 double oStartPart = (oTest->t() - oStartPtT->fT) / oStartRange; in debugAddExpanded()
1659 addToOpp ? log->record(SkPathOpsDebug::kAddExpandedCoin_Glitch, in debugAddExpanded()
1661 : log->record(SkPathOpsDebug::kAddExpandedCoin_Glitch, in debugAddExpanded()
1668 end = coin->coinPtTEnd()->span(); in debugAddExpanded()
1669 oEnd = coin->oppPtTEnd()->span(); in debugAddExpanded()
1672 FAIL_IF_COIN(!test->upCastable(), coin); in debugAddExpanded()
1673 priorT = test->t(); in debugAddExpanded()
1674 test = test->upCast()->next(); in debugAddExpanded()
1677 oPriorT = oTest->t(); in debugAddExpanded()
1678 oTest = coin->flipped() ? oTest->prev() : oTest->upCast()->next(); in debugAddExpanded()
1682 } while ((coin = coin->next())); in debugAddExpanded()
1686 /* Commented-out lines keep this in sync addIfMissing() */
1692 SkASSERT(over1s->fT < over1e->fT); in debugAddIfMissing()
1693 SkASSERT(between(over1s->fT, tStart, over1e->fT)); in debugAddIfMissing()
1694 SkASSERT(between(over1s->fT, tEnd, over1e->fT)); in debugAddIfMissing()
1695 SkASSERT(over2s->fT < over2e->fT); in debugAddIfMissing()
1696 SkASSERT(between(over2s->fT, tStart, over2e->fT)); in debugAddIfMissing()
1697 SkASSERT(between(over2s->fT, tEnd, over2e->fT)); in debugAddIfMissing()
1698 SkASSERT(over1s->segment() == over1e->segment()); in debugAddIfMissing()
1699 SkASSERT(over2s->segment() == over2e->segment()); in debugAddIfMissing()
1700 SkASSERT(over1s->segment() == over2s->segment()); in debugAddIfMissing()
1701 SkASSERT(over1s->segment() != coinSeg); in debugAddIfMissing()
1702 SkASSERT(over1s->segment() != oppSeg); in debugAddIfMissing()
1707 SkOpSpanBase::Collapsed result = coinSeg->collapsed(coinTs, coinTe); in debugAddIfMissing()
1709 return log->record(SkPathOpsDebug::kAddIfCollapsed_Glitch, coinSeg); in debugAddIfMissing()
1713 result = oppSeg->collapsed(oppTs, oppTe); in debugAddIfMissing()
1715 return log->record(SkPathOpsDebug::kAddIfCollapsed_Glitch, oppSeg); in debugAddIfMissing()
1722 this->debugAddOrOverlap(log, coinSeg, oppSeg, coinTs, coinTe, oppTs, oppTe, added); in debugAddIfMissing()
1726 /* Commented-out lines keep this in sync addOrOverlap() */
1734 if (fTop && !this->checkOverlap(fTop, coinSeg, oppSeg, coinTs, coinTe, oppTs, oppTe, in debugAddOrOverlap()
1738 if (fHead && !this->checkOverlap(fHead, coinSeg, oppSeg, coinTs, in debugAddOrOverlap()
1745 if (overlap->coinPtTStart()->fT > test->coinPtTStart()->fT) { in debugAddOrOverlap()
1746 log->record(SkPathOpsDebug::kAddOrOverlap_Glitch, overlap, test->coinPtTStart()); in debugAddOrOverlap()
1748 if (overlap->coinPtTEnd()->fT < test->coinPtTEnd()->fT) { in debugAddOrOverlap()
1749 log->record(SkPathOpsDebug::kAddOrOverlap_Glitch, overlap, test->coinPtTEnd()); in debugAddOrOverlap()
1751 if (overlap->flipped() in debugAddOrOverlap()
1752 ? overlap->oppPtTStart()->fT < test->oppPtTStart()->fT in debugAddOrOverlap()
1753 : overlap->oppPtTStart()->fT > test->oppPtTStart()->fT) { in debugAddOrOverlap()
1754 log->record(SkPathOpsDebug::kAddOrOverlap_Glitch, overlap, test->oppPtTStart()); in debugAddOrOverlap()
1756 if (overlap->flipped() in debugAddOrOverlap()
1757 ? overlap->oppPtTEnd()->fT > test->oppPtTEnd()->fT in debugAddOrOverlap()
1758 : overlap->oppPtTEnd()->fT < test->oppPtTEnd()->fT) { in debugAddOrOverlap()
1759 log->record(SkPathOpsDebug::kAddOrOverlap_Glitch, overlap, test->oppPtTEnd()); in debugAddOrOverlap()
1761 if (!fHead) { this->debugRelease(log, fHead, test); in debugAddOrOverlap()
1762 this->debugRelease(log, fTop, test); in debugAddOrOverlap()
1765 const SkOpPtT* cs = coinSeg->existing(coinTs, oppSeg); in debugAddOrOverlap()
1766 const SkOpPtT* ce = coinSeg->existing(coinTe, oppSeg); in debugAddOrOverlap()
1767 RETURN_FALSE_IF(overlap && cs && ce && overlap->contains(cs, ce), coinSeg); in debugAddOrOverlap()
1769 const SkOpPtT* os = oppSeg->existing(oppTs, coinSeg); in debugAddOrOverlap()
1770 const SkOpPtT* oe = oppSeg->existing(oppTe, coinSeg); in debugAddOrOverlap()
1771 RETURN_FALSE_IF(overlap && os && oe && overlap->contains(os, oe), oppSeg); in debugAddOrOverlap()
1772 SkASSERT(true || !cs || !cs->deleted()); in debugAddOrOverlap()
1773 SkASSERT(true || !os || !os->deleted()); in debugAddOrOverlap()
1774 SkASSERT(true || !ce || !ce->deleted()); in debugAddOrOverlap()
1775 SkASSERT(true || !oe || !oe->deleted()); in debugAddOrOverlap()
1776 const SkOpPtT* csExisting = !cs ? coinSeg->existing(coinTs, nullptr) : nullptr; in debugAddOrOverlap()
1777 const SkOpPtT* ceExisting = !ce ? coinSeg->existing(coinTe, nullptr) : nullptr; in debugAddOrOverlap()
1780 csExisting->contains(ceExisting ? ceExisting : ce)), coinSeg); in debugAddOrOverlap()
1782 ceExisting->contains(csExisting ? csExisting : cs)), coinSeg); in debugAddOrOverlap()
1783 const SkOpPtT* osExisting = !os ? oppSeg->existing(oppTs, nullptr) : nullptr; in debugAddOrOverlap()
1784 const SkOpPtT* oeExisting = !oe ? oppSeg->existing(oppTe, nullptr) : nullptr; in debugAddOrOverlap()
1787 osExisting->contains(oeExisting ? oeExisting : oe)), oppSeg); in debugAddOrOverlap()
1789 oeExisting->contains(osExisting ? osExisting : os)), oppSeg); in debugAddOrOverlap()
1791 this->debugValidate(); in debugAddOrOverlap()
1794 cs = coinSeg->debugAddT(coinTs, log); in debugAddOrOverlap()
1796 os = oppSeg->debugAddT(oppTs, log); in debugAddOrOverlap()
1798 if (cs && os) cs->span()->debugAddOpp(log, os->span()); in debugAddOrOverlap()
1800 // os = osWritable->active(); in debugAddOrOverlap()
1801 RETURN_FALSE_IF((ce && ce->deleted()) || (oe && oe->deleted()), coinSeg); in debugAddOrOverlap()
1805 ce = coinSeg->debugAddT(coinTe, log); in debugAddOrOverlap()
1807 oe = oppSeg->debugAddT(oppTe, log); in debugAddOrOverlap()
1808 if (ce && oe) ce->span()->debugAddOpp(log, oe->span()); in debugAddOrOverlap()
1812 this->debugValidate(); in debugAddOrOverlap()
1817 …RETURN_FALSE_IF(!cs || !ce || cs == ce || cs->contains(ce) || !os || !oe || os == oe || os->contai… in debugAddOrOverlap()
1820 if (overlap->coinPtTStart()->segment() == coinSeg) { in debugAddOrOverlap()
1821 …log->record(SkPathOpsDebug::kAddMissingExtend_Glitch, coinSeg, coinTs, coinTe, oppSeg, oppTs, oppT… in debugAddOrOverlap()
1828 …log->record(SkPathOpsDebug::kAddMissingExtend_Glitch, oppSeg, oppTs, oppTe, coinSeg, coinTs, coinT… in debugAddOrOverlap()
1832 overlap->debugShow(); in debugAddOrOverlap()
1836 …log->record(SkPathOpsDebug::kAddMissingCoin_Glitch, coinSeg, coinTs, coinTe, oppSeg, oppTs, oppTe); in debugAddOrOverlap()
1838 fHead->debugShow(); in debugAddOrOverlap()
1841 this->debugValidate(); in debugAddOrOverlap()
1845 // Extra commented-out lines keep this in sync with addMissing()
1861 const SkOpPtT* ocs = outer->coinPtTStart(); in debugAddMissing()
1862 SkASSERT(!ocs->deleted()); in debugAddMissing()
1863 const SkOpSegment* outerCoin = ocs->segment(); in debugAddMissing()
1864 SkASSERT(!outerCoin->done()); // if it's done, should have already been removed from list in debugAddMissing()
1865 const SkOpPtT* oos = outer->oppPtTStart(); in debugAddMissing()
1866 if (oos->deleted()) { in debugAddMissing()
1869 const SkOpSegment* outerOpp = oos->segment(); in debugAddMissing()
1870 SkASSERT(!outerOpp->done()); in debugAddMissing()
1874 while ((inner = inner->next())) { in debugAddMissing()
1875 this->debugValidate(); in debugAddMissing()
1877 const SkOpPtT* ics = inner->coinPtTStart(); in debugAddMissing()
1878 SkASSERT(!ics->deleted()); in debugAddMissing()
1879 const SkOpSegment* innerCoin = ics->segment(); in debugAddMissing()
1880 SkASSERT(!innerCoin->done()); in debugAddMissing()
1881 const SkOpPtT* ios = inner->oppPtTStart(); in debugAddMissing()
1882 SkASSERT(!ios->deleted()); in debugAddMissing()
1883 const SkOpSegment* innerOpp = ios->segment(); in debugAddMissing()
1884 SkASSERT(!innerOpp->done()); in debugAddMissing()
1888 const SkOpPtT* oce = outer->coinPtTEnd(); in debugAddMissing()
1889 if (oce->deleted()) { in debugAddMissing()
1892 const SkOpPtT* ice = inner->coinPtTEnd(); in debugAddMissing()
1893 SkASSERT(!ice->deleted()); in debugAddMissing()
1894 if (outerOpp != innerOpp && this->overlap(ocs, oce, ics, ice, &overS, &overE)) { in debugAddMissing()
1895 this->debugAddIfMissing(log, ocs->starter(oce), ics->starter(ice), in debugAddMissing()
1897 ocs->debugEnder(oce), in debugAddMissing()
1898 ics->debugEnder(ice)); in debugAddMissing()
1901 const SkOpPtT* oce = outer->coinPtTEnd(); in debugAddMissing()
1902 SkASSERT(!oce->deleted()); in debugAddMissing()
1903 const SkOpPtT* ioe = inner->oppPtTEnd(); in debugAddMissing()
1904 SkASSERT(!ioe->deleted()); in debugAddMissing()
1905 if (outerOpp != innerCoin && this->overlap(ocs, oce, ios, ioe, &overS, &overE)) { in debugAddMissing()
1906 this->debugAddIfMissing(log, ocs->starter(oce), ios->starter(ioe), in debugAddMissing()
1908 ocs->debugEnder(oce), in debugAddMissing()
1909 ios->debugEnder(ioe)); in debugAddMissing()
1912 const SkOpPtT* ooe = outer->oppPtTEnd(); in debugAddMissing()
1913 SkASSERT(!ooe->deleted()); in debugAddMissing()
1914 const SkOpPtT* ice = inner->coinPtTEnd(); in debugAddMissing()
1915 SkASSERT(!ice->deleted()); in debugAddMissing()
1917 if (this->overlap(oos, ooe, ics, ice, &overS, &overE)) { in debugAddMissing()
1918 this->debugAddIfMissing(log, oos->starter(ooe), ics->starter(ice), in debugAddMissing()
1920 oos->debugEnder(ooe), in debugAddMissing()
1921 ics->debugEnder(ice)); in debugAddMissing()
1924 const SkOpPtT* ooe = outer->oppPtTEnd(); in debugAddMissing()
1925 SkASSERT(!ooe->deleted()); in debugAddMissing()
1926 const SkOpPtT* ioe = inner->oppPtTEnd(); in debugAddMissing()
1927 if (ioe->deleted()) { in debugAddMissing()
1931 if (this->overlap(oos, ooe, ios, ioe, &overS, &overE)) { in debugAddMissing()
1932 this->debugAddIfMissing(log, oos->starter(ooe), ios->starter(ioe), in debugAddMissing()
1934 oos->debugEnder(ooe), in debugAddMissing()
1935 ios->debugEnder(ioe)); in debugAddMissing()
1938 this->debugValidate(); in debugAddMissing()
1940 } while ((outer = outer->next())); in debugAddMissing()
1941 // this->restoreHead(); in debugAddMissing()
1945 // Commented-out lines keep this in sync with release()
1951 next = coin->next(); in debugRelease()
1954 // prev->setNext(next); in debugRelease()
1960 log->record(SkPathOpsDebug::kReleasedSpan_Glitch, coin); in debugRelease()
1973 if (coin->coinPtTStart()->segment() == deleted in debugRelease()
1974 || coin->coinPtTEnd()->segment() == deleted in debugRelease()
1975 || coin->oppPtTStart()->segment() == deleted in debugRelease()
1976 || coin->oppPtTEnd()->segment() == deleted) { in debugRelease()
1977 log->record(SkPathOpsDebug::kReleasedSpan_Glitch, coin); in debugRelease()
1979 } while ((coin = coin->next())); in debugRelease()
1982 // Commented-out lines keep this in sync with expand()
1991 if (coin->debugExpand(log)) { in debugExpand()
1998 if (coin->coinPtTStart() == test->coinPtTStart() in debugExpand()
1999 && coin->oppPtTStart() == test->oppPtTStart()) { in debugExpand()
2000 … if (log) log->record(SkPathOpsDebug::kExpandCoin_Glitch, fHead, test->coinPtTStart()); in debugExpand()
2003 } while ((test = test->next())); in debugExpand()
2006 } while ((coin = coin->next())); in debugExpand()
2010 // Commented-out lines keep this in sync with mark()
2018 FAIL_IF_COIN(!coin->coinPtTStartWritable()->span()->upCastable(), coin); in debugMark()
2019 const SkOpSpan* start = coin->coinPtTStartWritable()->span()->upCast(); in debugMark()
2020 // SkASSERT(start->deleted()); in debugMark()
2021 const SkOpSpanBase* end = coin->coinPtTEndWritable()->span(); in debugMark()
2022 // SkASSERT(end->deleted()); in debugMark()
2023 const SkOpSpanBase* oStart = coin->oppPtTStartWritable()->span(); in debugMark()
2024 // SkASSERT(oStart->deleted()); in debugMark()
2025 const SkOpSpanBase* oEnd = coin->oppPtTEndWritable()->span(); in debugMark()
2026 // SkASSERT(oEnd->deleted()); in debugMark()
2027 bool flipped = coin->flipped(); in debugMark()
2034 start->debugInsertCoincidence(log, oStart->upCast()); in debugMark()
2035 end->debugInsertCoinEnd(log, oEnd); in debugMark()
2036 const SkOpSegment* segment = start->segment(); in debugMark()
2037 const SkOpSegment* oSegment = oStart->segment(); in debugMark()
2041 FAIL_IF_COIN(!coin->ordered(&ordered), coin); in debugMark()
2042 while ((next = next->upCast()->next()) != end) { in debugMark()
2043 FAIL_IF_COIN(!next->upCastable(), coin); in debugMark()
2044 next->upCast()->debugInsertCoincidence(log, oSegment, flipped, ordered); in debugMark()
2046 while ((oNext = oNext->upCast()->next()) != oEnd) { in debugMark()
2047 FAIL_IF_COIN(!oNext->upCastable(), coin); in debugMark()
2048 oNext->upCast()->debugInsertCoincidence(log, segment, flipped, ordered); in debugMark()
2050 } while ((coin = coin->next())); in debugMark()
2056 // Commented-out lines keep this in sync with markCollapsed()
2060 if (coin->collapsed(test)) { in debugMarkCollapsed()
2061 if (zero_or_one(coin->coinPtTStart()->fT) && zero_or_one(coin->coinPtTEnd()->fT)) { in debugMarkCollapsed()
2062 log->record(SkPathOpsDebug::kCollapsedCoin_Glitch, coin); in debugMarkCollapsed()
2064 if (zero_or_one(coin->oppPtTStart()->fT) && zero_or_one(coin->oppPtTEnd()->fT)) { in debugMarkCollapsed()
2065 log->record(SkPathOpsDebug::kCollapsedCoin_Glitch, coin); in debugMarkCollapsed()
2067 this->debugRelease(log, head, coin); in debugMarkCollapsed()
2069 coin = coin->next(); in debugMarkCollapsed()
2073 // Commented-out lines keep this in sync with markCollapsed()
2075 this->debugMarkCollapsed(log, fHead, test); in debugMarkCollapsed()
2076 this->debugMarkCollapsed(log, fTop, test); in debugMarkCollapsed()
2081 SkDebugf("coinSpan - id=%d t=%1.9g tEnd=%1.9g\n", coinPtTStart()->segment()->debugID(), in debugShow()
2082 coinPtTStart()->fT, coinPtTEnd()->fT); in debugShow()
2083 SkDebugf("coinSpan + id=%d t=%1.9g tEnd=%1.9g\n", oppPtTStart()->segment()->debugID(), in debugShow()
2084 oppPtTStart()->fT, oppPtTEnd()->fT); in debugShow()
2091 span->debugShow(); in debugShowCoincidence()
2092 span = span->next(); in debugShowCoincidence()
2102 SkASSERT(!next->contains(end) || log); in DebugCheckBetween()
2103 if (next->t() > end->t()) { in DebugCheckBetween()
2108 const SkOpPtT* ptT = next->ptT(); in DebugCheckBetween()
2113 ptT = ptT->next(); in DebugCheckBetween()
2114 const SkOpPtT* checkPtT = next->ptT(); in DebugCheckBetween()
2123 checkPtT = checkPtT->next(); in DebugCheckBetween()
2129 if (ptT->deleted()) { in DebugCheckBetween()
2132 if (ptT->segment() != oSegment) { in DebugCheckBetween()
2135 somethingBetween |= between(oStart, ptT->fT, oEnd); in DebugCheckBetween()
2138 } while (next != end && (next = next->upCast()->next())); in DebugCheckBetween()
2146 const SkOpSegment* coinSeg = test->coinPtTStart()->segment(); in DebugCheckOverlap()
2147 SkASSERT(coinSeg == test->coinPtTEnd()->segment()); in DebugCheckOverlap()
2148 const SkOpSegment* oppSeg = test->oppPtTStart()->segment(); in DebugCheckOverlap()
2149 SkASSERT(oppSeg == test->oppPtTEnd()->segment()); in DebugCheckOverlap()
2150 SkASSERT(coinSeg != test->oppPtTStart()->segment()); in DebugCheckOverlap()
2151 SkDEBUGCODE(double tcs = test->coinPtTStart()->fT); in DebugCheckOverlap()
2153 SkDEBUGCODE(double tce = test->coinPtTEnd()->fT); in DebugCheckOverlap()
2156 double tos = test->oppPtTStart()->fT; in DebugCheckOverlap() local
2157 SkASSERT(between(0, tos, 1)); in DebugCheckOverlap()
2158 double toe = test->oppPtTEnd()->fT; in DebugCheckOverlap()
2160 SkASSERT(tos != toe); in DebugCheckOverlap()
2161 if (tos > toe) { in DebugCheckOverlap()
2163 swap(tos, toe); in DebugCheckOverlap()
2167 if (coinSeg == list->coinPtTStart()->segment()) { in DebugCheckOverlap()
2168 if (oppSeg != list->oppPtTStart()->segment()) { in DebugCheckOverlap()
2171 lcs = list->coinPtTStart()->fT; in DebugCheckOverlap()
2172 lce = list->coinPtTEnd()->fT; in DebugCheckOverlap()
2173 los = list->oppPtTStart()->fT; in DebugCheckOverlap()
2174 loe = list->oppPtTEnd()->fT; in DebugCheckOverlap()
2179 } else if (coinSeg == list->oppPtTStart()->segment()) { in DebugCheckOverlap()
2180 if (oppSeg != list->coinPtTStart()->segment()) { in DebugCheckOverlap()
2183 lcs = list->oppPtTStart()->fT; in DebugCheckOverlap()
2184 lce = list->oppPtTEnd()->fT; in DebugCheckOverlap()
2189 los = list->coinPtTStart()->fT; in DebugCheckOverlap()
2190 loe = list->coinPtTEnd()->fT; in DebugCheckOverlap()
2195 SkASSERT(toe < los || loe < tos); in DebugCheckOverlap()
2196 } while ((list = list->next())); in DebugCheckOverlap()
2205 const SkCoincidentSpans* next = test->next(); in DebugCheckOverlapTop()
2217 SkASSERT(SkOpCoincidence::Ordered(coin->coinPtTStart()->segment(), in DebugValidate()
2218 coin->oppPtTStart()->segment())); in DebugValidate()
2219 SkASSERT(coin->coinPtTStart()->span()->ptT() == coin->coinPtTStart()); in DebugValidate()
2220 SkASSERT(coin->coinPtTEnd()->span()->ptT() == coin->coinPtTEnd()); in DebugValidate()
2221 SkASSERT(coin->oppPtTStart()->span()->ptT() == coin->oppPtTStart()); in DebugValidate()
2222 SkASSERT(coin->oppPtTEnd()->span()->ptT() == coin->oppPtTEnd()); in DebugValidate()
2223 coin = coin->next(); in DebugValidate()
2242 DebugCheckBetween(coin->coinPtTStart()->span(), coin->coinPtTEnd()->span(), in DebugCheckBetween()
2243 coin->oppPtTStart()->fT, coin->oppPtTEnd()->fT, coin->oppPtTStart()->segment(), in DebugCheckBetween()
2245 DebugCheckBetween(coin->oppPtTStart()->span(), coin->oppPtTEnd()->span(), in DebugCheckBetween()
2246 coin->coinPtTStart()->fT, coin->coinPtTEnd()->fT, coin->coinPtTStart()->segment(), in DebugCheckBetween()
2248 coin = coin->next(); in DebugCheckBetween()
2256 if (fGlobalState->debugCheckHealth()) { in debugCheckBetween()
2268 segment->debugCheckHealth(log); in debugCheckHealth()
2269 } while ((segment = segment->next())); in debugCheckHealth()
2285 coin->debugCorrectEnds(log); in debugCorrectEnds()
2286 } while ((coin = coin->next())); in debugCorrectEnds()
2289 // commmented-out lines keep this aligned with missingCoincidence()
2295 segment->debugMissingCoincidence(log); in debugMissingCoincidence()
2296 segment = segment->next(); in debugMissingCoincidence()
2305 segment->debugMoveMultiples(log); in debugMoveMultiples()
2306 } while ((segment = segment->next())); in debugMoveMultiples()
2314 segment->debugMoveNearby(log); in debugMoveNearby()
2315 } while ((segment = segment->next())); in debugMoveNearby()
2321 fDebugBaseIndex = -1; in debugResetCoinT()
2323 fDebugBaseMax = -1; in debugResetCoinT()
2324 fDebugLastIndex = -1; in debugResetCoinT()
2326 fDebugLastMax = -1; in debugResetCoinT()
2335 span->debugResetCoinT(); in debugValidate()
2336 } while (!span->final() && (span = span->upCast()->next())); in debugValidate()
2340 span->debugSetCoinT(index++); in debugValidate()
2341 } while (!span->final() && (span = span->upCast()->next())); in debugValidate()
2345 if (this->globalState()->debugCheckHealth()) { in debugValidate()
2351 double lastT = -1; in debugValidate()
2356 if (!span->final()) { in debugValidate()
2358 done += span->upCast()->done() ? 1 : 0; in debugValidate()
2360 SkASSERT(span->segment() == this); in debugValidate()
2361 SkASSERT(!prev || prev->upCast()->next() == span); in debugValidate()
2362 SkASSERT(!prev || prev == span->prev()); in debugValidate()
2364 double t = span->ptT()->fT; in debugValidate()
2367 span->debugValidate(); in debugValidate()
2368 } while (!span->final() && (span = span->upCast()->next())); in debugValidate()
2372 SkASSERT(span->final()); in debugValidate()
2373 span->debugValidate(); in debugValidate()
2379 // Commented-out lines keep this in sync with addOpp()
2381 const SkOpPtT* oppPrev = this->ptT()->oppPrev(opp->ptT()); in debugAddOpp()
2385 this->debugMergeMatches(log, opp); in debugAddOpp()
2386 this->ptT()->debugAddOpp(opp->ptT(), oppPrev); in debugAddOpp()
2387 this->debugCheckForCollapsedCoincidence(log); in debugAddOpp()
2390 // Commented-out lines keep this in sync with checkForCollapsedCoincidence()
2392 const SkOpCoincidence* coins = this->globalState()->coincidence(); in debugCheckForCollapsedCoincidence()
2393 if (coins->isEmpty()) { in debugCheckForCollapsedCoincidence()
2399 const SkOpPtT* head = this->ptT(); in debugCheckForCollapsedCoincidence()
2402 if (!test->coincident()) { in debugCheckForCollapsedCoincidence()
2405 coins->debugMarkCollapsed(log, test); in debugCheckForCollapsedCoincidence()
2406 } while ((test = test->next()) != head); in debugCheckForCollapsedCoincidence()
2415 nextCoin = next->fCoinEnd; in debugCoinEndLoopCheck()
2416 SkASSERT(nextCoin == this || nextCoin->fCoinEnd != nextCoin); in debugCoinEndLoopCheck()
2417 for (int check = 1; check < loop - 1; ++check) { in debugCoinEndLoopCheck()
2418 const SkOpSpanBase* checkCoin = this->fCoinEnd; in debugCoinEndLoopCheck()
2421 innerCoin = innerCoin->fCoinEnd; in debugCoinEndLoopCheck()
2434 // Commented-out lines keep this in sync with insertCoinEnd()
2437 // SkASSERT(coin->containsCoinEnd(this)); in debugInsertCoinEnd()
2442 log->record(SkPathOpsDebug::kMarkCoinEnd_Glitch, this, coin); in debugInsertCoinEnd()
2443 // coin->fCoinEnd = this->fCoinEnd; in debugInsertCoinEnd()
2444 // this->fCoinEnd = coinNext; in debugInsertCoinEnd()
2448 // Commented-out lines keep this in sync with mergeMatches()
2449 // Look to see if pt-t linked list contains same segment more than once
2450 // if so, and if each pt-t is directly pointed to by spans in that segment,
2453 // spans pointing to the same pt-t loop at different loop elements
2459 testNext = test->next(); in debugMergeMatches()
2460 if (test->deleted()) { in debugMergeMatches()
2463 const SkOpSpanBase* testBase = test->span(); in debugMergeMatches()
2464 SkASSERT(testBase->ptT() == test); in debugMergeMatches()
2465 const SkOpSegment* segment = test->segment(); in debugMergeMatches()
2466 if (segment->done()) { in debugMergeMatches()
2469 const SkOpPtT* inner = opp->ptT(); in debugMergeMatches()
2472 if (inner->segment() != segment) { in debugMergeMatches()
2475 if (inner->deleted()) { in debugMergeMatches()
2478 const SkOpSpanBase* innerBase = inner->span(); in debugMergeMatches()
2479 SkASSERT(innerBase->ptT() == inner); in debugMergeMatches()
2482 // if (!innerBase->hasMultipleHint() && !testBase->hasMultipleHint()) { in debugMergeMatches()
2483 if (!zero_or_one(inner->fT)) { in debugMergeMatches()
2484 log->record(SkPathOpsDebug::kMergeMatches_Glitch, innerBase, test); in debugMergeMatches()
2486 SkASSERT(inner->fT != test->fT); in debugMergeMatches()
2487 if (!zero_or_one(test->fT)) { in debugMergeMatches()
2488 log->record(SkPathOpsDebug::kMergeMatches_Glitch, testBase, inner); in debugMergeMatches()
2490 log->record(SkPathOpsDebug::kMergeMatches_Glitch, segment); in debugMergeMatches()
2491 // SkDEBUGCODE(testBase->debugSetDeleted()); in debugMergeMatches()
2492 // test->setDeleted(); in debugMergeMatches()
2493 // SkDEBUGCODE(innerBase->debugSetDeleted()); in debugMergeMatches()
2494 // inner->setDeleted(); in debugMergeMatches()
2499 while ((debugInner = debugInner->next()) != innerStop) { in debugMergeMatches()
2500 if (debugInner->segment() != segment) { in debugMergeMatches()
2503 if (debugInner->deleted()) { in debugMergeMatches()
2512 } while ((inner = inner->next()) != innerStop); in debugMergeMatches()
2514 this->debugCheckForCollapsedCoincidence(log); in debugMergeMatches()
2523 ptT->debugResetCoinT(); in debugResetCoinT()
2524 ptT = ptT->next(); in debugResetCoinT()
2533 if (!ptT->deleted()) { in debugSetCoinT()
2534 ptT->debugSetCoinT(index); in debugSetCoinT()
2536 ptT = ptT->next(); in debugSetCoinT()
2543 SkASSERT(this->segment() == end->segment()); in debugStarter()
2545 if (t() < end->t()) { in debugStarter()
2551 return result->upCast(); in debugStarter()
2556 if (this->globalState()->debugCheckHealth()) { in debugValidate()
2562 SkASSERT(ptT->span() == this); in debugValidate()
2564 // SkASSERT(SkDPoint::RoughlyEqual(fPtT.fPt, ptT->fPt)); in debugValidate()
2565 ptT->debugValidate(); in debugValidate()
2566 ptT = ptT->next(); in debugValidate()
2568 SkASSERT(this->debugCoinEndLoopCheck()); in debugValidate()
2569 if (!this->final()) { in debugValidate()
2570 SkASSERT(this->upCast()->debugCoinLoopCheck()); in debugValidate()
2573 fFromAngle->debugValidate(); in debugValidate()
2575 if (!this->final() && this->upCast()->toAngle()) { in debugValidate()
2576 this->upCast()->toAngle()->debugValidate(); in debugValidate()
2586 nextCoin = next->fCoincident; in debugCoinLoopCheck()
2587 SkASSERT(nextCoin == this || nextCoin->fCoincident != nextCoin); in debugCoinLoopCheck()
2588 for (int check = 1; check < loop - 1; ++check) { in debugCoinLoopCheck()
2589 const SkOpSpan* checkCoin = this->fCoincident; in debugCoinLoopCheck()
2592 innerCoin = innerCoin->fCoincident; in debugCoinLoopCheck()
2605 // Commented-out lines keep this in sync with insertCoincidence() in header
2608 // SkASSERT(coin->containsCoincidence(this)); in debugInsertCoincidence()
2613 log->record(SkPathOpsDebug::kMarkCoinStart_Glitch, this, coin); in debugInsertCoincidence()
2614 // coin->fCoincident = this->fCoincident; in debugInsertCoincidence()
2615 // this->fCoincident = coinNext; in debugInsertCoincidence()
2619 // Commented-out lines keep this in sync with insertCoincidence()
2621 if (this->containsCoincidence(segment)) { in debugInsertCoincidence()
2625 while ((next = next->next()) != &fPtT) { in debugInsertCoincidence()
2626 if (next->segment() == segment) { in debugInsertCoincidence()
2628 const SkOpSpanBase* base = next->span(); in debugInsertCoincidence()
2630 const SkOpSpanBase* spanEnd = fNext->contains(segment)->span(); in debugInsertCoincidence()
2631 const SkOpPtT* start = base->ptT()->starter(spanEnd->ptT()); in debugInsertCoincidence()
2632 FAIL_IF_COIN(!start->span()->upCastable(), this); in debugInsertCoincidence()
2633 span = const_cast<SkOpSpan*>(start->span()->upCast()); in debugInsertCoincidence()
2636 span = base->prev(); in debugInsertCoincidence()
2640 FAIL_IF_COIN(!base->upCastable(), this); in debugInsertCoincidence()
2641 span = base->upCast(); in debugInsertCoincidence()
2643 log->record(SkPathOpsDebug::kMarkCoinInsert_Glitch, span); in debugInsertCoincidence()
2647 log->record(SkPathOpsDebug::kMarkCoinMissing_Glitch, segment, this); in debugInsertCoincidence()
2674 // Commented-out lines keep this in sync with addOpp()
2676 SkDEBUGCODE(const SkOpPtT* oldNext = this->fNext); in debugAddOpp()
2678 // this->fNext = opp; in debugAddOpp()
2680 // oppPrev->fNext = oldNext; in debugAddOpp()
2688 ptT = ptT->next(); in debugContains()
2698 test = test->next(); in debugContains()
2704 SkASSERT(this->segment() != check); in debugContains()
2708 ptT = ptT->next(); in debugContains()
2709 if (ptT->segment() == check) { in debugContains()
2718 test = test->next(); in debugContains()
2724 return fT < end->fT ? end : this; in debugEnder()
2731 for (int check = 1; check < loop - 1; ++check) { in debugLoopLimit()
2732 const SkOpPtT* checkPtT = this->fNext; in debugLoopLimit()
2735 innerPtT = innerPtT->fNext; in debugLoopLimit()
2744 // there's nothing wrong with extremely large loop counts -- but this may appear to hang in debugLoopLimit()
2746 // -- and it's likely that a large loop count is indicative of a bug somewhere in debugLoopLimit()
2751 } while ((next = next->fNext) && next != this); in debugLoopLimit()
2756 return this->oppPrev(const_cast<SkOpPtT*>(opp)); in debugOppPrev()
2761 this->segment()->debugResetCoinT(); in debugResetCoinT()
2767 this->segment()->debugSetCoinT(index, fT); in debugSetCoinT()
2773 if (this->globalState()->debugCheckHealth()) { in debugValidate()
2778 SkOpPhase phase = contour()->globalState()->phase(); in debugValidate()
2784 SkASSERT(fNext->fNext); in debugValidate()
2797 while (cStr[width - 1] == '0') { in output_scalar()
2798 --width; in output_scalar()
2897 fprintf(file, "%.*s\n", (int) data->size(), (char*) data->data()); in dump_path()
2956 larger.join(two->getBounds()); in debug_scale_matrix()
2966 SkScalar hScale = (bitWidth - 2) / largerWidth; in debug_scale_matrix()
2967 SkScalar vScale = (bitHeight - 2) / largerHeight; in debug_scale_matrix()
2974 SkScalar dx = -16000 > larger.fLeft ? -16000 - larger.fLeft in debug_scale_matrix()
2975 : 16000 < larger.fRight ? 16000 - larger.fRight : 0; in debug_scale_matrix()
2976 SkScalar dy = -16000 > larger.fTop ? -16000 - larger.fTop in debug_scale_matrix()
2977 : 16000 < larger.fBottom ? 16000 - larger.fBottom : 0; in debug_scale_matrix()
2990 canvas.translate(-bounds1.fLeft + 1, -bounds1.fTop + 1); in debug_paths_draw_the_same()
2994 canvas.translate(-bounds1.fLeft + 1 + bitWidth, -bounds1.fTop + 1); in debug_paths_draw_the_same()
2998 for (int y = 0; y < bitHeight - 1; ++y) { in debug_paths_draw_the_same()
3003 for (int x = 0; x < bitWidth - 1; ++x) { in debug_paths_draw_the_same()
3025 openClip.setRect({-16000, -16000, 16000, 16000}); in VerifyOp()
3064 openClip.setRect({-16000, -16000, 16000, 16000}); in VerifySimplify()