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

Side by Side Diff: src/utils/debugger/SkObjectParser.cpp

Issue 1470063002: Upgrade debugger to print more SkPath info (isOval & isRRect) (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years 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 | « no previous file | no next file » | 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 /* 2 /*
3 * Copyright 2012 Google Inc. 3 * Copyright 2012 Google Inc.
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 8
9 #include "SkObjectParser.h" 9 #include "SkObjectParser.h"
10 #include "SkData.h" 10 #include "SkData.h"
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after
152 152
153 mPath->append(gConvexityStrings[path.getConvexity()]); 153 mPath->append(gConvexityStrings[path.getConvexity()]);
154 mPath->append(", "); 154 mPath->append(", ");
155 155
156 if (path.isRect(nullptr)) { 156 if (path.isRect(nullptr)) {
157 mPath->append("isRect, "); 157 mPath->append("isRect, ");
158 } else { 158 } else {
159 mPath->append("isNotRect, "); 159 mPath->append("isNotRect, ");
160 } 160 }
161 161
162 if (path.isOval(nullptr)) {
163 mPath->append("isOval, ");
164 } else {
165 mPath->append("isNotOval, ");
166 }
167
168 SkRRect rrect;
169 if (path.isRRect(&rrect)) {
170 mPath->append("isRRect, ");
171 } else {
172 mPath->append("isNotRRect, ");
173 }
174
162 mPath->appendS32(path.countVerbs()); 175 mPath->appendS32(path.countVerbs());
163 mPath->append("V, "); 176 mPath->append("V, ");
164 mPath->appendS32(path.countPoints()); 177 mPath->appendS32(path.countPoints());
165 mPath->append("P): "); 178 mPath->append("P): ");
166 179
167 static const char* gVerbStrings[] = { 180 static const char* gVerbStrings[] = {
168 "Move", "Line", "Quad", "Conic", "Cubic", "Close", "Done" 181 "Move", "Line", "Quad", "Conic", "Cubic", "Close", "Done"
169 }; 182 };
170 static const int gPtsPerVerb[] = { 1, 1, 2, 2, 3, 0, 0 }; 183 static const int gPtsPerVerb[] = { 1, 1, 2, 2, 3, 0, 0 };
171 static const int gPtOffsetPerVerb[] = { 0, 1, 1, 1, 1, 0, 0 }; 184 static const int gPtOffsetPerVerb[] = { 0, 1, 1, 1, 1, 0, 0 };
(...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after
386 } 399 }
387 break; 400 break;
388 } 401 }
389 default: 402 default:
390 decodedText->append("Unknown text encoding."); 403 decodedText->append("Unknown text encoding.");
391 break; 404 break;
392 } 405 }
393 406
394 return decodedText; 407 return decodedText;
395 } 408 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698