aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/effects
diff options
context:
space:
mode:
authorGravatar Robert Phillips <robertphillips@google.com>2018-03-22 15:16:30 -0400
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2018-03-22 19:55:05 +0000
commit0a4b13cdea208946a59c612e0743f28533124166 (patch)
treebe5b089cb61c3cf2478689a2308501edb2878d7b /src/gpu/effects
parentf7d3f6170fc8efb16a98cf8c52a32060c5c21631 (diff)
Remove std::move from GrSimpleTextureEffect
Bug:822680 Change-Id: I4780ce12a6ce244a2165bfb7b293adb06ae577c5 Reviewed-on: https://skia-review.googlesource.com/115900 Reviewed-by: Ethan Nicholas <ethannicholas@google.com> Reviewed-by: Brian Salomon <bsalomon@google.com> Commit-Queue: Robert Phillips <robertphillips@google.com>
Diffstat (limited to 'src/gpu/effects')
-rw-r--r--src/gpu/effects/GrSimpleTextureEffect.fp22
-rw-r--r--src/gpu/effects/GrSimpleTextureEffect.h2
2 files changed, 15 insertions, 9 deletions
diff --git a/src/gpu/effects/GrSimpleTextureEffect.fp b/src/gpu/effects/GrSimpleTextureEffect.fp
index 18ce3a9387..9312ddf048 100644
--- a/src/gpu/effects/GrSimpleTextureEffect.fp
+++ b/src/gpu/effects/GrSimpleTextureEffect.fp
@@ -8,10 +8,6 @@
in uniform sampler2D image;
in half4x4 matrix;
-@constructorParams {
- GrSamplerState samplerParams
-}
-
@coordTransform(image) {
matrix
}
@@ -45,10 +41,20 @@ in half4x4 matrix;
}
}
-@optimizationFlags {
- kCompatibleWithCoverageAsAlpha_OptimizationFlag |
- (GrPixelConfigIsOpaque(image->config()) ? kPreservesOpaqueInput_OptimizationFlag :
- kNone_OptimizationFlags)
+@constructor {
+ GrSimpleTextureEffect(sk_sp<GrTextureProxy> image, SkMatrix44 matrix,
+ GrSamplerState samplerParams)
+ : INHERITED(kGrSimpleTextureEffect_ClassID,
+ (OptimizationFlags)kCompatibleWithCoverageAsAlpha_OptimizationFlag |
+ (GrPixelConfigIsOpaque(image->config())
+ ? kPreservesOpaqueInput_OptimizationFlag
+ : kNone_OptimizationFlags))
+ , fImage(image, samplerParams) // std::move(image) removed for crbug.com/822680
+ , fMatrix(matrix)
+ , fImageCoordTransform(matrix, fImage.proxy()) {
+ this->addTextureSampler(&fImage);
+ this->addCoordTransform(&fImageCoordTransform);
+ }
}
void main() {
diff --git a/src/gpu/effects/GrSimpleTextureEffect.h b/src/gpu/effects/GrSimpleTextureEffect.h
index 119f11e305..b19ea57a20 100644
--- a/src/gpu/effects/GrSimpleTextureEffect.h
+++ b/src/gpu/effects/GrSimpleTextureEffect.h
@@ -53,7 +53,7 @@ private:
(GrPixelConfigIsOpaque(image->config())
? kPreservesOpaqueInput_OptimizationFlag
: kNone_OptimizationFlags))
- , fImage(std::move(image), samplerParams)
+ , fImage(image, samplerParams) // std::move(image) removed for crbug.com/822680
, fMatrix(matrix)
, fImageCoordTransform(matrix, fImage.proxy()) {
this->addTextureSampler(&fImage);