Index: src/effects/gradients/SkLinearGradient.cpp |
diff --git a/src/effects/gradients/SkLinearGradient.cpp b/src/effects/gradients/SkLinearGradient.cpp |
index d518cc700f954a8e023c8f5fe1bcb641917eacc9..113877cfe089a3f55055edce451840ef421f1fa3 100644 |
--- a/src/effects/gradients/SkLinearGradient.cpp |
+++ b/src/effects/gradients/SkLinearGradient.cpp |
@@ -480,10 +480,10 @@ private: |
class GrLinearGradient : public GrGradientEffect { |
public: |
- static GrEffectRef* Create(GrContext* ctx, |
- const SkLinearGradient& shader, |
- const SkMatrix& matrix, |
- SkShader::TileMode tm) { |
+ static GrEffect* Create(GrContext* ctx, |
+ const SkLinearGradient& shader, |
+ const SkMatrix& matrix, |
+ SkShader::TileMode tm) { |
return SkNEW_ARGS(GrLinearGradient, (ctx, shader, matrix, tm)); |
} |
@@ -511,10 +511,10 @@ private: |
GR_DEFINE_EFFECT_TEST(GrLinearGradient); |
-GrEffectRef* GrLinearGradient::TestCreate(SkRandom* random, |
- GrContext* context, |
- const GrDrawTargetCaps&, |
- GrTexture**) { |
+GrEffect* GrLinearGradient::TestCreate(SkRandom* random, |
+ GrContext* context, |
+ const GrDrawTargetCaps&, |
+ GrTexture**) { |
SkPoint points[] = {{random->nextUScalar1(), random->nextUScalar1()}, |
{random->nextUScalar1(), random->nextUScalar1()}}; |
@@ -527,9 +527,9 @@ GrEffectRef* GrLinearGradient::TestCreate(SkRandom* random, |
colors, stops, colorCount, |
tm)); |
SkPaint paint; |
- GrColor grColor; |
- GrEffectRef* effect; |
- shader->asNewEffect(context, paint, NULL, &grColor, &effect); |
+ GrColor paintColor; |
+ GrEffect* effect; |
+ SkAssertResult(shader->asNewEffect(context, paint, NULL, &paintColor, &effect)); |
return effect; |
} |
@@ -551,8 +551,8 @@ void GrGLLinearGradient::emitCode(GrGLShaderBuilder* builder, |
///////////////////////////////////////////////////////////////////// |
bool SkLinearGradient::asNewEffect(GrContext* context, const SkPaint& paint, |
- const SkMatrix* localMatrix, GrColor* grColor, |
- GrEffectRef** grEffect) const { |
+ const SkMatrix* localMatrix, GrColor* paintColor, |
+ GrEffect** effect) const { |
SkASSERT(NULL != context); |
SkMatrix matrix; |
@@ -568,8 +568,8 @@ bool SkLinearGradient::asNewEffect(GrContext* context, const SkPaint& paint, |
} |
matrix.postConcat(fPtsToUnit); |
- *grColor = SkColor2GrColorJustAlpha(paint.getColor()); |
- *grEffect = GrLinearGradient::Create(context, *this, matrix, fTileMode); |
+ *paintColor = SkColor2GrColorJustAlpha(paint.getColor()); |
+ *effect = GrLinearGradient::Create(context, *this, matrix, fTileMode); |
return true; |
} |
@@ -577,8 +577,8 @@ bool SkLinearGradient::asNewEffect(GrContext* context, const SkPaint& paint, |
#else |
bool SkLinearGradient::asNewEffect(GrContext* context, const SkPaint& paint, |
- const SkMatrix* localMatrix, GrColor* grColor, |
- GrEffect** grEffect) const { |
+ const SkMatrix* localMatrix, GrColor* paintColor, |
+ GrEffect** effect) const { |
SkDEBUGFAIL("Should not call in GPU-less build"); |
return false; |
} |