Index: src/core/SkDraw.cpp |
diff --git a/src/core/SkDraw.cpp b/src/core/SkDraw.cpp |
index f69137f6b8bb003e1538a5e4c2db45e7c2a3305c..c42d3ef9ed6636e3895e426805d8e0b5ad52ba65 100644 |
--- a/src/core/SkDraw.cpp |
+++ b/src/core/SkDraw.cpp |
@@ -936,22 +936,6 @@ static SkScalar fast_len(const SkVector& vec) { |
return x + SkScalarHalf(y); |
} |
-static bool xfermodeSupportsCoverageAsAlpha(SkXfermode* xfer) { |
- SkXfermode::Coeff dc; |
- if (!SkXfermode::AsCoeff(xfer, NULL, &dc)) { |
- return false; |
- } |
- |
- switch (dc) { |
- case SkXfermode::kOne_Coeff: |
- case SkXfermode::kISA_Coeff: |
- case SkXfermode::kISC_Coeff: |
- return true; |
- default: |
- return false; |
- } |
-} |
- |
bool SkDrawTreatAAStrokeAsHairline(SkScalar strokeWidth, const SkMatrix& matrix, |
SkScalar* coverage) { |
SkASSERT(strokeWidth > 0); |
@@ -1063,7 +1047,7 @@ void SkDraw::drawPath(const SkPath& origSrcPath, const SkPaint& origPaint, |
if (SkDrawTreatAsHairline(origPaint, *matrix, &coverage)) { |
if (SK_Scalar1 == coverage) { |
paint.writable()->setStrokeWidth(0); |
- } else if (xfermodeSupportsCoverageAsAlpha(origPaint.getXfermode())) { |
+ } else if (SkXfermode::SupportsCoverageAsAlpha(origPaint.getXfermode())) { |
U8CPU newAlpha; |
#if 0 |
newAlpha = SkToU8(SkScalarRoundToInt(coverage * |