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

Side by Side Diff: gm/drrect.cpp

Issue 806653007: Fix up all the easy virtual ... SK_OVERRIDE cases. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: rebase Created 5 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 | « gm/drawlooper.cpp ('k') | gm/emboss.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 2014 Google Inc. 2 * Copyright 2014 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 "SkRRect.h" 10 #include "SkRRect.h"
11 #include "SkPath.h" 11 #include "SkPath.h"
12 12
13 class DRRectGM : public skiagm::GM { 13 class DRRectGM : public skiagm::GM {
14 public: 14 public:
15 DRRectGM() {} 15 DRRectGM() {}
16 16
17 protected: 17 protected:
18 virtual uint32_t onGetFlags() const SK_OVERRIDE { 18 uint32_t onGetFlags() const SK_OVERRIDE {
19 return kSkipTiled_Flag; 19 return kSkipTiled_Flag;
20 } 20 }
21 21
22 virtual SkString onShortName() SK_OVERRIDE { 22 SkString onShortName() SK_OVERRIDE {
23 return SkString("drrect"); 23 return SkString("drrect");
24 } 24 }
25 25
26 virtual SkISize onISize() SK_OVERRIDE { 26 SkISize onISize() SK_OVERRIDE {
27 return SkISize::Make(640, 480); 27 return SkISize::Make(640, 480);
28 } 28 }
29 29
30 virtual void onDraw(SkCanvas* canvas) SK_OVERRIDE { 30 void onDraw(SkCanvas* canvas) SK_OVERRIDE {
31 SkPaint paint; 31 SkPaint paint;
32 paint.setAntiAlias(true); 32 paint.setAntiAlias(true);
33 33
34 SkRRect outers[4]; 34 SkRRect outers[4];
35 // like squares/circles, to exercise fast-cases in GPU 35 // like squares/circles, to exercise fast-cases in GPU
36 SkRect r = { 0, 0, 100, 100 }; 36 SkRect r = { 0, 0, 100, 100 };
37 SkVector radii[4] = { 37 SkVector radii[4] = {
38 { 0, 0 }, { 30, 1 }, { 10, 40 }, { 40, 40 } 38 { 0, 0 }, { 30, 1 }, { 10, 40 }, { 40, 40 }
39 }; 39 };
40 40
(...skipping 23 matching lines...) Expand all
64 canvas->restore(); 64 canvas->restore();
65 } 65 }
66 } 66 }
67 } 67 }
68 68
69 private: 69 private:
70 typedef GM INHERITED; 70 typedef GM INHERITED;
71 }; 71 };
72 72
73 DEF_GM( return new DRRectGM; ) 73 DEF_GM( return new DRRectGM; )
OLDNEW
« no previous file with comments | « gm/drawlooper.cpp ('k') | gm/emboss.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698