diff options
author | Brian Salomon <bsalomon@google.com> | 2017-07-28 07:34:05 -0400 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2017-07-28 11:54:47 +0000 |
commit | 3f6f965a5a65415c65fe9e64eb41896c66da771d (patch) | |
tree | 1de139167492fd077527517356bbf1f3298a9800 /src/gpu/effects/GrBicubicEffect.h | |
parent | 71603cca8ec779bb3ad5ad18a3dc69e97910fb7c (diff) |
Implement clone for 6 additional GrFragmentProcessor subclasses.
GrMagnifierEffect
GrMorphologyEffect
GrBicubicEffect
GrGaussianConvolutionFragmentProcessor
GrMatrixConvolutionEffect
GrTextureDomainEffect
Bug: skia:
Change-Id: I69721b9b95346b365723e5ee21dff2dee8884466
Reviewed-on: https://skia-review.googlesource.com/27900
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
Diffstat (limited to 'src/gpu/effects/GrBicubicEffect.h')
-rw-r--r-- | src/gpu/effects/GrBicubicEffect.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/gpu/effects/GrBicubicEffect.h b/src/gpu/effects/GrBicubicEffect.h index 0d4c7c5dd9..65e2c3dbba 100644 --- a/src/gpu/effects/GrBicubicEffect.h +++ b/src/gpu/effects/GrBicubicEffect.h @@ -19,10 +19,13 @@ public: kFilterTexelPad = 2, // Given a src rect in texels to be filtered, this number of // surrounding texels are needed by the kernel in x and y. }; - ~GrBicubicEffect() override; const char* name() const override { return "Bicubic"; } + sk_sp<GrFragmentProcessor> clone() const override { + return sk_sp<GrFragmentProcessor>(new GrBicubicEffect(*this)); + } + const GrTextureDomain& domain() const { return fDomain; } const GrColorSpaceXform* colorSpaceXform() const { return fColorSpaceXform.get(); } @@ -66,6 +69,7 @@ private: const SkMatrix &matrix, const SkShader::TileMode tileModes[2]); GrBicubicEffect(sk_sp<GrTextureProxy>, sk_sp<GrColorSpaceXform>, const SkMatrix &matrix, const SkRect& domain); + explicit GrBicubicEffect(const GrBicubicEffect&); GrGLSLFragmentProcessor* onCreateGLSLInstance() const override; |