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

Side by Side Diff: src/gpu/GrProcessor.cpp

Issue 820523002: initial changes to add local matrix to primitive processor (Closed) Base URL: https://skia.googlesource.com/skia.git@cleanup-ccm-above-context
Patch Set: 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 | « src/gpu/GrOvalRenderer.cpp ('k') | src/gpu/GrStencilAndCoverTextContext.h » ('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 "GrProcessor.h" 8 #include "GrProcessor.h"
9 #include "GrContext.h" 9 #include "GrContext.h"
10 #include "GrCoordTransform.h" 10 #include "GrCoordTransform.h"
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after
142 return false; 142 return false;
143 } 143 }
144 } 144 }
145 return true; 145 return true;
146 } 146 }
147 147
148 //////////////////////////////////////////////////////////////////////////////// /////////////////// 148 //////////////////////////////////////////////////////////////////////////////// ///////////////////
149 149
150 void GrFragmentProcessor::addCoordTransform(const GrCoordTransform* transform) { 150 void GrFragmentProcessor::addCoordTransform(const GrCoordTransform* transform) {
151 fCoordTransforms.push_back(transform); 151 fCoordTransforms.push_back(transform);
152 fUsesLocalCoords = fUsesLocalCoords || transform->sourceCoords() == kLocal_G rCoordSet;
152 SkDEBUGCODE(transform->setInProcessor();) 153 SkDEBUGCODE(transform->setInProcessor();)
153 } 154 }
154 155
155 bool GrFragmentProcessor::hasSameTransforms(const GrFragmentProcessor& that) con st { 156 bool GrFragmentProcessor::hasSameTransforms(const GrFragmentProcessor& that) con st {
156 if (fCoordTransforms.count() != that.fCoordTransforms.count()) { 157 if (fCoordTransforms.count() != that.fCoordTransforms.count()) {
157 return false; 158 return false;
158 } 159 }
159 int count = fCoordTransforms.count(); 160 int count = fCoordTransforms.count();
160 for (int i = 0; i < count; ++i) { 161 for (int i = 0; i < count; ++i) {
161 if (*fCoordTransforms[i] != *that.fCoordTransforms[i]) { 162 if (*fCoordTransforms[i] != *that.fCoordTransforms[i]) {
(...skipping 18 matching lines...) Expand all
180 181
181 void GrGeometryData::operator delete(void* target) { 182 void GrGeometryData::operator delete(void* target) {
182 GrProcessor_Globals::GetTLS()->release(target); 183 GrProcessor_Globals::GetTLS()->release(target);
183 } 184 }
184 185
185 //////////////////////////////////////////////////////////////////////////////// /////////////////// 186 //////////////////////////////////////////////////////////////////////////////// ///////////////////
186 187
187 // Initial static variable from GrXPFactory 188 // Initial static variable from GrXPFactory
188 int32_t GrXPFactory::gCurrXPFClassID = 189 int32_t GrXPFactory::gCurrXPFClassID =
189 GrXPFactory::kIllegalXPFClassID; 190 GrXPFactory::kIllegalXPFClassID;
OLDNEW
« no previous file with comments | « src/gpu/GrOvalRenderer.cpp ('k') | src/gpu/GrStencilAndCoverTextContext.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698