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

Side by Side Diff: include/core/SkShader.h

Issue 882443007: Remove unused hasLocalMatrix. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 10 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 | no next file » | 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 2006 The Android Open Source Project 2 * Copyright 2006 The Android Open Source Project
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 8
9 #ifndef SkShader_DEFINED 9 #ifndef SkShader_DEFINED
10 #define SkShader_DEFINED 10 #define SkShader_DEFINED
(...skipping 29 matching lines...) Expand all
40 virtual ~SkShader(); 40 virtual ~SkShader();
41 41
42 /** 42 /**
43 * Returns the local matrix. 43 * Returns the local matrix.
44 * 44 *
45 * FIXME: This can be incorrect for a Shader with its own local matrix 45 * FIXME: This can be incorrect for a Shader with its own local matrix
46 * that is also wrapped via CreateLocalMatrixShader. 46 * that is also wrapped via CreateLocalMatrixShader.
47 */ 47 */
48 const SkMatrix& getLocalMatrix() const { return fLocalMatrix; } 48 const SkMatrix& getLocalMatrix() const { return fLocalMatrix; }
49 49
50 /**
51 * Returns true if the local matrix is not an identity matrix.
52 *
53 * FIXME: This can be incorrect for a Shader with its own local matrix
54 * that is also wrapped via CreateLocalMatrixShader.
55 */
56 bool hasLocalMatrix() const { return !fLocalMatrix.isIdentity(); }
57
58 enum TileMode { 50 enum TileMode {
59 /** replicate the edge color if the shader draws outside of its 51 /** replicate the edge color if the shader draws outside of its
60 * original bounds 52 * original bounds
61 */ 53 */
62 kClamp_TileMode, 54 kClamp_TileMode,
63 55
64 /** repeat the shader's image horizontally and vertically */ 56 /** repeat the shader's image horizontally and vertically */
65 kRepeat_TileMode, 57 kRepeat_TileMode,
66 58
67 /** repeat the shader's image horizontally and vertically, alternating 59 /** repeat the shader's image horizontally and vertically, alternating
(...skipping 435 matching lines...) Expand 10 before | Expand all | Expand 10 after
503 // constructors. 495 // constructors.
504 SkMatrix fLocalMatrix; 496 SkMatrix fLocalMatrix;
505 497
506 // So the SkLocalMatrixShader can whack fLocalMatrix in its SkReadBuffer con structor. 498 // So the SkLocalMatrixShader can whack fLocalMatrix in its SkReadBuffer con structor.
507 friend class SkLocalMatrixShader; 499 friend class SkLocalMatrixShader;
508 500
509 typedef SkFlattenable INHERITED; 501 typedef SkFlattenable INHERITED;
510 }; 502 };
511 503
512 #endif 504 #endif
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698