aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/effects/SkBlendImageFilter.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/effects/SkBlendImageFilter.cpp')
-rw-r--r--src/effects/SkBlendImageFilter.cpp12
1 files changed, 3 insertions, 9 deletions
diff --git a/src/effects/SkBlendImageFilter.cpp b/src/effects/SkBlendImageFilter.cpp
index 4e5e018d0f..6dd5eab4c5 100644
--- a/src/effects/SkBlendImageFilter.cpp
+++ b/src/effects/SkBlendImageFilter.cpp
@@ -153,8 +153,6 @@ public:
typedef GrGLBlendEffect GLEffect;
static const char* Name() { return "Blend"; }
- virtual const GrTextureAccess& textureAccess(int index) const SK_OVERRIDE;
-
private:
GrTextureAccess fForegroundAccess;
GrTextureAccess fBackgroundAccess;
@@ -228,10 +226,11 @@ GrTexture* SkBlendImageFilter::filterImageGPU(Proxy* proxy, GrTexture* src, cons
GrBlendEffect::GrBlendEffect(SkBlendImageFilter::Mode mode,
GrTexture* foreground,
GrTexture* background)
- : INHERITED(2)
- , fForegroundAccess(foreground)
+ : fForegroundAccess(foreground)
, fBackgroundAccess(background)
, fMode(mode) {
+ this->addTextureAccess(&fForegroundAccess);
+ this->addTextureAccess(&fBackgroundAccess);
}
GrBlendEffect::~GrBlendEffect() {
@@ -246,11 +245,6 @@ const GrBackendEffectFactory& GrBlendEffect::getFactory() const {
return GrTBackendEffectFactory<GrBlendEffect>::getInstance();
}
-const GrTextureAccess& GrBlendEffect::textureAccess(int index) const {
- SkASSERT(index >= 0 && index < 2);
- return (0 == index) ? fForegroundAccess : fBackgroundAccess;
-}
-
///////////////////////////////////////////////////////////////////////////////
GrGLBlendEffect::GrGLBlendEffect(const GrBackendEffectFactory& factory, const GrEffect& effect)