aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/effects
diff options
context:
space:
mode:
authorGravatar fmalita <fmalita@chromium.org>2015-12-03 09:15:25 -0800
committerGravatar Commit bot <commit-bot@chromium.org>2015-12-03 09:15:26 -0800
commitc2e0ac4fce5bfe5bac9f2cb1ebd3aea3a8900fb1 (patch)
tree8c1a1fbd880aaa1fd31ae198b9dd45b1034210d9 /src/effects
parent53c5d5fb795fe04bec050c0583223027c25b839b (diff)
Don't use the Sk4f gradient impl without SIMD
Also remove the SK_SUPPORT_LEGACY_LINEAR_GRADIENT_TABLE guard since it is no longer used in Chromium. BUG=chromium:563492 R=reed@google.com,mtklein@google.com CQ_EXTRA_TRYBOTS=client.skia:Test-Ubuntu-GCC-GCE-CPU-AVX2-x86_64-Release-SKNX_NO_SIMD-Trybot Review URL: https://codereview.chromium.org/1489233005
Diffstat (limited to 'src/effects')
-rw-r--r--src/effects/gradients/SkLinearGradient.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/effects/gradients/SkLinearGradient.cpp b/src/effects/gradients/SkLinearGradient.cpp
index b224474536..c7d52fb0d9 100644
--- a/src/effects/gradients/SkLinearGradient.cpp
+++ b/src/effects/gradients/SkLinearGradient.cpp
@@ -282,7 +282,8 @@ void SkLinearGradient::LinearGradientContext::shadeSpan(int x, int y, SkPMColor*
SkASSERT(count > 0);
const SkLinearGradient& linearGradient = static_cast<const SkLinearGradient&>(fShader);
-#ifndef SK_SUPPORT_LEGACY_LINEAR_GRADIENT_TABLE
+// Only use the Sk4f impl when known to be fast.
+#if defined(SKNX_IS_FAST)
if (SkShader::kClamp_TileMode == linearGradient.fTileMode &&
kLinear_MatrixClass == fDstToIndexClass)
{