Index: src/gpu/effects/GrConstColorProcessor.cpp |
diff --git a/src/gpu/effects/GrConstColorProcessor.cpp b/src/gpu/effects/GrConstColorProcessor.cpp |
index 95a4081d4f7df2421435f51cf9d362f7e15c07ee..627139fa413d2f717c7e77cb2149f5060b3b0583 100644 |
--- a/src/gpu/effects/GrConstColorProcessor.cpp |
+++ b/src/gpu/effects/GrConstColorProcessor.cpp |
@@ -19,7 +19,11 @@ public: |
fColorUniform = args.fBuilder->addUniform(GrGLProgramBuilder::kFragment_Visibility, |
kVec4f_GrSLType, kMedium_GrSLPrecision, "constantColor", |
&colorUni); |
- switch (args.fFp.cast<GrConstColorProcessor>().inputMode()) { |
+ GrConstColorProcessor::InputMode mode = args.fFp.cast<GrConstColorProcessor>().inputMode(); |
+ if (!args.fInputColor) { |
+ mode = GrConstColorProcessor::kIgnore_InputMode; |
+ } |
+ switch (mode) { |
case GrConstColorProcessor::kIgnore_InputMode: |
fsBuilder->codeAppendf("%s = %s;", args.fOutputColor, colorUni); |
break; |