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

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

Issue 1457543003: Add ShaderBuilders to EmitArgs and remove gettings from ProgBuilder. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 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 | « src/effects/gradients/SkGradientShaderPriv.h ('k') | src/effects/gradients/SkRadialGradient.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/effects/gradients/SkLinearGradient.cpp
diff --git a/src/effects/gradients/SkLinearGradient.cpp b/src/effects/gradients/SkLinearGradient.cpp
index ada9d70b6a19af49520d1eaaebd9fad6678704f0..330b2377f4d14a1e3eb6db991c77e0fc5135ab13 100644
--- a/src/effects/gradients/SkLinearGradient.cpp
+++ b/src/effects/gradients/SkLinearGradient.cpp
@@ -528,9 +528,13 @@ const GrFragmentProcessor* GrLinearGradient::TestCreate(GrProcessorTestData* d)
void GrGLLinearGradient::emitCode(EmitArgs& args) {
const GrLinearGradient& ge = args.fFp.cast<GrLinearGradient>();
this->emitUniforms(args.fBuilder, ge);
- SkString t = args.fBuilder->getFragmentShaderBuilder()->ensureFSCoords2D(args.fCoords, 0);
+ SkString t = args.fFragBuilder->ensureFSCoords2D(args.fCoords, 0);
t.append(".x");
- this->emitColor(args.fBuilder, ge, t.c_str(), args.fOutputColor, args.fInputColor,
+ this->emitColor(args.fBuilder,
+ args.fFragBuilder,
+ ge, t.c_str(),
+ args.fOutputColor,
+ args.fInputColor,
args.fSamplers);
}
« no previous file with comments | « src/effects/gradients/SkGradientShaderPriv.h ('k') | src/effects/gradients/SkRadialGradient.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698