Lines Matching refs:sect2

203     static void BinarySearch(SkTSect* sect1, SkTSect<OppCurve, TCurve>* sect2,
246 void coincidentCheck(SkTSect<OppCurve, TCurve>* sect2);
249 void computePerpendiculars(SkTSect<OppCurve, TCurve>* sect2, SkTSpan<TCurve, OppCurve>* first,
261 static int EndsEqual(const SkTSect* sect1, const SkTSect<OppCurve, TCurve>* sect2,
263 SkTSpan<TCurve, OppCurve>* extractCoincident(SkTSect<OppCurve, TCurve>* sect2,
273 bool matchedDirection(double t, const SkTSect<OppCurve, TCurve>* sect2, double t2) const;
274 void matchedDirCheck(double t, const SkTSect<OppCurve, TCurve>* sect2, double t2,
276 void mergeCoincidence(SkTSect<OppCurve, TCurve>* sect2);
848 bool SkTSect<TCurve, OppCurve>::binarySearchCoin(SkTSect<OppCurve, TCurve>* sect2, double tStart, in binarySearchCoin() argument
857 const OppCurve& opp = sect2->fCurve; in binarySearchCoin()
879 if (sect2->fHead->contains(oppTTest)) { in binarySearchCoin()
924 void SkTSect<TCurve, OppCurve>::coincidentCheck(SkTSect<OppCurve, TCurve>* sect2) { in coincidentCheck() argument
934 sect2->validate(); in coincidentCheck()
935 this->computePerpendiculars(sect2, first, last); in coincidentCheck()
937 sect2->validate(); in coincidentCheck()
941 coinStart = this->extractCoincident(sect2, coinStart, last); in coincidentCheck()
972 void SkTSect<TCurve, OppCurve>::computePerpendiculars(SkTSect<OppCurve, TCurve>* sect2, in computePerpendiculars() argument
974 const OppCurve& opp = sect2->fCurve; in computePerpendiculars()
986 if (sect2->coincidentHasT(perpT)) { in computePerpendiculars()
989 sect2->addForPerp(work, perpT); in computePerpendiculars()
995 if (sect2->coincidentHasT(perpT)) { in computePerpendiculars()
998 sect2->addForPerp(work, perpT); in computePerpendiculars()
1060 SkTSect<OppCurve, TCurve>* sect2, in extractCoincident() argument
1079 && this->binarySearchCoin(sect2, startT, prev->fStartT - startT, &coinStart, in extractCoincident()
1088 SkTSpan<OppCurve, TCurve>* oppHalf = sect2->addSplitAt(oppFirst, oppStartT); in extractCoincident()
1119 sect2->validate(); in extractCoincident()
1121 deleteEmptySpans |= sect2->updateBounded(oppFirst, oppLast, first); in extractCoincident()
1123 sect2->removeSpanRange(oppFirst, oppLast); in extractCoincident()
1126 first->fCoinStart.setPerp(fCurve, first->fStartT, first->fPart[0], sect2->fCurve); in extractCoincident()
1127 first->fCoinEnd.setPerp(fCurve, first->fEndT, first->fPart[TCurve::kPointLast], sect2->fCurve); in extractCoincident()
1136 oppFirst->resetBounds(sect2->fCurve); in extractCoincident()
1139 sect2->validateBounded(); in extractCoincident()
1142 sect2->removeCoincident(oppFirst, true); in extractCoincident()
1145 sect2->deleteEmptySpans(); in extractCoincident()
1148 sect2->validate(); in extractCoincident()
1384 bool SkTSect<TCurve, OppCurve>::matchedDirection(double t, const SkTSect<OppCurve, TCurve>* sect2, in matchedDirection() argument
1387 SkDVector dxdy2 = sect2->fCurve.dxdyAtT(t2); in matchedDirection()
1392 void SkTSect<TCurve, OppCurve>::matchedDirCheck(double t, const SkTSect<OppCurve, TCurve>* sect2, in matchedDirCheck() argument
1395 SkASSERT(*oppMatched == this->matchedDirection(t, sect2, t2)); in matchedDirCheck()
1397 *oppMatched = this->matchedDirection(t, sect2, t2); in matchedDirCheck()
1403 void SkTSect<TCurve, OppCurve>::mergeCoincidence(SkTSect<OppCurve, TCurve>* sect2) { in mergeCoincidence() argument
1445 coin.setPerp(fCurve, midT, midPt, sect2->fCurve); in mergeCoincidence()
1725 const SkTSect<OppCurve, TCurve>* sect2, SkIntersections* intersections) { in EndsEqual() argument
1727 if (sect1->fCurve[0] == sect2->fCurve[0]) { in EndsEqual()
1731 if (sect1->fCurve[0] == sect2->fCurve[OppCurve::kPointLast]) { in EndsEqual()
1735 if (sect1->fCurve[TCurve::kPointLast] == sect2->fCurve[0]) { in EndsEqual()
1739 if (sect1->fCurve[TCurve::kPointLast] == sect2->fCurve[OppCurve::kPointLast]) { in EndsEqual()
1745 && sect1->fCurve[0].approximatelyEqual(sect2->fCurve[0])) { in EndsEqual()
1747 intersections->insertNear(0, 0, sect1->fCurve[0], sect2->fCurve[0]); in EndsEqual()
1750 && sect1->fCurve[0].approximatelyEqual(sect2->fCurve[OppCurve::kPointLast])) { in EndsEqual()
1752 intersections->insertNear(0, 1, sect1->fCurve[0], sect2->fCurve[OppCurve::kPointLast]); in EndsEqual()
1756 && sect1->fCurve[TCurve::kPointLast].approximatelyEqual(sect2->fCurve[0])) { in EndsEqual()
1758 intersections->insertNear(1, 0, sect1->fCurve[TCurve::kPointLast], sect2->fCurve[0]); in EndsEqual()
1761 && sect1->fCurve[TCurve::kPointLast].approximatelyEqual(sect2->fCurve[ in EndsEqual()
1765 sect2->fCurve[OppCurve::kPointLast]); in EndsEqual()
1903 SkTSect<OppCurve, TCurve>* sect2, SkIntersections* intersections) { in BinarySearch() argument
1907 SkDEBUGCODE(sect1->fOppSect = sect2); in BinarySearch()
1908 SkDEBUGCODE(sect2->fOppSect = sect1); in BinarySearch()
1912 SkTSpan<OppCurve, TCurve>* span2 = sect2->fHead; in BinarySearch()
1913 int oppSect, sect = sect1->intersects(span1, sect2, span2, &oppSect); in BinarySearch()
1919 (void) EndsEqual(sect1, sect2, intersections); in BinarySearch()
1923 span2->addBounded(span1, &sect2->fHeap); in BinarySearch()
1930 SkTSpan<OppCurve, TCurve>* largest2 = sect2->boundsMax(); in BinarySearch()
1942 sect1->trim(largest1, sect2); in BinarySearch()
1943 sect1->trim(half1, sect2); in BinarySearch()
1949 SkTSpan<OppCurve, TCurve>* half2 = sect2->addOne(); in BinarySearch()
1950 if (!half2->split(largest2, &sect2->fHeap)) { in BinarySearch()
1953 sect2->trim(largest2, sect1); in BinarySearch()
1954 sect2->trim(half2, sect1); in BinarySearch()
1957 sect2->validate(); in BinarySearch()
1960 && sect2->fActiveCount >= COINCIDENT_SPAN_COUNT) { in BinarySearch()
1961 sect1->coincidentCheck(sect2); in BinarySearch()
1963 sect2->validate(); in BinarySearch()
1966 && sect2->fActiveCount >= COINCIDENT_SPAN_COUNT) { in BinarySearch()
1967 sect1->computePerpendiculars(sect2, sect1->fHead, sect1->tail()); in BinarySearch()
1968 sect2->computePerpendiculars(sect1, sect2->fHead, sect2->tail()); in BinarySearch()
1969 sect1->removeByPerpendicular(sect2); in BinarySearch()
1971 sect2->validate(); in BinarySearch()
1977 sect1->dumpBoth(sect2); in BinarySearch()
1979 if (!sect1->fHead || !sect2->fHead) { in BinarySearch()
1987 sect1->mergeCoincidence(sect2); in BinarySearch()
1990 SkASSERT(sect2->fCoincident); // courtesy check : coincidence only looks at sect 1 in BinarySearch()
2003 int zeroOneSet = EndsEqual(sect1, sect2, intersections); in BinarySearch()
2004 if (!sect1->fHead || !sect2->fHead) { in BinarySearch()
2008 sect2->recoverCollapsed(); in BinarySearch()
2016 if (sect2->fCurve.ptAtT(t).approximatelyEqual(start1)) { in BinarySearch()
2021 const SkTSpan<OppCurve, TCurve>* head2 = sect2->fHead; in BinarySearch()
2023 const SkDPoint& start2 = sect2->fCurve[0]; in BinarySearch()
2036 if (sect2->fCurve.ptAtT(t).approximatelyEqual(end1)) { in BinarySearch()
2041 const SkTSpan<OppCurve, TCurve>* tail2 = sect2->tail(); in BinarySearch()
2043 const SkDPoint& end2 = sect2->fCurve[OppCurve::kPointLast]; in BinarySearch()
2059 SkTSpan<OppCurve, TCurve>* result2 = sect2->fHead; in BinarySearch()
2078 perp.setPerp(sect1->fCurve, midT, midPt, sect2->fCurve); in BinarySearch()