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

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

Issue 1709153002: Add more specialized fragment builders (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Make MSVC happy Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/gpu/glsl/GrGLSLFragmentShaderBuilder.h ('k') | src/gpu/glsl/GrGLSLPrimitiveProcessor.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/glsl/GrGLSLFragmentShaderBuilder.cpp
diff --git a/src/gpu/glsl/GrGLSLFragmentShaderBuilder.cpp b/src/gpu/glsl/GrGLSLFragmentShaderBuilder.cpp
index 8651827841a103dae9f21fa598e3bf682e49556c..4277cf4a760acad0f993c280a9c8d91fc3f5af3c 100644
--- a/src/gpu/glsl/GrGLSLFragmentShaderBuilder.cpp
+++ b/src/gpu/glsl/GrGLSLFragmentShaderBuilder.cpp
@@ -68,12 +68,15 @@ GrGLSLFragmentShaderBuilder::KeyForFragmentPosition(const GrRenderTarget* dst) {
GrGLSLFragmentShaderBuilder::GrGLSLFragmentShaderBuilder(GrGLSLProgramBuilder* program,
uint8_t fragPosKey)
- : INHERITED(program)
+ : GrGLSLFragmentBuilder(program)
, fSetupFragPosition(false)
, fTopLeftFragPosRead(kTopLeftFragPosRead_FragPosKey == fragPosKey)
+ , fHasCustomColorOutput(false)
, fCustomColorOutputIndex(-1)
+ , fHasSecondaryOutput(false)
, fHasReadDstColor(false)
, fHasReadFragmentPosition(false) {
+ fSubstageIndices.push_back(0);
}
bool GrGLSLFragmentShaderBuilder::enableFeature(GLSLFeature feature) {
@@ -263,7 +266,7 @@ void GrGLSLFragmentShaderBuilder::onFinalize() {
&this->precisionQualifier());
}
-void GrGLSLFragmentBuilder::onBeforeChildProcEmitCode() {
+void GrGLSLFragmentShaderBuilder::onBeforeChildProcEmitCode() {
SkASSERT(fSubstageIndices.count() >= 1);
fSubstageIndices.push_back(0);
// second-to-last value in the fSubstageIndices stack is the index of the child proc
@@ -271,7 +274,7 @@ void GrGLSLFragmentBuilder::onBeforeChildProcEmitCode() {
fMangleString.appendf("_c%d", fSubstageIndices[fSubstageIndices.count() - 2]);
}
-void GrGLSLFragmentBuilder::onAfterChildProcEmitCode() {
+void GrGLSLFragmentShaderBuilder::onAfterChildProcEmitCode() {
SkASSERT(fSubstageIndices.count() >= 2);
fSubstageIndices.pop_back();
fSubstageIndices.back()++;
« no previous file with comments | « src/gpu/glsl/GrGLSLFragmentShaderBuilder.h ('k') | src/gpu/glsl/GrGLSLPrimitiveProcessor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698