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

Unified Diff: src/effects/SkLightingImageFilter.cpp

Issue 1403403003: Update feSpotLight to match spec (Closed) Base URL: https://chromium.googlesource.com/skia.git@master
Patch Set: Created 5 years, 2 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 | « gm/lighting.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/effects/SkLightingImageFilter.cpp
diff --git a/src/effects/SkLightingImageFilter.cpp b/src/effects/SkLightingImageFilter.cpp
index 4265f6e1e53c23137f5ca9db523169c44bde5c40..ec7d72fe2db0c242723343601a8cf853e982fe03 100644
--- a/src/effects/SkLightingImageFilter.cpp
+++ b/src/effects/SkLightingImageFilter.cpp
@@ -855,7 +855,7 @@ public:
: INHERITED(color),
fLocation(location),
fTarget(target),
- fSpecularExponent(SkScalarPin(specularExponent, kSpecularExponentMin, kSpecularExponentMax))
Stephen White 2015/10/16 15:03:10 Although it may not be spec-correct, this was adde
ericrk 2015/10/16 18:36:23 Per offline discussion - going to remove and see i
+ fSpecularExponent(specularExponent)
{
fS = target - location;
fast_normalize(&fS);
@@ -1996,7 +1996,7 @@ void GrGLSpotLight::emitLightColor(GrGLFPBuilder* builder,
lightColorBody.appendf("\t\treturn %s * scale * (cosAngle - %s) * %s;\n",
color, cosOuter, coneScale);
lightColorBody.appendf("\t}\n");
- lightColorBody.appendf("\treturn %s;\n", color);
+ lightColorBody.appendf("\treturn %s * scale;\n", color);
GrGLFragmentBuilder* fsBuilder = builder->getFragmentShaderBuilder();
fsBuilder->emitFunction(kVec3f_GrSLType,
"lightColor",
« no previous file with comments | « gm/lighting.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698