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

Side by Side Diff: gm/filterindiabox.cpp

Issue 831113002: Cleanup: More override fixes - another round. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 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/filterbitmap.cpp ('k') | gm/fontmgr.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 2011 Google Inc. 2 * Copyright 2011 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 9
10 #include "Resources.h" 10 #include "Resources.h"
(...skipping 25 matching lines...) Expand all
36 } 36 }
37 37
38 static void draw_row(SkCanvas* canvas, const SkBitmap& bm, const SkMatrix& mat, SkScalar dx) { 38 static void draw_row(SkCanvas* canvas, const SkBitmap& bm, const SkMatrix& mat, SkScalar dx) {
39 draw_cell(canvas, bm, mat, 0 * dx, SkPaint::kNone_FilterLevel); 39 draw_cell(canvas, bm, mat, 0 * dx, SkPaint::kNone_FilterLevel);
40 draw_cell(canvas, bm, mat, 1 * dx, SkPaint::kLow_FilterLevel); 40 draw_cell(canvas, bm, mat, 1 * dx, SkPaint::kLow_FilterLevel);
41 draw_cell(canvas, bm, mat, 2 * dx, SkPaint::kMedium_FilterLevel); 41 draw_cell(canvas, bm, mat, 2 * dx, SkPaint::kMedium_FilterLevel);
42 draw_cell(canvas, bm, mat, 3 * dx, SkPaint::kHigh_FilterLevel); 42 draw_cell(canvas, bm, mat, 3 * dx, SkPaint::kHigh_FilterLevel);
43 } 43 }
44 44
45 class FilterIndiaBoxGM : public skiagm::GM { 45 class FilterIndiaBoxGM : public skiagm::GM {
46 void onOnceBeforeDraw() { 46 void onOnceBeforeDraw() SK_OVERRIDE {
47 this->makeBitmap(); 47 this->makeBitmap();
48 48
49 SkScalar cx = SkScalarHalf(fBM.width()); 49 SkScalar cx = SkScalarHalf(fBM.width());
50 SkScalar cy = SkScalarHalf(fBM.height()); 50 SkScalar cy = SkScalarHalf(fBM.height());
51 51
52 float vertScale = 30.0f/55.0f; 52 float vertScale = 30.0f/55.0f;
53 float horizScale = 150.0f/200.0f; 53 float horizScale = 150.0f/200.0f;
54 54
55 fMatrix[0].setScale(horizScale, vertScale); 55 fMatrix[0].setScale(horizScale, vertScale);
56 fMatrix[1].setRotate(30, cx, cy); fMatrix[1].postScale(horizScale, vertS cale); 56 fMatrix[1].setRotate(30, cx, cy); fMatrix[1].postScale(horizScale, vertS cale);
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
123 fSize = fBM.height(); 123 fSize = fBM.height();
124 } 124 }
125 private: 125 private:
126 typedef skiagm::GM INHERITED; 126 typedef skiagm::GM INHERITED;
127 }; 127 };
128 128
129 ////////////////////////////////////////////////////////////////////////////// 129 //////////////////////////////////////////////////////////////////////////////
130 130
131 131
132 DEF_GM( return new FilterIndiaBoxGM("box.gif"); ) 132 DEF_GM( return new FilterIndiaBoxGM("box.gif"); )
OLDNEW
« no previous file with comments | « gm/filterbitmap.cpp ('k') | gm/fontmgr.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698