diff options
Diffstat (limited to 'src/effects/SkAlphaThresholdFilter.cpp')
-rw-r--r-- | src/effects/SkAlphaThresholdFilter.cpp | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/effects/SkAlphaThresholdFilter.cpp b/src/effects/SkAlphaThresholdFilter.cpp index 7215aa8372..823c3028c5 100644 --- a/src/effects/SkAlphaThresholdFilter.cpp +++ b/src/effects/SkAlphaThresholdFilter.cpp @@ -229,12 +229,11 @@ bool AlphaThresholdEffect::onIsEqual(const GrProcessor& sBase) const { } void AlphaThresholdEffect::onComputeInvariantOutput(InvariantOutput* inout) const { - if (inout->isOpaque() && GrPixelConfigIsOpaque(this->texture(0)->config())) { - inout->fValidFlags = kA_GrColorComponentFlag; + if (GrPixelConfigIsOpaque(this->texture(0)->config()) && fOuterThreshold >= 1.f) { + inout->mulByUnknownOpaqueColor(); } else { - inout->fValidFlags = 0; + inout->mulByUnknownColor(); } - inout->fIsSingleComponent = false; } #endif |