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

Side by Side Diff: gm/composeshader.cpp

Issue 1842753002: Style bikeshed - remove extraneous whitespace (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 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/complexclip3.cpp ('k') | gm/conicpaths.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 2012 Google Inc. 2 * Copyright 2012 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 "SkCanvas.h" 10 #include "SkCanvas.h"
(...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after
197 paint.setAlpha(alpha); 197 paint.setAlpha(alpha);
198 paint.setShader(shaders[y]); 198 paint.setShader(shaders[y]);
199 canvas->drawRect(r, paint); 199 canvas->drawRect(r, paint);
200 200
201 canvas->translate(r.width() + 5, 0); 201 canvas->translate(r.width() + 5, 0);
202 } 202 }
203 canvas->restore(); 203 canvas->restore();
204 canvas->translate(0, r.height() + 5); 204 canvas->translate(0, r.height() + 5);
205 } 205 }
206 } 206 }
207 207
208 private: 208 private:
209 /** This determines the length and width of the bitmaps used in the ComposeS haders. Values 209 /** This determines the length and width of the bitmaps used in the ComposeS haders. Values
210 * above 20 may cause an SkASSERT to fail in SkSmallAllocator. However, lar ger values will 210 * above 20 may cause an SkASSERT to fail in SkSmallAllocator. However, lar ger values will
211 * work in a release build. You can change this parameter and then compile a release build 211 * work in a release build. You can change this parameter and then compile a release build
212 * to have this GM draw larger bitmaps for easier visual inspection. 212 * to have this GM draw larger bitmaps for easier visual inspection.
213 */ 213 */
214 static const int squareLength = 20; 214 static const int squareLength = 20;
215 215
216 SkBitmap fColorBitmap; 216 SkBitmap fColorBitmap;
217 SkBitmap fAlpha8Bitmap; 217 SkBitmap fAlpha8Bitmap;
218 sk_sp<SkShader> fColorBitmapShader; 218 sk_sp<SkShader> fColorBitmapShader;
219 sk_sp<SkShader> fAlpha8BitmapShader; 219 sk_sp<SkShader> fAlpha8BitmapShader;
220 sk_sp<SkShader> fLinearGradientShader; 220 sk_sp<SkShader> fLinearGradientShader;
221 221
222 typedef GM INHERITED; 222 typedef GM INHERITED;
223 }; 223 };
224 224
225 ////////////////////////////////////////////////////////////////////////////// 225 //////////////////////////////////////////////////////////////////////////////
226 226
227 DEF_GM( return new ComposeShaderGM; ) 227 DEF_GM( return new ComposeShaderGM; )
228 DEF_GM( return new ComposeShaderAlphaGM; ) 228 DEF_GM( return new ComposeShaderAlphaGM; )
229 DEF_GM( return new ComposeShaderBitmapGM; ) 229 DEF_GM( return new ComposeShaderBitmapGM; )
OLDNEW
« no previous file with comments | « gm/complexclip3.cpp ('k') | gm/conicpaths.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698