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

Unified Diff: src/gpu/glsl/GrGLSLPrimitiveProcessor.cpp

Issue 1457543003: Add ShaderBuilders to EmitArgs and remove gettings from ProgBuilder. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 1 month 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/gpu/glsl/GrGLSLPrimitiveProcessor.h ('k') | src/gpu/glsl/GrGLSLProgramBuilder.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/glsl/GrGLSLPrimitiveProcessor.cpp
diff --git a/src/gpu/glsl/GrGLSLPrimitiveProcessor.cpp b/src/gpu/glsl/GrGLSLPrimitiveProcessor.cpp
index abb3abcb0d10d467fe9f9dc374c7ce5466ca6557..70b58cda94f2d85a747dd3dd32d0f73273d83522 100644
--- a/src/gpu/glsl/GrGLSLPrimitiveProcessor.cpp
+++ b/src/gpu/glsl/GrGLSLPrimitiveProcessor.cpp
@@ -33,9 +33,9 @@ SkMatrix GrGLSLPrimitiveProcessor::GetTransformMatrix(const SkMatrix& localMatri
}
void GrGLSLPrimitiveProcessor::setupUniformColor(GrGLSLGPBuilder* pb,
+ GrGLSLFragmentBuilder* fragBuilder,
const char* outputName,
UniformHandle* colorUniform) {
- GrGLSLFragmentBuilder* fs = pb->getFragmentShaderBuilder();
SkASSERT(colorUniform);
const char* stagedLocalVarName;
*colorUniform = pb->addUniform(GrGLSLProgramBuilder::kFragment_Visibility,
@@ -43,5 +43,5 @@ void GrGLSLPrimitiveProcessor::setupUniformColor(GrGLSLGPBuilder* pb,
kDefault_GrSLPrecision,
"Color",
&stagedLocalVarName);
- fs->codeAppendf("%s = %s;", outputName, stagedLocalVarName);
+ fragBuilder->codeAppendf("%s = %s;", outputName, stagedLocalVarName);
}
« no previous file with comments | « src/gpu/glsl/GrGLSLPrimitiveProcessor.h ('k') | src/gpu/glsl/GrGLSLProgramBuilder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698