Index: samplecode/SampleSlides.cpp |
diff --git a/samplecode/SampleSlides.cpp b/samplecode/SampleSlides.cpp |
index 6899fc111e94c8fa785c8de3fa7bc2e18479c73c..83e91bb4d6299bff6653b75e256c242f68737421 100644 |
--- a/samplecode/SampleSlides.cpp |
+++ b/samplecode/SampleSlides.cpp |
@@ -197,13 +197,13 @@ static SkShader* MakeSweep(const SkPoint pts[2], const GradData& data, SkShader: |
return SkGradientShader::CreateSweep(center.fX, center.fY, data.fColors, data.fPos, data.fCount); |
} |
-static SkShader* Make2Radial(const SkPoint pts[2], const GradData& data, SkShader::TileMode tm) { |
+static SkShader* Make2Conical(const SkPoint pts[2], const GradData& data, SkShader::TileMode tm) { |
SkPoint center0, center1; |
center0.set(SkScalarAve(pts[0].fX, pts[1].fX), |
SkScalarAve(pts[0].fY, pts[1].fY)); |
center1.set(SkScalarInterp(pts[0].fX, pts[1].fX, SkIntToScalar(3)/5), |
SkScalarInterp(pts[0].fY, pts[1].fY, SkIntToScalar(1)/4)); |
- return SkGradientShader::CreateTwoPointRadial( |
+ return SkGradientShader::CreateTwoPointConical( |
center1, (pts[1].fX - pts[0].fX) / 7, |
center0, (pts[1].fX - pts[0].fX) / 2, |
data.fColors, data.fPos, data.fCount, tm); |
@@ -211,7 +211,7 @@ static SkShader* Make2Radial(const SkPoint pts[2], const GradData& data, SkShade |
typedef SkShader* (*GradMaker)(const SkPoint pts[2], const GradData& data, SkShader::TileMode tm); |
static const GradMaker gGradMakers[] = { |
- MakeLinear, MakeRadial, MakeSweep, Make2Radial |
+ MakeLinear, MakeRadial, MakeSweep, Make2Conical |
}; |
static void gradient_slide(SkCanvas* canvas) { |