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

Unified Diff: src/effects/gradients/SkTwoPointRadialGradient.cpp

Issue 22854005: GPU Gradients (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: remove dead line of code Created 7 years, 3 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/effects/gradients/SkTwoPointConicalGradient.cpp ('k') | src/gpu/GrContext.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/effects/gradients/SkTwoPointRadialGradient.cpp
diff --git a/src/effects/gradients/SkTwoPointRadialGradient.cpp b/src/effects/gradients/SkTwoPointRadialGradient.cpp
index e8ec73625b76c7bc2be585c7b740047650b16f34..b4b84029124c1222a06ec4eca85f8fbb150c7406 100644
--- a/src/effects/gradients/SkTwoPointRadialGradient.cpp
+++ b/src/effects/gradients/SkTwoPointRadialGradient.cpp
@@ -532,9 +532,10 @@ void GrGLRadial2Gradient::emitCode(GrGLShaderBuilder* builder,
const char* inputColor,
const TextureSamplerArray& samplers) {
- this->emitYCoordUniform(builder);
+ this->emitUniforms(builder, key);
SkString fsCoords;
SkString vsCoordsVarying;
+
GrSLType coordsVaryingType;
this->setupMatrix(builder, key, &fsCoords, &vsCoordsVarying, &coordsVaryingType);
@@ -632,7 +633,7 @@ void GrGLRadial2Gradient::emitCode(GrGLShaderBuilder* builder,
t.printf("-%s / %s", cName.c_str(), bVar.c_str());
}
- this->emitColorLookup(builder, t.c_str(), outputColor, inputColor, samplers[0]);
+ this->emitColor(builder, t.c_str(), key, outputColor, inputColor, samplers);
}
}
@@ -674,10 +675,10 @@ void GrGLRadial2Gradient::setData(const GrGLUniformManager& uman,
GrGLEffect::EffectKey GrGLRadial2Gradient::GenKey(const GrDrawEffect& drawEffect,
const GrGLCaps&) {
enum {
- kIsDegenerate = 1 << kMatrixKeyBitCnt,
+ kIsDegenerate = 1 << kBaseKeyBitCnt,
};
- EffectKey key = GenMatrixKey(drawEffect);
+ EffectKey key = GenBaseGradientKey(drawEffect);
if (drawEffect.castEffect<GrRadial2Gradient>().isDegenerate()) {
key |= kIsDegenerate;
}
« no previous file with comments | « src/effects/gradients/SkTwoPointConicalGradient.cpp ('k') | src/gpu/GrContext.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698