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

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

Issue 1225923010: Refugee from Dead Machine 4: MDB Monster Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Last update from dead machine Created 4 years, 8 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/SkSweepGradient.h ('k') | src/effects/gradients/SkTwoPointConicalGradient.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/effects/gradients/SkSweepGradient.cpp
diff --git a/src/effects/gradients/SkSweepGradient.cpp b/src/effects/gradients/SkSweepGradient.cpp
index 172c7d152ab1bf3b6600a94ae35647ecd7198157..98a308dfc7a2bfbc84e1ea57d3207d1dc2890d24 100644
--- a/src/effects/gradients/SkSweepGradient.cpp
+++ b/src/effects/gradients/SkSweepGradient.cpp
@@ -192,9 +192,9 @@ private:
class GrSweepGradient : public GrGradientEffect {
public:
- static GrFragmentProcessor* Create(GrContext* ctx, const SkSweepGradient& shader,
- const SkMatrix& m) {
- return new GrSweepGradient(ctx, shader, m);
+ static GrFragmentProcessor* Create(GrContext* ctx,
+ const SkSweepGradient& shader, const SkMatrix& m, GrRenderTarget* dst) {
+ return new GrSweepGradient(ctx, shader, m, dst);
}
virtual ~GrSweepGradient() { }
@@ -203,8 +203,8 @@ public:
private:
GrSweepGradient(GrContext* ctx,
const SkSweepGradient& shader,
- const SkMatrix& matrix)
- : INHERITED(ctx, shader, matrix, SkShader::kClamp_TileMode) {
+ const SkMatrix& matrix, GrRenderTarget* dst)
+ : INHERITED(ctx, shader, matrix, SkShader::kClamp_TileMode, dst) {
this->initClassID<GrSweepGradient>();
}
@@ -238,7 +238,8 @@ const GrFragmentProcessor* GrSweepGradient::TestCreate(GrProcessorTestData* d) {
colors, stops, colorCount));
const GrFragmentProcessor* fp = shader->asFragmentProcessor(d->fContext,
GrTest::TestMatrix(d->fRandom),
- NULL, kNone_SkFilterQuality);
+ NULL, kNone_SkFilterQuality,
+ NULL);
GrAlwaysAssert(fp);
return fp;
}
@@ -271,7 +272,8 @@ const GrFragmentProcessor* SkSweepGradient::asFragmentProcessor(
GrContext* context,
const SkMatrix& viewM,
const SkMatrix* localMatrix,
- SkFilterQuality) const {
+ SkFilterQuality,
+ GrRenderTarget* dst) const {
SkMatrix matrix;
if (!this->getLocalMatrix().invert(&matrix)) {
@@ -287,7 +289,7 @@ const GrFragmentProcessor* SkSweepGradient::asFragmentProcessor(
matrix.postConcat(fPtsToUnit);
SkAutoTUnref<const GrFragmentProcessor> inner(
- GrSweepGradient::Create(context, *this, matrix));
+ GrSweepGradient::Create(context, *this, matrix, dst));
return GrFragmentProcessor::MulOutputByInputAlpha(inner);
}
« no previous file with comments | « src/effects/gradients/SkSweepGradient.h ('k') | src/effects/gradients/SkTwoPointConicalGradient.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698