| Index: src/gpu/effects/GrSingleTextureEffect.h
|
| diff --git a/src/gpu/effects/GrSingleTextureEffect.h b/src/gpu/effects/GrSingleTextureEffect.h
|
| index 6349ee7896af677ba06dcc679445719b7e42a805..caf04771c5eb29d73d322a7da76159c41df3c575 100644
|
| --- a/src/gpu/effects/GrSingleTextureEffect.h
|
| +++ b/src/gpu/effects/GrSingleTextureEffect.h
|
| @@ -44,16 +44,16 @@ protected:
|
| }
|
|
|
| /**
|
| - * Can be used as a helper to implement subclass getConstantColorComponents(). It assumes that
|
| + * Can be used as a helper to implement subclass onComputeInvarientOutput(). It assumes that
|
| * the subclass output color will be a modulation of the input color with a value read from the
|
| * texture.
|
| */
|
| - void updateConstantColorComponentsForModulation(GrColor* color, uint32_t* validFlags) const {
|
| - if ((*validFlags & kA_GrColorComponentFlag) && 0xFF == GrColorUnpackA(*color) &&
|
| - GrPixelConfigIsOpaque(this->texture(0)->config())) {
|
| - *validFlags = kA_GrColorComponentFlag;
|
| + void updateInvarientOutputForModulation(InvarientOutput* invarientOutput) const {
|
| + if (invarientOutput->hasOpaqueAlpha()
|
| + && GrPixelConfigIsOpaque(this->texture(0)->config())) {
|
| + invarientOutput->validFlags = kA_GrColorComponentFlag;
|
| } else {
|
| - *validFlags = 0;
|
| + invarientOutput->validFlags = 0;
|
| }
|
| }
|
|
|
|
|