diff options
Diffstat (limited to 'src/effects')
36 files changed, 0 insertions, 429 deletions
diff --git a/src/effects/Sk1DPathEffect.cpp b/src/effects/Sk1DPathEffect.cpp index 57f2d2b6ce..1837479147 100644 --- a/src/effects/Sk1DPathEffect.cpp +++ b/src/effects/Sk1DPathEffect.cpp @@ -194,14 +194,6 @@ SkScalar SkPath1DPathEffect::next(SkPath* dst, SkScalar distance, return fAdvance; } - -void SkPath1DPathEffect::toString(SkString* str) const { - str->appendf("SkPath1DPathEffect: ("); - // TODO: add path and style - str->appendf("advance: %.2f phase %.2f", fAdvance, fInitialOffset); - str->appendf(")"); -} - /////////////////////////////////////////////////////////////////////////////////////////////////// sk_sp<SkPathEffect> SkPath1DPathEffect::Make(const SkPath& path, SkScalar advance, SkScalar phase, diff --git a/src/effects/Sk2DPathEffect.cpp b/src/effects/Sk2DPathEffect.cpp index a541b91476..6c2c4c2854 100644 --- a/src/effects/Sk2DPathEffect.cpp +++ b/src/effects/Sk2DPathEffect.cpp @@ -74,13 +74,6 @@ void Sk2DPathEffect::flatten(SkWriteBuffer& buffer) const { buffer.writeMatrix(fMatrix); } -void Sk2DPathEffect::toString(SkString* str) const { - str->appendf("(matrix: %.2f %.2f %.2f %.2f %.2f %.2f %.2f %.2f %.2f)", - fMatrix[SkMatrix::kMScaleX], fMatrix[SkMatrix::kMSkewX], fMatrix[SkMatrix::kMTransX], - fMatrix[SkMatrix::kMSkewY], fMatrix[SkMatrix::kMScaleY], fMatrix[SkMatrix::kMTransY], - fMatrix[SkMatrix::kMPersp0], fMatrix[SkMatrix::kMPersp1], fMatrix[SkMatrix::kMPersp2]); -} - /////////////////////////////////////////////////////////////////////////////// bool SkLine2DPathEffect::filterPath(SkPath* dst, const SkPath& src, @@ -117,14 +110,6 @@ void SkLine2DPathEffect::flatten(SkWriteBuffer &buffer) const { buffer.writeScalar(fWidth); } - -void SkLine2DPathEffect::toString(SkString* str) const { - str->appendf("SkLine2DPathEffect: ("); - this->INHERITED::toString(str); - str->appendf("width: %f", fWidth); - str->appendf(")"); -} - /////////////////////////////////////////////////////////////////////////////// SkPath2DPathEffect::SkPath2DPathEffect(const SkMatrix& m, const SkPath& p) @@ -148,11 +133,3 @@ void SkPath2DPathEffect::next(const SkPoint& loc, int u, int v, SkPath* dst) const { dst->addPath(fPath, loc.fX, loc.fY); } - -void SkPath2DPathEffect::toString(SkString* str) const { - str->appendf("SkPath2DPathEffect: ("); - this->INHERITED::toString(str); - // TODO: print out path information - str->appendf(")"); -} - diff --git a/src/effects/SkAlphaThresholdFilter.cpp b/src/effects/SkAlphaThresholdFilter.cpp index f09ec50b67..5bd2571842 100644 --- a/src/effects/SkAlphaThresholdFilter.cpp +++ b/src/effects/SkAlphaThresholdFilter.cpp @@ -31,7 +31,6 @@ public: SkScalar outerThreshold, sk_sp<SkImageFilter> input, const CropRect* cropRect = nullptr); - void toString(SkString* str) const override; SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkAlphaThresholdFilterImpl) friend void SkAlphaThresholdFilter::InitializeFlattenables(); @@ -281,10 +280,3 @@ const { } return this->refMe(); } - -void SkAlphaThresholdFilterImpl::toString(SkString* str) const { - str->appendf("SkAlphaThresholdImageFilter: ("); - str->appendf("inner: %f outer: %f", fInnerThreshold, fOuterThreshold); - str->append(")"); -} - diff --git a/src/effects/SkArithmeticImageFilter.cpp b/src/effects/SkArithmeticImageFilter.cpp index c022ec955e..578cc0d350 100644 --- a/src/effects/SkArithmeticImageFilter.cpp +++ b/src/effects/SkArithmeticImageFilter.cpp @@ -37,7 +37,6 @@ public: sk_sp<SkImageFilter> inputs[2], const CropRect* cropRect) : INHERITED(inputs, 2, cropRect), fK{k1, k2, k3, k4}, fEnforcePMColor(enforcePMColor) {} - void toString(SkString* str) const override; SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(ArithmeticImageFilterImpl) protected: @@ -432,22 +431,6 @@ const { return this->refMe(); } -void ArithmeticImageFilterImpl::toString(SkString* str) const { - str->appendf("SkArithmeticImageFilter: ("); - str->appendf("K[]: (%f %f %f %f)", fK[0], fK[1], fK[2], fK[3]); - if (this->getInput(0)) { - str->appendf("foreground: ("); - this->getInput(0)->toString(str); - str->appendf(")"); - } - if (this->getInput(1)) { - str->appendf("background: ("); - this->getInput(1)->toString(str); - str->appendf(")"); - } - str->append(")"); -} - sk_sp<SkImageFilter> SkArithmeticImageFilter::Make(float k1, float k2, float k3, float k4, bool enforcePMColor, sk_sp<SkImageFilter> background, diff --git a/src/effects/SkColorFilterImageFilter.cpp b/src/effects/SkColorFilterImageFilter.cpp index 514d04622e..9bea7943e3 100644 --- a/src/effects/SkColorFilterImageFilter.cpp +++ b/src/effects/SkColorFilterImageFilter.cpp @@ -144,18 +144,3 @@ bool SkColorFilterImageFilter::onIsColorFilterNode(SkColorFilter** filter) const bool SkColorFilterImageFilter::affectsTransparentBlack() const { return fColorFilter->affectsTransparentBlack(); } - -void SkColorFilterImageFilter::toString(SkString* str) const { - str->appendf("SkColorFilterImageFilter: ("); - - str->appendf("input: ("); - - if (this->getInput(0)) { - this->getInput(0)->toString(str); - } - - str->appendf(") color filter: "); - fColorFilter->toString(str); - - str->append(")"); -} diff --git a/src/effects/SkColorMatrixFilter.cpp b/src/effects/SkColorMatrixFilter.cpp index 7a562b4aa0..c68c47e884 100644 --- a/src/effects/SkColorMatrixFilter.cpp +++ b/src/effects/SkColorMatrixFilter.cpp @@ -72,8 +72,6 @@ public: } #endif - void toString(SkString* str) const override { fMatrixFilter->toString(str); } - private: SkColor fMul, fAdd; sk_sp<SkColorFilter> fMatrixFilter; diff --git a/src/effects/SkComposeImageFilter.cpp b/src/effects/SkComposeImageFilter.cpp index 51cec9c671..842588d9c6 100644 --- a/src/effects/SkComposeImageFilter.cpp +++ b/src/effects/SkComposeImageFilter.cpp @@ -88,17 +88,3 @@ sk_sp<SkFlattenable> SkComposeImageFilter::CreateProc(SkReadBuffer& buffer) { return SkComposeImageFilter::Make(common.getInput(0), common.getInput(1)); } -void SkComposeImageFilter::toString(SkString* str) const { - SkImageFilter* outer = getInput(0); - SkImageFilter* inner = getInput(1); - - str->appendf("SkComposeImageFilter: ("); - - str->appendf("outer: "); - outer->toString(str); - - str->appendf("inner: "); - inner->toString(str); - - str->appendf(")"); -} diff --git a/src/effects/SkCornerPathEffect.cpp b/src/effects/SkCornerPathEffect.cpp index ec137b9c60..a88bc3224c 100644 --- a/src/effects/SkCornerPathEffect.cpp +++ b/src/effects/SkCornerPathEffect.cpp @@ -151,9 +151,3 @@ sk_sp<SkFlattenable> SkCornerPathEffect::CreateProc(SkReadBuffer& buffer) { void SkCornerPathEffect::flatten(SkWriteBuffer& buffer) const { buffer.writeScalar(fRadius); } - -void SkCornerPathEffect::toString(SkString* str) const { - str->appendf("SkCornerPathEffect: ("); - str->appendf("radius: %.2f", fRadius); - str->appendf(")"); -} diff --git a/src/effects/SkDashImpl.h b/src/effects/SkDashImpl.h index f5c4244dc3..f2c8255772 100644 --- a/src/effects/SkDashImpl.h +++ b/src/effects/SkDashImpl.h @@ -21,7 +21,6 @@ public: DashType asADash(DashInfo* info) const override; - void toString(SkString* str) const override; SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkDashImpl) #ifdef SK_BUILD_FOR_ANDROID_FRAMEWORK diff --git a/src/effects/SkDashPathEffect.cpp b/src/effects/SkDashPathEffect.cpp index cdadcf907d..7f003da6ab 100644 --- a/src/effects/SkDashPathEffect.cpp +++ b/src/effects/SkDashPathEffect.cpp @@ -380,18 +380,6 @@ sk_sp<SkFlattenable> SkDashImpl::CreateProc(SkReadBuffer& buffer) { return nullptr; } -void SkDashImpl::toString(SkString* str) const { - str->appendf("SkDashPathEffect: ("); - str->appendf("count: %d phase %.2f intervals: (", fCount, fPhase); - for (int i = 0; i < fCount; ++i) { - str->appendf("%.2f", fIntervals[i]); - if (i < fCount-1) { - str->appendf(", "); - } - } - str->appendf("))"); -} - ////////////////////////////////////////////////////////////////////////////////////////////////// sk_sp<SkPathEffect> SkDashPathEffect::Make(const SkScalar intervals[], int count, SkScalar phase) { diff --git a/src/effects/SkDiscretePathEffect.cpp b/src/effects/SkDiscretePathEffect.cpp index 57d8f9639e..46cd42bece 100644 --- a/src/effects/SkDiscretePathEffect.cpp +++ b/src/effects/SkDiscretePathEffect.cpp @@ -143,9 +143,3 @@ void SkDiscretePathEffect::flatten(SkWriteBuffer& buffer) const { buffer.writeScalar(fPerterb); buffer.writeUInt(fSeedAssist); } - -void SkDiscretePathEffect::toString(SkString* str) const { - str->appendf("SkDiscretePathEffect: ("); - str->appendf("segLength: %.2f deviation: %.2f seed %d", fSegLength, fPerterb, fSeedAssist); - str->append(")"); -} diff --git a/src/effects/SkDisplacementMapEffect.cpp b/src/effects/SkDisplacementMapEffect.cpp index d40e521b0a..9dcf0bee45 100644 --- a/src/effects/SkDisplacementMapEffect.cpp +++ b/src/effects/SkDisplacementMapEffect.cpp @@ -404,20 +404,6 @@ SkIRect SkDisplacementMapEffect::onFilterBounds(const SkIRect& src, const SkMatr return src; } -void SkDisplacementMapEffect::toString(SkString* str) const { - str->appendf("SkDisplacementMapEffect: ("); - str->appendf("scale: %f ", fScale); - str->appendf("displacement: ("); - if (this->getDisplacementInput()) { - this->getDisplacementInput()->toString(str); - } - str->appendf(") color: ("); - if (this->getColorInput()) { - this->getColorInput()->toString(str); - } - str->appendf("))"); -} - /////////////////////////////////////////////////////////////////////////////// #if SK_SUPPORT_GPU diff --git a/src/effects/SkDropShadowImageFilter.cpp b/src/effects/SkDropShadowImageFilter.cpp index 7532894bce..d19c05fe5d 100644 --- a/src/effects/SkDropShadowImageFilter.cpp +++ b/src/effects/SkDropShadowImageFilter.cpp @@ -159,24 +159,3 @@ SkIRect SkDropShadowImageFilter::onFilterNodeBounds(const SkIRect& src, const Sk return dst; } -void SkDropShadowImageFilter::toString(SkString* str) const { - str->appendf("SkDropShadowImageFilter: ("); - - str->appendf("dX: %f ", fDx); - str->appendf("dY: %f ", fDy); - str->appendf("sigmaX: %f ", fSigmaX); - str->appendf("sigmaY: %f ", fSigmaY); - - str->append("Color: "); - str->appendHex(fColor); - - static const char* gModeStrings[] = { - "kDrawShadowAndForeground", "kDrawShadowOnly" - }; - - static_assert(kShadowModeCount == SK_ARRAY_COUNT(gModeStrings), "enum_mismatch"); - - str->appendf(" mode: %s", gModeStrings[fShadowMode]); - - str->append(")"); -} diff --git a/src/effects/SkEmbossMaskFilter.cpp b/src/effects/SkEmbossMaskFilter.cpp index 4a4c8d0e34..ef26520172 100644 --- a/src/effects/SkEmbossMaskFilter.cpp +++ b/src/effects/SkEmbossMaskFilter.cpp @@ -140,22 +140,3 @@ void SkEmbossMaskFilter::flatten(SkWriteBuffer& buffer) const { buffer.writeByteArray(&tmpLight, sizeof(tmpLight)); buffer.writeScalar(fBlurSigma); } - -void SkEmbossMaskFilter::toString(SkString* str) const { - str->append("SkEmbossMaskFilter: ("); - - str->append("direction: ("); - str->appendScalar(fLight.fDirection[0]); - str->append(", "); - str->appendScalar(fLight.fDirection[1]); - str->append(", "); - str->appendScalar(fLight.fDirection[2]); - str->append(") "); - - str->appendf("ambient: %d specular: %d ", - fLight.fAmbient, fLight.fSpecular); - - str->append("blurSigma: "); - str->appendScalar(fBlurSigma); - str->append(")"); -} diff --git a/src/effects/SkEmbossMaskFilter.h b/src/effects/SkEmbossMaskFilter.h index bc992a09b5..9c3cb62d93 100644 --- a/src/effects/SkEmbossMaskFilter.h +++ b/src/effects/SkEmbossMaskFilter.h @@ -32,7 +32,6 @@ public: bool filterMask(SkMask* dst, const SkMask& src, const SkMatrix&, SkIPoint* margin) const override; - void toString(SkString* str) const override; SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkEmbossMaskFilter) protected: diff --git a/src/effects/SkHighContrastFilter.cpp b/src/effects/SkHighContrastFilter.cpp index b805212f18..607033ef20 100644 --- a/src/effects/SkHighContrastFilter.cpp +++ b/src/effects/SkHighContrastFilter.cpp @@ -45,8 +45,6 @@ public: SkArenaAlloc* scratch, bool shaderIsOpaque) const override; - void toString(SkString* str) const override; - SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkHighContrast_Filter) protected: @@ -157,10 +155,6 @@ sk_sp<SkColorFilter> SkHighContrastFilter::Make( return sk_make_sp<SkHighContrast_Filter>(config); } -void SkHighContrast_Filter::toString(SkString* str) const { - str->append("SkHighContrastColorFilter "); -} - SK_DEFINE_FLATTENABLE_REGISTRAR_GROUP_START(SkHighContrastFilter) SK_DEFINE_FLATTENABLE_REGISTRAR_ENTRY(SkHighContrast_Filter) SK_DEFINE_FLATTENABLE_REGISTRAR_GROUP_END diff --git a/src/effects/SkImageSource.cpp b/src/effects/SkImageSource.cpp index 0f48fb0c97..960de37b33 100644 --- a/src/effects/SkImageSource.cpp +++ b/src/effects/SkImageSource.cpp @@ -157,12 +157,3 @@ SkIRect SkImageSource::onFilterNodeBounds(const SkIRect& src, const SkMatrix& ct return dstRect.roundOut(); } -void SkImageSource::toString(SkString* str) const { - str->appendf("SkImageSource: ("); - str->appendf("src: (%f,%f,%f,%f) dst: (%f,%f,%f,%f) ", - fSrcRect.fLeft, fSrcRect.fTop, fSrcRect.fRight, fSrcRect.fBottom, - fDstRect.fLeft, fDstRect.fTop, fDstRect.fRight, fDstRect.fBottom); - str->appendf("image: (%d,%d)", - fImage->width(), fImage->height()); - str->append(")"); -} diff --git a/src/effects/SkLayerDrawLooper.cpp b/src/effects/SkLayerDrawLooper.cpp index db61e08c4f..1610809456 100644 --- a/src/effects/SkLayerDrawLooper.cpp +++ b/src/effects/SkLayerDrawLooper.cpp @@ -279,62 +279,6 @@ sk_sp<SkFlattenable> SkLayerDrawLooper::CreateProc(SkReadBuffer& buffer) { return builder.detach(); } -void SkLayerDrawLooper::toString(SkString* str) const { - str->appendf("SkLayerDrawLooper (%d): ", fCount); - - Rec* rec = fRecs; - for (int i = 0; i < fCount; i++) { - str->appendf("%d: paintBits: (", i); - if (0 == rec->fInfo.fPaintBits) { - str->append("None"); - } else if (kEntirePaint_Bits == rec->fInfo.fPaintBits) { - str->append("EntirePaint"); - } else { - bool needSeparator = false; - SkAddFlagToString(str, SkToBool(kStyle_Bit & rec->fInfo.fPaintBits), "Style", - &needSeparator); - SkAddFlagToString(str, SkToBool(kTextSkewX_Bit & rec->fInfo.fPaintBits), "TextSkewX", - &needSeparator); - SkAddFlagToString(str, SkToBool(kPathEffect_Bit & rec->fInfo.fPaintBits), "PathEffect", - &needSeparator); - SkAddFlagToString(str, SkToBool(kMaskFilter_Bit & rec->fInfo.fPaintBits), "MaskFilter", - &needSeparator); - SkAddFlagToString(str, SkToBool(kShader_Bit & rec->fInfo.fPaintBits), "Shader", - &needSeparator); - SkAddFlagToString(str, SkToBool(kColorFilter_Bit & rec->fInfo.fPaintBits), "ColorFilter", - &needSeparator); - SkAddFlagToString(str, SkToBool(kXfermode_Bit & rec->fInfo.fPaintBits), "Xfermode", - &needSeparator); - } - str->append(") "); - - static const char* gModeStrings[(int)SkBlendMode::kLastMode+1] = { - "kClear", "kSrc", "kDst", "kSrcOver", "kDstOver", "kSrcIn", "kDstIn", - "kSrcOut", "kDstOut", "kSrcATop", "kDstATop", "kXor", "kPlus", - "kMultiply", "kScreen", "kOverlay", "kDarken", "kLighten", "kColorDodge", - "kColorBurn", "kHardLight", "kSoftLight", "kDifference", "kExclusion" - }; - - str->appendf("mode: %s ", gModeStrings[(int)rec->fInfo.fColorMode]); - - str->append("offset: ("); - str->appendScalar(rec->fInfo.fOffset.fX); - str->append(", "); - str->appendScalar(rec->fInfo.fOffset.fY); - str->append(") "); - - str->append("postTranslate: "); - if (rec->fInfo.fPostTranslate) { - str->append("true "); - } else { - str->append("false "); - } - - rec->fPaint.toString(str); - rec = rec->fNext; - } -} - SkLayerDrawLooper::Builder::Builder() : fRecs(nullptr), fTopRec(nullptr), diff --git a/src/effects/SkLightingImageFilter.cpp b/src/effects/SkLightingImageFilter.cpp index 0a1330583a..c812ccecce 100644 --- a/src/effects/SkLightingImageFilter.cpp +++ b/src/effects/SkLightingImageFilter.cpp @@ -530,7 +530,6 @@ public: sk_sp<SkImageFilter>, const CropRect*); - void toString(SkString* str) const override; SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkDiffuseLightingImageFilter) SkScalar kd() const { return fKD; } @@ -565,7 +564,6 @@ public: SkScalar ks, SkScalar shininess, sk_sp<SkImageFilter>, const CropRect*); - void toString(SkString* str) const override; SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkSpecularLightingImageFilter) SkScalar ks() const { return fKS; } @@ -1371,12 +1369,6 @@ const { return this->refMe(); } -void SkDiffuseLightingImageFilter::toString(SkString* str) const { - str->appendf("SkDiffuseLightingImageFilter: ("); - str->appendf("kD: %f\n", fKD); - str->append(")"); -} - #if SK_SUPPORT_GPU std::unique_ptr<GrFragmentProcessor> SkDiffuseLightingImageFilter::makeFragmentProcessor( sk_sp<GrTextureProxy> proxy, @@ -1526,12 +1518,6 @@ const { return this->refMe(); } -void SkSpecularLightingImageFilter::toString(SkString* str) const { - str->appendf("SkSpecularLightingImageFilter: ("); - str->appendf("kS: %f shininess: %f", fKS, fShininess); - str->append(")"); -} - #if SK_SUPPORT_GPU std::unique_ptr<GrFragmentProcessor> SkSpecularLightingImageFilter::makeFragmentProcessor( sk_sp<GrTextureProxy> proxy, diff --git a/src/effects/SkLumaColorFilter.cpp b/src/effects/SkLumaColorFilter.cpp index 847d5f929f..12d6dd877b 100644 --- a/src/effects/SkLumaColorFilter.cpp +++ b/src/effects/SkLumaColorFilter.cpp @@ -37,10 +37,6 @@ sk_sp<SkFlattenable> SkLumaColorFilter::CreateProc(SkReadBuffer&) { void SkLumaColorFilter::flatten(SkWriteBuffer&) const {} -void SkLumaColorFilter::toString(SkString* str) const { - str->append("SkLumaColorFilter "); -} - #if SK_SUPPORT_GPU std::unique_ptr<GrFragmentProcessor> SkLumaColorFilter::asFragmentProcessor( GrContext*, const GrColorSpaceInfo&) const { diff --git a/src/effects/SkMagnifierImageFilter.cpp b/src/effects/SkMagnifierImageFilter.cpp index 75e9817b8d..e28469e595 100644 --- a/src/effects/SkMagnifierImageFilter.cpp +++ b/src/effects/SkMagnifierImageFilter.cpp @@ -200,11 +200,3 @@ sk_sp<SkImageFilter> SkMagnifierImageFilter::onMakeColorSpace(SkColorSpaceXforme } return this->refMe(); } - -void SkMagnifierImageFilter::toString(SkString* str) const { - str->appendf("SkMagnifierImageFilter: ("); - str->appendf("src: (%f,%f,%f,%f) ", - fSrcRect.fLeft, fSrcRect.fTop, fSrcRect.fRight, fSrcRect.fBottom); - str->appendf("inset: %f", fInset); - str->append(")"); -} diff --git a/src/effects/SkMatrixConvolutionImageFilter.cpp b/src/effects/SkMatrixConvolutionImageFilter.cpp index 848676afaf..7668a02849 100644 --- a/src/effects/SkMatrixConvolutionImageFilter.cpp +++ b/src/effects/SkMatrixConvolutionImageFilter.cpp @@ -479,18 +479,3 @@ bool SkMatrixConvolutionImageFilter::affectsTransparentBlack() const { // pixels it will affect in object-space. return kRepeat_TileMode != fTileMode; } - -void SkMatrixConvolutionImageFilter::toString(SkString* str) const { - str->appendf("SkMatrixConvolutionImageFilter: ("); - str->appendf("size: (%d,%d) kernel: (", fKernelSize.width(), fKernelSize.height()); - for (int y = 0; y < fKernelSize.height(); y++) { - for (int x = 0; x < fKernelSize.width(); x++) { - str->appendf("%f ", fKernel[y * fKernelSize.width() + x]); - } - } - str->appendf(")"); - str->appendf("gain: %f bias: %f ", fGain, fBias); - str->appendf("offset: (%d, %d) ", fKernelOffset.fX, fKernelOffset.fY); - str->appendf("convolveAlpha: %s", fConvolveAlpha ? "true" : "false"); - str->append(")"); -} diff --git a/src/effects/SkMergeImageFilter.cpp b/src/effects/SkMergeImageFilter.cpp index 41d545e187..633ddd4ae1 100644 --- a/src/effects/SkMergeImageFilter.cpp +++ b/src/effects/SkMergeImageFilter.cpp @@ -121,15 +121,3 @@ void SkMergeImageFilter::flatten(SkWriteBuffer& buffer) const { this->INHERITED::flatten(buffer); } -void SkMergeImageFilter::toString(SkString* str) const { - str->appendf("SkMergeImageFilter: ("); - - for (int i = 0; i < this->countInputs(); ++i) { - SkImageFilter* filter = this->getInput(i); - str->appendf("%d: (", i); - filter->toString(str); - str->appendf(")"); - } - - str->append(")"); -} diff --git a/src/effects/SkMorphologyImageFilter.cpp b/src/effects/SkMorphologyImageFilter.cpp index e421fdd28a..d46364aa5d 100644 --- a/src/effects/SkMorphologyImageFilter.cpp +++ b/src/effects/SkMorphologyImageFilter.cpp @@ -113,18 +113,6 @@ sk_sp<SkFlattenable> SkDilateImageFilter::CreateProc(SkReadBuffer& buffer) { return Make(width, height, common.getInput(0), &common.cropRect()); } -void SkErodeImageFilter::toString(SkString* str) const { - str->appendf("SkErodeImageFilter: ("); - str->appendf("radius: (%d,%d)", this->radius().fWidth, this->radius().fHeight); - str->append(")"); -} - -void SkDilateImageFilter::toString(SkString* str) const { - str->appendf("SkDilateImageFilter: ("); - str->appendf("radius: (%d,%d)", this->radius().fWidth, this->radius().fHeight); - str->append(")"); -} - #if SK_SUPPORT_GPU /////////////////////////////////////////////////////////////////////////////// diff --git a/src/effects/SkOffsetImageFilter.cpp b/src/effects/SkOffsetImageFilter.cpp index 5b1533b371..25b7289974 100644 --- a/src/effects/SkOffsetImageFilter.cpp +++ b/src/effects/SkOffsetImageFilter.cpp @@ -124,13 +124,3 @@ SkOffsetImageFilter::SkOffsetImageFilter(SkScalar dx, SkScalar dy, : INHERITED(&input, 1, cropRect) { fOffset.set(dx, dy); } - -void SkOffsetImageFilter::toString(SkString* str) const { - str->appendf("SkOffsetImageFilter: ("); - str->appendf("offset: (%f, %f) ", fOffset.fX, fOffset.fY); - str->append("input: ("); - if (this->getInput(0)) { - this->getInput(0)->toString(str); - } - str->append("))"); -} diff --git a/src/effects/SkOverdrawColorFilter.cpp b/src/effects/SkOverdrawColorFilter.cpp index 01dab6544f..71dbb72011 100644 --- a/src/effects/SkOverdrawColorFilter.cpp +++ b/src/effects/SkOverdrawColorFilter.cpp @@ -36,14 +36,6 @@ void SkOverdrawColorFilter::onAppendStages(SkRasterPipeline* p, p->append(SkRasterPipeline::callback, ctx); } -void SkOverdrawColorFilter::toString(SkString* str) const { - str->append("SkOverdrawColorFilter ("); - for (int i = 0; i < kNumColors; i++) { - str->appendf("%d: %x\n", i, fColors[i]); - } - str->append(")"); -} - void SkOverdrawColorFilter::flatten(SkWriteBuffer& buffer) const { buffer.writeByteArray(fColors, kNumColors * sizeof(SkPMColor)); } diff --git a/src/effects/SkPaintImageFilter.cpp b/src/effects/SkPaintImageFilter.cpp index 235f76f6a1..c0be41fdb9 100644 --- a/src/effects/SkPaintImageFilter.cpp +++ b/src/effects/SkPaintImageFilter.cpp @@ -81,9 +81,3 @@ sk_sp<SkImageFilter> SkPaintImageFilter::onMakeColorSpace(SkColorSpaceXformer* x bool SkPaintImageFilter::affectsTransparentBlack() const { return true; } - -void SkPaintImageFilter::toString(SkString* str) const { - str->appendf("SkPaintImageFilter: ("); - fPaint.toString(str); - str->append(")"); -} diff --git a/src/effects/SkPictureImageFilter.cpp b/src/effects/SkPictureImageFilter.cpp index 93a494d1e7..e6069c3b21 100644 --- a/src/effects/SkPictureImageFilter.cpp +++ b/src/effects/SkPictureImageFilter.cpp @@ -130,15 +130,3 @@ sk_sp<SkImageFilter> SkPictureImageFilter::onMakeColorSpace(SkColorSpaceXformer* return sk_sp<SkImageFilter>(new SkPictureImageFilter(fPicture, fCropRect, std::move(dstCS))); } - -void SkPictureImageFilter::toString(SkString* str) const { - str->appendf("SkPictureImageFilter: ("); - str->appendf("crop: (%f,%f,%f,%f) ", - fCropRect.fLeft, fCropRect.fTop, fCropRect.fRight, fCropRect.fBottom); - if (fPicture) { - str->appendf("picture: (%f,%f,%f,%f)", - fPicture->cullRect().fLeft, fPicture->cullRect().fTop, - fPicture->cullRect().fRight, fPicture->cullRect().fBottom); - } - str->append(")"); -} diff --git a/src/effects/SkShaderMaskFilter.cpp b/src/effects/SkShaderMaskFilter.cpp index cfa15c5bad..f2160a17a3 100644 --- a/src/effects/SkShaderMaskFilter.cpp +++ b/src/effects/SkShaderMaskFilter.cpp @@ -27,7 +27,6 @@ public: bool asABlur(BlurRec*) const override { return false; } - void toString(SkString* str) const override; SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkShaderMF) protected: @@ -47,10 +46,6 @@ private: typedef SkMaskFilter INHERITED; }; -void SkShaderMF::toString(SkString* str) const { - str->set("SkShaderMF:"); -} - sk_sp<SkFlattenable> SkShaderMF::CreateProc(SkReadBuffer& buffer) { return SkShaderMaskFilter::Make(buffer.readShader()); } diff --git a/src/effects/SkTableColorFilter.cpp b/src/effects/SkTableColorFilter.cpp index 47d6ae2d8c..fcf76dcbae 100644 --- a/src/effects/SkTableColorFilter.cpp +++ b/src/effects/SkTableColorFilter.cpp @@ -90,8 +90,6 @@ public: GrContext*, const GrColorSpaceInfo&) const override; #endif - void toString(SkString* str) const override; - SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkTable_ColorFilter) enum { @@ -140,35 +138,6 @@ private: typedef SkColorFilter INHERITED; }; -void SkTable_ColorFilter::toString(SkString* str) const { - const uint8_t* table = fStorage; - const uint8_t* tableA = gIdentityTable; - const uint8_t* tableR = gIdentityTable; - const uint8_t* tableG = gIdentityTable; - const uint8_t* tableB = gIdentityTable; - if (fFlags & kA_Flag) { - tableA = table; table += 256; - } - if (fFlags & kR_Flag) { - tableR = table; table += 256; - } - if (fFlags & kG_Flag) { - tableG = table; table += 256; - } - if (fFlags & kB_Flag) { - tableB = table; - } - - str->append("SkTable_ColorFilter ("); - - for (int i = 0; i < 256; ++i) { - str->appendf("%d: %d,%d,%d,%d\n", - i, tableR[i], tableG[i], tableB[i], tableA[i]); - } - - str->append(")"); -} - static const uint8_t gCountNibBits[] = { 0, 1, 1, 2, 1, 2, 2, 3, diff --git a/src/effects/SkTableMaskFilter.cpp b/src/effects/SkTableMaskFilter.cpp index 2df2fa7f14..8ff58ec89d 100644 --- a/src/effects/SkTableMaskFilter.cpp +++ b/src/effects/SkTableMaskFilter.cpp @@ -18,7 +18,6 @@ public: SkMask::Format getFormat() const override; bool filterMask(SkMask*, const SkMask&, const SkMatrix&, SkIPoint*) const override; - void toString(SkString* str) const override; SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkTableMaskFilterImpl) protected: @@ -167,15 +166,3 @@ void SkTableMaskFilter::MakeClipTable(uint8_t table[256], uint8_t min, SkDebugf("\n\n"); #endif } - -void SkTableMaskFilterImpl::toString(SkString* str) const { - str->append("SkTableMaskFilter: ("); - - str->append("table: "); - for (int i = 0; i < 255; ++i) { - str->appendf("%d, ", fTable[i]); - } - str->appendf("%d", fTable[255]); - - str->append(")"); -} diff --git a/src/effects/SkTileImageFilter.cpp b/src/effects/SkTileImageFilter.cpp index 1aac5814c5..eddad2722f 100644 --- a/src/effects/SkTileImageFilter.cpp +++ b/src/effects/SkTileImageFilter.cpp @@ -157,17 +157,3 @@ void SkTileImageFilter::flatten(SkWriteBuffer& buffer) const { buffer.writeRect(fSrcRect); buffer.writeRect(fDstRect); } - -void SkTileImageFilter::toString(SkString* str) const { - str->appendf("SkTileImageFilter: ("); - str->appendf("src: %.2f %.2f %.2f %.2f", - fSrcRect.fLeft, fSrcRect.fTop, fSrcRect.fRight, fSrcRect.fBottom); - str->appendf(" dst: %.2f %.2f %.2f %.2f", - fDstRect.fLeft, fDstRect.fTop, fDstRect.fRight, fDstRect.fBottom); - if (this->getInput(0)) { - str->appendf("input: ("); - this->getInput(0)->toString(str); - str->appendf(")"); - } - str->append(")"); -} diff --git a/src/effects/SkToSRGBColorFilter.cpp b/src/effects/SkToSRGBColorFilter.cpp index d2020ef338..09acabf94a 100644 --- a/src/effects/SkToSRGBColorFilter.cpp +++ b/src/effects/SkToSRGBColorFilter.cpp @@ -71,11 +71,6 @@ void SkToSRGBColorFilter::flatten(SkWriteBuffer& buffer) const { buffer.writeDataAsByteArray(fSrcColorSpace->serialize().get()); } -void SkToSRGBColorFilter::toString(SkString* str) const { - // TODO - str->append("SkToSRGBColorFilter "); -} - #if SK_SUPPORT_GPU std::unique_ptr<GrFragmentProcessor> SkToSRGBColorFilter::asFragmentProcessor( GrContext*, const GrColorSpaceInfo&) const { diff --git a/src/effects/SkTrimPE.h b/src/effects/SkTrimPE.h index 7a05e72074..f66bccc821 100644 --- a/src/effects/SkTrimPE.h +++ b/src/effects/SkTrimPE.h @@ -18,7 +18,6 @@ public: bool filterPath(SkPath* dst, const SkPath& src, SkStrokeRec*, const SkRect*) const override; - void toString(SkString* str) const override; SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkTrimPE) protected: diff --git a/src/effects/SkTrimPathEffect.cpp b/src/effects/SkTrimPathEffect.cpp index d63393a4a6..8c3f56e2ba 100644 --- a/src/effects/SkTrimPathEffect.cpp +++ b/src/effects/SkTrimPathEffect.cpp @@ -97,10 +97,6 @@ sk_sp<SkFlattenable> SkTrimPE::CreateProc(SkReadBuffer& buffer) { (mode & 1) ? SkTrimPathEffect::Mode::kInverted : SkTrimPathEffect::Mode::kNormal); } -void SkTrimPE::toString(SkString* str) const { - str->appendf("SkTrimPathEffect: (%g %g)", fStartT, fStopT); -} - ////////////////////////////////////////////////////////////////////////////////////////////////// sk_sp<SkPathEffect> SkTrimPathEffect::Make(SkScalar startT, SkScalar stopT, Mode mode) { diff --git a/src/effects/SkXfermodeImageFilter.cpp b/src/effects/SkXfermodeImageFilter.cpp index 9123818c84..ff4a6299ed 100644 --- a/src/effects/SkXfermodeImageFilter.cpp +++ b/src/effects/SkXfermodeImageFilter.cpp @@ -34,7 +34,6 @@ public: SkXfermodeImageFilter_Base(SkBlendMode mode, sk_sp<SkImageFilter> inputs[2], const CropRect* cropRect); - void toString(SkString* str) const override; SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkXfermodeImageFilter_Base) protected: @@ -249,22 +248,6 @@ void SkXfermodeImageFilter_Base::drawForeground(SkCanvas* canvas, SkSpecialImage canvas->drawPaint(paint); } -void SkXfermodeImageFilter_Base::toString(SkString* str) const { - str->appendf("SkXfermodeImageFilter: ("); - str->appendf("blendmode: (%d)", (int)fMode); - if (this->getInput(0)) { - str->appendf("foreground: ("); - this->getInput(0)->toString(str); - str->appendf(")"); - } - if (this->getInput(1)) { - str->appendf("background: ("); - this->getInput(1)->toString(str); - str->appendf(")"); - } - str->append(")"); -} - #if SK_SUPPORT_GPU #include "effects/GrXfermodeFragmentProcessor.h" |