Index: src/gpu/effects/GrTextureDomain.h |
diff --git a/src/gpu/effects/GrTextureDomain.h b/src/gpu/effects/GrTextureDomain.h |
index 82ff73c066207f7d84bc97ef788334c5188bea57..c15c7028b7ab4ce6507d0d4e8c6034aea14bae53 100644 |
--- a/src/gpu/effects/GrTextureDomain.h |
+++ b/src/gpu/effects/GrTextureDomain.h |
@@ -60,9 +60,9 @@ public: |
/* Computes a domain that bounds all the texels in texelRect. Note that with bilerp enabled |
texels neighboring the domain may be read. */ |
- static const SkRect MakeTexelDomain(const GrTexture* texture, const SkIRect& texelRect) { |
- SkScalar wInv = SK_Scalar1 / texture->width(); |
- SkScalar hInv = SK_Scalar1 / texture->height(); |
+ static const SkRect MakeTexelDomain(int width, int height, const SkIRect& texelRect) { |
+ SkScalar wInv = SK_Scalar1 / width; |
+ SkScalar hInv = SK_Scalar1 / height; |
SkRect result = { |
texelRect.fLeft * wInv, |
texelRect.fTop * hInv, |
@@ -173,6 +173,13 @@ public: |
GrTextureDomain::Mode, |
GrTextureParams::FilterMode filterMode); |
+ static sk_sp<GrFragmentProcessor> Make(GrTextureProxy*, |
+ sk_sp<GrColorSpaceXform>, |
+ const SkMatrix&, |
+ const SkRect& domain, |
+ GrTextureDomain::Mode, |
+ GrTextureParams::FilterMode filterMode); |
+ |
const char* name() const override { return "TextureDomain"; } |
SkString dumpInfo() const override { |
@@ -212,6 +219,9 @@ public: |
static sk_sp<GrFragmentProcessor> Make(GrTexture*, const SkIRect& subset, |
const SkIPoint& deviceSpaceOffset); |
+ static sk_sp<GrFragmentProcessor> Make(GrTextureProxy*, const SkIRect& subset, |
+ const SkIPoint& deviceSpaceOffset); |
+ |
const char* name() const override { return "GrDeviceSpaceTextureDecalFragmentProcessor"; } |
SkString dumpInfo() const override { |