aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/effects/GrBicubicEffect.cpp
diff options
context:
space:
mode:
authorGravatar Brian Salomon <bsalomon@google.com>2017-07-26 19:07:15 -0400
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2017-07-26 23:31:30 +0000
commit6cd51b51d6603a3100b147c45f38697f2f199fc6 (patch)
tree55d6bebf39125e0cdb0cd30c4fb6f8489428931a /src/gpu/effects/GrBicubicEffect.cpp
parent7f97f49a840c92e26058034c631e8d76a54897bd (diff)
Remove GrSingleTextureEffect
Change-Id: I510cc0657f9433b206dc2ab643fa557667263294 Reviewed-on: https://skia-review.googlesource.com/27180 Commit-Queue: Brian Salomon <bsalomon@google.com> Reviewed-by: Ethan Nicholas <ethannicholas@google.com>
Diffstat (limited to 'src/gpu/effects/GrBicubicEffect.cpp')
-rw-r--r--src/gpu/effects/GrBicubicEffect.cpp29
1 files changed, 17 insertions, 12 deletions
diff --git a/src/gpu/effects/GrBicubicEffect.cpp b/src/gpu/effects/GrBicubicEffect.cpp
index f7441bc043..9472f5192e 100644
--- a/src/gpu/effects/GrBicubicEffect.cpp
+++ b/src/gpu/effects/GrBicubicEffect.cpp
@@ -135,26 +135,31 @@ void GrGLBicubicEffect::onSetData(const GrGLSLProgramDataManager& pdman,
GrBicubicEffect::GrBicubicEffect(sk_sp<GrTextureProxy> proxy,
sk_sp<GrColorSpaceXform> colorSpaceXform,
- const SkMatrix &matrix,
+ const SkMatrix& matrix,
const SkShader::TileMode tileModes[2])
- : INHERITED{ModulationFlags(proxy->config()),
- GR_PROXY_MOVE(proxy),
- std::move(colorSpaceXform),
- matrix,
- GrSamplerParams(tileModes, GrSamplerParams::kNone_FilterMode)}
- , fDomain(GrTextureDomain::IgnoredDomain()) {
+ : INHERITED{ModulateByConfigOptimizationFlags(proxy->config())}
+ , fCoordTransform(matrix, proxy.get())
+ , fDomain(GrTextureDomain::IgnoredDomain())
+ , fTextureSampler(std::move(proxy),
+ GrSamplerParams(tileModes, GrSamplerParams::kNone_FilterMode))
+ , fColorSpaceXform(std::move(colorSpaceXform)) {
this->initClassID<GrBicubicEffect>();
+ this->addCoordTransform(&fCoordTransform);
+ this->addTextureSampler(&fTextureSampler);
}
GrBicubicEffect::GrBicubicEffect(sk_sp<GrTextureProxy> proxy,
sk_sp<GrColorSpaceXform> colorSpaceXform,
- const SkMatrix &matrix,
+ const SkMatrix& matrix,
const SkRect& domain)
- : INHERITED(ModulationFlags(proxy->config()), proxy,
- std::move(colorSpaceXform), matrix,
- GrSamplerParams(SkShader::kClamp_TileMode, GrSamplerParams::kNone_FilterMode))
- , fDomain(proxy.get(), domain, GrTextureDomain::kClamp_Mode) {
+ : INHERITED(ModulateByConfigOptimizationFlags(proxy->config()))
+ , fCoordTransform(matrix, proxy.get())
+ , fDomain(proxy.get(), domain, GrTextureDomain::kClamp_Mode)
+ , fTextureSampler(std::move(proxy))
+ , fColorSpaceXform(std::move(colorSpaceXform)) {
this->initClassID<GrBicubicEffect>();
+ this->addCoordTransform(&fCoordTransform);
+ this->addTextureSampler(&fTextureSampler);
}
GrBicubicEffect::~GrBicubicEffect() {