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

Side by Side Diff: src/pathops/SkPathOpsDebug.h

Issue 239563004: fix minor skp-found bugs (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: fix mac-detected errors Created 6 years, 8 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 unified diff | Download patch
« no previous file with comments | « src/pathops/SkPathOpsCubic.cpp ('k') | src/pathops/SkPathOpsDebug.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #ifndef SkPathOpsDebug_DEFINED 7 #ifndef SkPathOpsDebug_DEFINED
8 #define SkPathOpsDebug_DEFINED 8 #define SkPathOpsDebug_DEFINED
9 9
10 #include "SkPathOps.h" 10 #include "SkPathOps.h"
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
45 #define DEBUG_ADD_T_PAIR 0 45 #define DEBUG_ADD_T_PAIR 0
46 #define DEBUG_ANGLE 0 46 #define DEBUG_ANGLE 0
47 #define DEBUG_AS_C_CODE 1 47 #define DEBUG_AS_C_CODE 1
48 #define DEBUG_ASSEMBLE 0 48 #define DEBUG_ASSEMBLE 0
49 #define DEBUG_CHECK_ENDS 0 49 #define DEBUG_CHECK_ENDS 0
50 #define DEBUG_CHECK_TINY 0 50 #define DEBUG_CHECK_TINY 0
51 #define DEBUG_CONCIDENT 0 51 #define DEBUG_CONCIDENT 0
52 #define DEBUG_CROSS 0 52 #define DEBUG_CROSS 0
53 #define DEBUG_FLAT_QUADS 0 53 #define DEBUG_FLAT_QUADS 0
54 #define DEBUG_FLOW 0 54 #define DEBUG_FLOW 0
55 #define DEBUG_LIMIT_WIND_SUM 0
55 #define DEBUG_MARK_DONE 0 56 #define DEBUG_MARK_DONE 0
56 #define DEBUG_PATH_CONSTRUCTION 0 57 #define DEBUG_PATH_CONSTRUCTION 0
57 #define DEBUG_SHOW_TEST_NAME 0 58 #define DEBUG_SHOW_TEST_NAME 0
58 #define DEBUG_SHOW_TEST_PROGRESS 0 59 #define DEBUG_SHOW_TEST_PROGRESS 0
59 #define DEBUG_SHOW_WINDING 0 60 #define DEBUG_SHOW_WINDING 0
60 #define DEBUG_SORT 0 61 #define DEBUG_SORT 0
61 #define DEBUG_SORT_COMPACT 0 62 #define DEBUG_SORT_COMPACT 0
62 #define DEBUG_SORT_RAW 0 63 #define DEBUG_SORT_RAW 0
63 #define DEBUG_SORT_SINGLE 0 64 #define DEBUG_SORT_SINGLE 0
64 #define DEBUG_SWAP_TOP 0 65 #define DEBUG_SWAP_TOP 0
(...skipping 13 matching lines...) Expand all
78 #define DEBUG_ADD_T_PAIR 1 79 #define DEBUG_ADD_T_PAIR 1
79 #define DEBUG_ANGLE 1 80 #define DEBUG_ANGLE 1
80 #define DEBUG_AS_C_CODE 1 81 #define DEBUG_AS_C_CODE 1
81 #define DEBUG_ASSEMBLE 1 82 #define DEBUG_ASSEMBLE 1
82 #define DEBUG_CHECK_ENDS 1 83 #define DEBUG_CHECK_ENDS 1
83 #define DEBUG_CHECK_TINY 1 84 #define DEBUG_CHECK_TINY 1
84 #define DEBUG_CONCIDENT 1 85 #define DEBUG_CONCIDENT 1
85 #define DEBUG_CROSS 01 86 #define DEBUG_CROSS 01
86 #define DEBUG_FLAT_QUADS 0 87 #define DEBUG_FLAT_QUADS 0
87 #define DEBUG_FLOW 1 88 #define DEBUG_FLOW 1
89 #define DEBUG_LIMIT_WIND_SUM 4
88 #define DEBUG_MARK_DONE 1 90 #define DEBUG_MARK_DONE 1
89 #define DEBUG_PATH_CONSTRUCTION 1 91 #define DEBUG_PATH_CONSTRUCTION 1
90 #define DEBUG_SHOW_TEST_NAME 1 92 #define DEBUG_SHOW_TEST_NAME 1
91 #define DEBUG_SHOW_TEST_PROGRESS 1 93 #define DEBUG_SHOW_TEST_PROGRESS 1
92 #define DEBUG_SHOW_WINDING 0 94 #define DEBUG_SHOW_WINDING 0
93 #define DEBUG_SORT 1 95 #define DEBUG_SORT 1
94 #define DEBUG_SORT_COMPACT 0 96 #define DEBUG_SORT_COMPACT 0
95 #define DEBUG_SORT_RAW 0 97 #define DEBUG_SORT_RAW 0
96 #define DEBUG_SORT_SINGLE 0 98 #define DEBUG_SORT_SINGLE 0
97 #define DEBUG_SWAP_TOP 1 99 #define DEBUG_SWAP_TOP 1
98 #define DEBUG_UNSORTABLE 1 100 #define DEBUG_UNSORTABLE 1
99 #define DEBUG_VALIDATE 1 101 #define DEBUG_VALIDATE 0
100 #define DEBUG_WIND_BUMP 0 102 #define DEBUG_WIND_BUMP 0
101 #define DEBUG_WINDING 1 103 #define DEBUG_WINDING 1
102 #define DEBUG_WINDING_AT_T 1 104 #define DEBUG_WINDING_AT_T 1
103 105
104 #endif 106 #endif
105 107
106 #if DEBUG_AS_C_CODE 108 #if DEBUG_AS_C_CODE
107 #define CUBIC_DEBUG_STR "{{%1.9g,%1.9g}, {%1.9g,%1.9g}, {%1.9g,%1.9g}, {%1.9g,%1 .9g}}" 109 #define CUBIC_DEBUG_STR "{{%1.9g,%1.9g}, {%1.9g,%1.9g}, {%1.9g,%1.9g}, {%1.9g,%1 .9g}}"
108 #define QUAD_DEBUG_STR "{{%1.9g,%1.9g}, {%1.9g,%1.9g}, {%1.9g,%1.9g}}" 110 #define QUAD_DEBUG_STR "{{%1.9g,%1.9g}, {%1.9g,%1.9g}, {%1.9g,%1.9g}}"
109 #define LINE_DEBUG_STR "{{%1.9g,%1.9g}, {%1.9g,%1.9g}}" 111 #define LINE_DEBUG_STR "{{%1.9g,%1.9g}, {%1.9g,%1.9g}}"
(...skipping 17 matching lines...) Expand all
127 129
128 #if DEBUG_SHOW_TEST_NAME 130 #if DEBUG_SHOW_TEST_NAME
129 #include "SkTLS.h" 131 #include "SkTLS.h"
130 #endif 132 #endif
131 133
132 #include "SkTArray.h" 134 #include "SkTArray.h"
133 #include "SkTDArray.h" 135 #include "SkTDArray.h"
134 136
135 class SkPathOpsDebug { 137 class SkPathOpsDebug {
136 public: 138 public:
137 static int gMaxWindSum; 139 static const char* kLVerbStr[];
138 static int gMaxWindValue;
139 140
140 static const char* kLVerbStr[]; 141 #if defined(SK_DEBUG) || !FORCE_RELEASE
141 static int gContourID; 142 static int gContourID;
142 static int gSegmentID; 143 static int gSegmentID;
144 #endif
143 145
144 #if DEBUG_SORT || DEBUG_SWAP_TOP 146 #if DEBUG_SORT || DEBUG_SWAP_TOP
145 static int gSortCountDefault; 147 static int gSortCountDefault;
146 static int gSortCount; 148 static int gSortCount;
147 #endif 149 #endif
148 150
149 #if DEBUG_ACTIVE_OP 151 #if DEBUG_ACTIVE_OP
150 static const char* kPathOpStr[]; 152 static const char* kPathOpStr[];
151 #endif 153 #endif
152 154
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
206 void DumpSpans(const SkTArray<class SkOpContour* , true>& contours); 208 void DumpSpans(const SkTArray<class SkOpContour* , true>& contours);
207 void DumpSpans(const SkTArray<class SkOpContour, true>* contours); 209 void DumpSpans(const SkTArray<class SkOpContour, true>* contours);
208 void DumpSpans(const SkTArray<class SkOpContour* , true>* contours); 210 void DumpSpans(const SkTArray<class SkOpContour* , true>* contours);
209 211
210 // generates tools/path_sorter.htm and path_visualizer.htm compatible data 212 // generates tools/path_sorter.htm and path_visualizer.htm compatible data
211 void DumpQ(const struct SkDQuad& quad1, const struct SkDQuad& quad2, int testNo) ; 213 void DumpQ(const struct SkDQuad& quad1, const struct SkDQuad& quad2, int testNo) ;
212 214
213 void DumpT(const struct SkDQuad& quad, double t); 215 void DumpT(const struct SkDQuad& quad, double t);
214 216
215 #endif 217 #endif
OLDNEW
« no previous file with comments | « src/pathops/SkPathOpsCubic.cpp ('k') | src/pathops/SkPathOpsDebug.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698