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

Side by Side Diff: gm/dcshader.cpp

Issue 864713002: remove dead SkPersp macros (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 | « no previous file | gm/filltypespersp.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 /* 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 #if SK_SUPPORT_GPU 10 #if SK_SUPPORT_GPU
(...skipping 231 matching lines...) Expand 10 before | Expand all | Expand 10 after
242 fPrims.push_back(SkNEW(Text)); 242 fPrims.push_back(SkNEW(Text));
243 fPrims.push_back(SkNEW(BmpText)); 243 fPrims.push_back(SkNEW(BmpText));
244 } 244 }
245 245
246 void onDraw(SkCanvas* canvas) SK_OVERRIDE { 246 void onDraw(SkCanvas* canvas) SK_OVERRIDE {
247 SkPaint paint; 247 SkPaint paint;
248 SkTArray<SkMatrix> devMats; 248 SkTArray<SkMatrix> devMats;
249 devMats.push_back().reset(); 249 devMats.push_back().reset();
250 devMats.push_back().setRotate(45, 500, 500); 250 devMats.push_back().setRotate(45, 500, 500);
251 devMats.push_back().setRotate(-30, 200, 200); 251 devMats.push_back().setRotate(-30, 200, 200);
252 devMats.back().setPerspX(-SkScalarToPersp(SK_Scalar1 / 2000)); 252 devMats.back().setPerspX(-SK_Scalar1 / 2000);
253 devMats.back().setPerspY(SkScalarToPersp(SK_Scalar1 / 1000)); 253 devMats.back().setPerspY(SK_Scalar1 / 1000);
254 254
255 255
256 SkTArray<SkMatrix> viewMats; 256 SkTArray<SkMatrix> viewMats;
257 viewMats.push_back().setScale(0.75f, 0.75f); 257 viewMats.push_back().setScale(0.75f, 0.75f);
258 viewMats.push_back().setRotate(45, 50, 50); 258 viewMats.push_back().setRotate(45, 50, 50);
259 viewMats.back().postScale(0.5f, 1.1f); 259 viewMats.back().postScale(0.5f, 1.1f);
260 260
261 canvas->translate(10, 20); 261 canvas->translate(10, 20);
262 canvas->save(); 262 canvas->save();
263 SkScalar tx = 0, maxTy = 0; 263 SkScalar tx = 0, maxTy = 0;
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
301 }; 301 };
302 302
303 SkTArray<Prim*> fPrims; 303 SkTArray<Prim*> fPrims;
304 304
305 typedef GM INHERITED; 305 typedef GM INHERITED;
306 }; 306 };
307 307
308 DEF_GM( return SkNEW(DCShaderGM); ) 308 DEF_GM( return SkNEW(DCShaderGM); )
309 } 309 }
310 #endif 310 #endif
OLDNEW
« no previous file with comments | « no previous file | gm/filltypespersp.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698