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

Unified Diff: src/gpu/gl/GrGLSL.cpp

Issue 78843006: Minor fix in Ganesh shader generation. (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 7 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/gl/GrGLSL.cpp
diff --git a/src/gpu/gl/GrGLSL.cpp b/src/gpu/gl/GrGLSL.cpp
index 0f740d92904ea420d26494592f3299f31cc55fd5..dce44f3aff6c389425f0c898aee483e0f0281e57 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());
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698