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

Side by Side Diff: gm/resizeimagefilter.cpp

Issue 1077763002: Change some more GMs to clear to opaque black, not transparent black. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 8 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/perlinnoise.cpp ('k') | gm/tileimagefilter.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 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 "SkBitmapDevice.h" 9 #include "SkBitmapDevice.h"
10 #include "SkBitmapSource.h" 10 #include "SkBitmapSource.h"
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 canvas->drawOval(ovalRect, paint); 52 canvas->drawOval(ovalRect, paint);
53 canvas->restore(); // for saveLayer 53 canvas->restore(); // for saveLayer
54 canvas->restore(); 54 canvas->restore();
55 } 55 }
56 56
57 virtual SkISize onISize() { 57 virtual SkISize onISize() {
58 return SkISize::Make(520, 100); 58 return SkISize::Make(520, 100);
59 } 59 }
60 60
61 virtual void onDraw(SkCanvas* canvas) { 61 virtual void onDraw(SkCanvas* canvas) {
62 canvas->clear(0x00000000); 62 canvas->clear(SK_ColorBLACK);
63 63
64 SkRect srcRect = SkRect::MakeWH(96, 96); 64 SkRect srcRect = SkRect::MakeWH(96, 96);
65 65
66 SkSize deviceSize = SkSize::Make(16, 16); 66 SkSize deviceSize = SkSize::Make(16, 16);
67 draw(canvas, 67 draw(canvas,
68 srcRect, 68 srcRect,
69 deviceSize, 69 deviceSize,
70 kNone_SkFilterQuality); 70 kNone_SkFilterQuality);
71 71
72 canvas->translate(srcRect.width() + SkIntToScalar(10), 0); 72 canvas->translate(srcRect.width() + SkIntToScalar(10), 0);
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 private: 113 private:
114 typedef GM INHERITED; 114 typedef GM INHERITED;
115 }; 115 };
116 116
117 ////////////////////////////////////////////////////////////////////////////// 117 //////////////////////////////////////////////////////////////////////////////
118 118
119 static GM* MyFactory(void*) { return new ResizeGM; } 119 static GM* MyFactory(void*) { return new ResizeGM; }
120 static GMRegistry reg(MyFactory); 120 static GMRegistry reg(MyFactory);
121 121
122 } 122 }
OLDNEW
« no previous file with comments | « gm/perlinnoise.cpp ('k') | gm/tileimagefilter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698