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

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

Issue 635533005: Revert of Cleanup of shader building system (Closed) Base URL: https://skia.googlesource.com/skia.git@solo_gp
Patch Set: Created 6 years, 2 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 | « src/gpu/GrDrawState.cpp ('k') | src/gpu/GrOptDrawState.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 2010 Google Inc. 3 * Copyright 2010 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 10
(...skipping 373 matching lines...) Expand 10 before | Expand all | Expand 10 after
384 break; 384 break;
385 } 385 }
386 if (maxIndex > maxValidIndex) { 386 if (maxIndex > maxValidIndex) {
387 SkFAIL("Index reads outside valid index range."); 387 SkFAIL("Index reads outside valid index range.");
388 } 388 }
389 } 389 }
390 390
391 SkASSERT(drawState.getRenderTarget()); 391 SkASSERT(drawState.getRenderTarget());
392 392
393 if (drawState.hasGeometryProcessor()) { 393 if (drawState.hasGeometryProcessor()) {
394 const GrGeometryProcessor* gp = drawState.getGeometryProcessor()->getPro cessor(); 394 const GrGeometryProcessor* gp = drawState.getGeometryProcessor()->getGeo metryProcessor();
395 int numTextures = gp->numTextures(); 395 int numTextures = gp->numTextures();
396 for (int t = 0; t < numTextures; ++t) { 396 for (int t = 0; t < numTextures; ++t) {
397 GrTexture* texture = gp->texture(t); 397 GrTexture* texture = gp->texture(t);
398 SkASSERT(texture->asRenderTarget() != drawState.getRenderTarget()); 398 SkASSERT(texture->asRenderTarget() != drawState.getRenderTarget());
399 } 399 }
400 } 400 }
401 401
402 for (int s = 0; s < drawState.numColorStages(); ++s) { 402 for (int s = 0; s < drawState.numColorStages(); ++s) {
403 const GrProcessor* effect = drawState.getColorStage(s).getProcessor(); 403 const GrProcessor* effect = drawState.getColorStage(s).getProcessor();
404 int numTextures = effect->numTextures(); 404 int numTextures = effect->numTextures();
(...skipping 746 matching lines...) Expand 10 before | Expand all | Expand 10 after
1151 1151
1152 uint32_t GrDrawTargetCaps::CreateUniqueID() { 1152 uint32_t GrDrawTargetCaps::CreateUniqueID() {
1153 static int32_t gUniqueID = SK_InvalidUniqueID; 1153 static int32_t gUniqueID = SK_InvalidUniqueID;
1154 uint32_t id; 1154 uint32_t id;
1155 do { 1155 do {
1156 id = static_cast<uint32_t>(sk_atomic_inc(&gUniqueID) + 1); 1156 id = static_cast<uint32_t>(sk_atomic_inc(&gUniqueID) + 1);
1157 } while (id == SK_InvalidUniqueID); 1157 } while (id == SK_InvalidUniqueID);
1158 return id; 1158 return id;
1159 } 1159 }
1160 1160
OLDNEW
« no previous file with comments | « src/gpu/GrDrawState.cpp ('k') | src/gpu/GrOptDrawState.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698