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

Side by Side Diff: src/pathops/SkPathOpsTypes.cpp

Issue 1250293002: fix path ops fuzz buster (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: corrupting bug kaput Created 5 years, 5 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/SkPathOpsTypes.h ('k') | tests/PathOpsAngleIdeas.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 2012 Google Inc. 2 * Copyright 2012 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 #include "SkFloatBits.h" 7 #include "SkFloatBits.h"
8 #include "SkOpCoincidence.h" 8 #include "SkOpCoincidence.h"
9 #include "SkPathOpsTypes.h" 9 #include "SkPathOpsTypes.h"
10 10
(...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after
193 if (approximately_zero_cubed(x)) { 193 if (approximately_zero_cubed(x)) {
194 return 0; 194 return 0;
195 } 195 }
196 double result = halley_cbrt3d(fabs(x)); 196 double result = halley_cbrt3d(fabs(x));
197 if (x < 0) { 197 if (x < 0) {
198 result = -result; 198 result = -result;
199 } 199 }
200 return result; 200 return result;
201 } 201 }
202 202
203 SkOpGlobalState::SkOpGlobalState(SkOpCoincidence* coincidence, SkOpContourHead* head) 203 SkOpGlobalState::SkOpGlobalState(SkOpCoincidence* coincidence, SkOpContourHead* head
204 SkDEBUGPARAMS(const char* testName))
204 : fCoincidence(coincidence) 205 : fCoincidence(coincidence)
205 , fContourHead(head) 206 , fContourHead(head)
206 , fNested(0) 207 , fNested(0)
207 , fWindingFailed(false) 208 , fWindingFailed(false)
208 , fAngleCoincidence(false) 209 , fAngleCoincidence(false)
209 , fPhase(kIntersecting) 210 , fPhase(kIntersecting)
211 SkDEBUGPARAMS(fDebugTestName(testName))
210 SkDEBUGPARAMS(fAngleID(0)) 212 SkDEBUGPARAMS(fAngleID(0))
211 SkDEBUGPARAMS(fContourID(0)) 213 SkDEBUGPARAMS(fContourID(0))
212 SkDEBUGPARAMS(fPtTID(0)) 214 SkDEBUGPARAMS(fPtTID(0))
213 SkDEBUGPARAMS(fSegmentID(0)) 215 SkDEBUGPARAMS(fSegmentID(0))
214 SkDEBUGPARAMS(fSpanID(0)) { 216 SkDEBUGPARAMS(fSpanID(0)) {
215 if (coincidence) { 217 if (coincidence) {
216 coincidence->debugSetGlobalState(this); 218 coincidence->debugSetGlobalState(this);
217 } 219 }
218 } 220 }
219 221
OLDNEW
« no previous file with comments | « src/pathops/SkPathOpsTypes.h ('k') | tests/PathOpsAngleIdeas.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698