| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2013 Google Inc. | 2 * Copyright 2013 Google Inc. |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
| 5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
| 6 */ | 6 */ |
| 7 | 7 |
| 8 #include "SkMutex.h" | 8 #include "SkMutex.h" |
| 9 #include "SkOpCoincidence.h" | 9 #include "SkOpCoincidence.h" |
| 10 #include "SkOpContour.h" | 10 #include "SkOpContour.h" |
| (...skipping 1076 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1087 SkASSERT(opp == 0 || !FLAGS_runFail); | 1087 SkASSERT(opp == 0 || !FLAGS_runFail); |
| 1088 #endif | 1088 #endif |
| 1089 } | 1089 } |
| 1090 | 1090 |
| 1091 void SkOpAngle::debugValidateNext() const { | 1091 void SkOpAngle::debugValidateNext() const { |
| 1092 #if !FORCE_RELEASE | 1092 #if !FORCE_RELEASE |
| 1093 const SkOpAngle* first = this; | 1093 const SkOpAngle* first = this; |
| 1094 const SkOpAngle* next = first; | 1094 const SkOpAngle* next = first; |
| 1095 SkTDArray<const SkOpAngle*>(angles); | 1095 SkTDArray<const SkOpAngle*>(angles); |
| 1096 do { | 1096 do { |
| 1097 // SK_ALWAYSBREAK(next->fSegment->debugContains(next)); | 1097 // SkASSERT_RELEASE(next->fSegment->debugContains(next)); |
| 1098 angles.push(next); | 1098 angles.push(next); |
| 1099 next = next->next(); | 1099 next = next->next(); |
| 1100 if (next == first) { | 1100 if (next == first) { |
| 1101 break; | 1101 break; |
| 1102 } | 1102 } |
| 1103 SK_ALWAYSBREAK(!angles.contains(next)); | 1103 SkASSERT_RELEASE(!angles.contains(next)); |
| 1104 if (!next) { | 1104 if (!next) { |
| 1105 return; | 1105 return; |
| 1106 } | 1106 } |
| 1107 } while (true); | 1107 } while (true); |
| 1108 #endif | 1108 #endif |
| 1109 } | 1109 } |
| 1110 | 1110 |
| 1111 | 1111 |
| 1112 #if DEBUG_COINCIDENCE | 1112 #if DEBUG_COINCIDENCE |
| 1113 void SkOpCoincidence::debugAddExpanded(const char* id, SkPathOpsDebug::GlitchLog
* log) const { | 1113 void SkOpCoincidence::debugAddExpanded(const char* id, SkPathOpsDebug::GlitchLog
* log) const { |
| (...skipping 731 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1845 #endif | 1845 #endif |
| 1846 SkPath::FillType fillType = path.getFillType(); | 1846 SkPath::FillType fillType = path.getFillType(); |
| 1847 SkASSERT(fillType >= SkPath::kWinding_FillType && fillType <= SkPath::kInver
seEvenOdd_FillType); | 1847 SkASSERT(fillType >= SkPath::kWinding_FillType && fillType <= SkPath::kInver
seEvenOdd_FillType); |
| 1848 if (includeDeclaration) { | 1848 if (includeDeclaration) { |
| 1849 SkDebugf(" SkPath %s;\n", name); | 1849 SkDebugf(" SkPath %s;\n", name); |
| 1850 } | 1850 } |
| 1851 SkDebugf(" %s.setFillType(SkPath::%s);\n", name, gFillTypeStr[fillType]); | 1851 SkDebugf(" %s.setFillType(SkPath::%s);\n", name, gFillTypeStr[fillType]); |
| 1852 iter.setPath(path); | 1852 iter.setPath(path); |
| 1853 showPathContours(iter, name); | 1853 showPathContours(iter, name); |
| 1854 } | 1854 } |
| OLD | NEW |