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

Side by Side Diff: gm/conicpaths.cpp

Issue 1606263002: add arc circle gap gm (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 11 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 | « 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 * 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 "gm.h" 8 #include "gm.h"
9 #include "SkCanvas.h" 9 #include "SkCanvas.h"
10 #include "SkPath.h" 10 #include "SkPath.h"
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 125
126 private: 126 private:
127 SkTArray<SkPath> fPaths; 127 SkTArray<SkPath> fPaths;
128 SkPath fGiantCircle; 128 SkPath fGiantCircle;
129 typedef skiagm::GM INHERITED; 129 typedef skiagm::GM INHERITED;
130 }; 130 };
131 DEF_GM(return new ConicPathsGM;) 131 DEF_GM(return new ConicPathsGM;)
132 132
133 ////////////////////////////////////////////////////////////////////////////// 133 //////////////////////////////////////////////////////////////////////////////
134 134
135 /* arc should be on top of circle */
136 DEF_SIMPLE_GM(arccirclegap, canvas, 250, 250) {
137 canvas->translate(50, 100);
138 SkPoint c = { 1052.5390625f, 506.8760978034711f };
139 SkScalar radius = 1096.702150363923f;
140 SkPaint paint;
141 paint.setAntiAlias(true);
142 paint.setStyle(SkPaint::kStroke_Style);
143 canvas->drawCircle(c.fX, c.fY, radius, paint);
144 SkPath path;
145 path.moveTo(288.88884710654133f, -280.26680862609f);
146 path.arcTo(0, 0, -39.00216443306411f, 400.6058925796476f, radius);
147 paint.setColor(0xff007f00);
148 canvas->drawPath(path, paint);
149 }
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