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

Side by Side Diff: gm/convexpolyclip.cpp

Issue 151843002: Allow GMs ato be used as benchmarks. Make convex_poly_clip opt in. (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Address comments Created 6 years, 10 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 | Annotate | Revision Log
« no previous file with comments | « bench/benchmain.cpp ('k') | gm/gm.h » ('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 /* 2 /*
3 * Copyright 2014 Google Inc. 3 * Copyright 2014 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 "gm.h" 9 #include "gm.h"
10 10
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after
175 0, 1.5f * txtPaint.getTextSize(), 175 0, 1.5f * txtPaint.getTextSize(),
176 txtPaint); 176 txtPaint);
177 canvas->restore(); 177 canvas->restore();
178 x += fBmp.width() + kMargin; 178 x += fBmp.width() + kMargin;
179 } 179 }
180 180
181 y += fBmp.height() + kMargin; 181 y += fBmp.height() + kMargin;
182 } 182 }
183 } 183 }
184 184
185 virtual uint32_t onGetFlags() const {
186 return kAsBench_Flag;
187 }
188
185 private: 189 private:
186 SkTLList<SkPath> fPaths; 190 SkTLList<SkPath> fPaths;
187 SkBitmap fBmp; 191 SkBitmap fBmp;
188 192
189 typedef GM INHERITED; 193 typedef GM INHERITED;
190 }; 194 };
191 195
192 DEF_GM( return SkNEW(ConvexPolyClip); ) 196 DEF_GM( return SkNEW(ConvexPolyClip); )
193 197
194 } 198 }
OLDNEW
« no previous file with comments | « bench/benchmain.cpp ('k') | gm/gm.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698