aboutsummaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/gpu/gl/GrGLSL.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/gpu/gl/GrGLSL.cpp b/src/gpu/gl/GrGLSL.cpp
index 0f740d9290..dce44f3aff 100644
--- a/src/gpu/gl/GrGLSL.cpp
+++ b/src/gpu/gl/GrGLSL.cpp
@@ -86,6 +86,7 @@ void GrGLSLMulVarBy4f(SkString* outAppend,
if (mulFactor.isZeros()) {
outAppend->appendf("%s = vec4(0);\n", vec4VarName);
+ } else {
+ outAppend->appendf("%s *= %s;\n", vec4VarName, mulFactor.c_str());
}
- outAppend->appendf("%s *= %s;\n", vec4VarName, mulFactor.c_str());
}