diff options
author | Brian Osman <brianosman@google.com> | 2017-04-03 16:36:58 -0400 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2017-04-04 13:19:18 +0000 |
commit | 5869ea99e437aec35d28a153079c37fd2b6def44 (patch) | |
tree | bb13198ce47b72de67032cefaf9c25cb84987857 /src/effects | |
parent | 8540acc197f982860d1c35c61df27e7ac412b45c (diff) |
Fully remove coord transform precision code
Coord transforms are always computed and interpolated at high precision.
Bug: skia:
Change-Id: I5f7eadc2080df8ad5cbb080835c0dba09c59e63e
Reviewed-on: https://skia-review.googlesource.com/11180
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Diffstat (limited to 'src/effects')
-rw-r--r-- | src/effects/GrAlphaThresholdFragmentProcessor.cpp | 6 | ||||
-rw-r--r-- | src/effects/SkDisplacementMapEffect.cpp | 5 | ||||
-rw-r--r-- | src/effects/gradients/SkGradientShader.cpp | 5 |
3 files changed, 6 insertions, 10 deletions
diff --git a/src/effects/GrAlphaThresholdFragmentProcessor.cpp b/src/effects/GrAlphaThresholdFragmentProcessor.cpp index b4ad0ccd2f..be890c48db 100644 --- a/src/effects/GrAlphaThresholdFragmentProcessor.cpp +++ b/src/effects/GrAlphaThresholdFragmentProcessor.cpp @@ -37,15 +37,13 @@ GrAlphaThresholdFragmentProcessor::GrAlphaThresholdFragmentProcessor( : INHERITED(OptFlags(outerThreshold)) , fInnerThreshold(innerThreshold) , fOuterThreshold(outerThreshold) - , fImageCoordTransform(resourceProvider, SkMatrix::I(), proxy.get(), - GrSamplerParams::kNone_FilterMode) + , fImageCoordTransform(resourceProvider, SkMatrix::I(), proxy.get()) , fImageTextureSampler(resourceProvider, std::move(proxy)) , fColorSpaceXform(std::move(colorSpaceXform)) , fMaskCoordTransform( resourceProvider, SkMatrix::MakeTrans(SkIntToScalar(-bounds.x()), SkIntToScalar(-bounds.y())), - maskProxy.get(), - GrSamplerParams::kNone_FilterMode) + maskProxy.get()) , fMaskTextureSampler(resourceProvider, maskProxy) { this->initClassID<GrAlphaThresholdFragmentProcessor>(); this->addCoordTransform(&fImageCoordTransform); diff --git a/src/effects/SkDisplacementMapEffect.cpp b/src/effects/SkDisplacementMapEffect.cpp index 9bd159d40b..bdf9cd5160 100644 --- a/src/effects/SkDisplacementMapEffect.cpp +++ b/src/effects/SkDisplacementMapEffect.cpp @@ -496,10 +496,9 @@ GrDisplacementMapEffect::GrDisplacementMapEffect( const SkISize& colorDimensions) : INHERITED(GrPixelConfigIsOpaque(color->config()) ? kPreservesOpaqueInput_OptimizationFlag : kNone_OptimizationFlags) - , fDisplacementTransform(resourceProvider, offsetMatrix, displacement.get(), - GrSamplerParams::kNone_FilterMode) + , fDisplacementTransform(resourceProvider, offsetMatrix, displacement.get()) , fDisplacementSampler(resourceProvider, displacement) - , fColorTransform(resourceProvider, color.get(), GrSamplerParams::kNone_FilterMode) + , fColorTransform(resourceProvider, color.get()) , fDomain(color.get(), GrTextureDomain::MakeTexelDomain(SkIRect::MakeSize(colorDimensions)), GrTextureDomain::kDecal_Mode) , fColorSampler(resourceProvider, color) diff --git a/src/effects/gradients/SkGradientShader.cpp b/src/effects/gradients/SkGradientShader.cpp index be60dee15e..b178467f9c 100644 --- a/src/effects/gradients/SkGradientShader.cpp +++ b/src/effects/gradients/SkGradientShader.cpp @@ -1696,8 +1696,7 @@ GrGradientEffect::GrGradientEffect(const CreateArgs& args, bool isOpaque) fYCoord = fAtlas->getYOffset(fRow)+SK_ScalarHalf*fAtlas->getNormalizedTexelHeight(); // This is 1/2 places where auto-normalization is disabled fCoordTransform.reset(args.fContext->resourceProvider(), *args.fMatrix, - fAtlas->asTextureProxyRef().get(), - params.filterMode(), false); + fAtlas->asTextureProxyRef().get(), false); fTextureSampler.reset(args.fContext->resourceProvider(), fAtlas->asTextureProxyRef(), params); } else { @@ -1716,7 +1715,7 @@ GrGradientEffect::GrGradientEffect(const CreateArgs& args, bool isOpaque) } // This is 2/2 places where auto-normalization is disabled fCoordTransform.reset(args.fContext->resourceProvider(), *args.fMatrix, - proxy.get(), params.filterMode(), false); + proxy.get(), false); fTextureSampler.reset(args.fContext->resourceProvider(), std::move(proxy), params); fYCoord = SK_ScalarHalf; |