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

Side by Side Diff: include/gpu/GrPaint.h

Issue 793013003: Remove the low hanging fruit with coord change matrices (Closed) Base URL: https://skia.googlesource.com/skia.git@more-ccm-cleanup
Patch Set: comment cleanup Created 6 years 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 | src/effects/SkBlurMaskFilter.cpp » ('j') | src/gpu/GrBitmapTextContext.cpp » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 1
2 /* 2 /*
3 * Copyright 2011 Google Inc. 3 * Copyright 2011 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 9
10 #ifndef GrPaint_DEFINED 10 #ifndef GrPaint_DEFINED
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 */ 150 */
151 bool isOpaque() const; 151 bool isOpaque() const;
152 152
153 /** 153 /**
154 * Returns true if isOpaque would return true and the paint represents a sol id constant color 154 * Returns true if isOpaque would return true and the paint represents a sol id constant color
155 * draw. If the result is true, constantColor will be updated to contain the constant color. 155 * draw. If the result is true, constantColor will be updated to contain the constant color.
156 */ 156 */
157 bool isOpaqueAndConstantColor(GrColor* constantColor) const; 157 bool isOpaqueAndConstantColor(GrColor* constantColor) const;
158 158
159 /** 159 /**
160 * Called when the source coord system from which geometry is rendered chang es. It ensures that 160 * DO NOT USE THESE
161 * the local coordinates seen by effects remains unchanged. oldToNew gives t he transformation 161 * TODO Remove remaining use cases and delete these
162 * from the previous coord system to the new coord system.
163 */ 162 */
164 void localCoordChange(const SkMatrix& oldToNew) { 163 void localCoordChange(const SkMatrix& oldToNew) {
165 for (int i = 0; i < fColorStages.count(); ++i) { 164 for (int i = 0; i < fColorStages.count(); ++i) {
166 fColorStages[i].localCoordChange(oldToNew); 165 fColorStages[i].localCoordChange(oldToNew);
167 } 166 }
168 for (int i = 0; i < fCoverageStages.count(); ++i) { 167 for (int i = 0; i < fCoverageStages.count(); ++i) {
169 fCoverageStages[i].localCoordChange(oldToNew); 168 fCoverageStages[i].localCoordChange(oldToNew);
170 } 169 }
171 } 170 }
172 171
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
216 } 215 }
217 216
218 void resetColor() { 217 void resetColor() {
219 fColor = GrColorPackRGBA(0xff, 0xff, 0xff, 0xff); 218 fColor = GrColorPackRGBA(0xff, 0xff, 0xff, 0xff);
220 } 219 }
221 220
222 void resetStages(); 221 void resetStages();
223 }; 222 };
224 223
225 #endif 224 #endif
OLDNEW
« no previous file with comments | « no previous file | src/effects/SkBlurMaskFilter.cpp » ('j') | src/gpu/GrBitmapTextContext.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698