Index: src/gpu/effects/GrConfigConversionEffect.cpp |
diff --git a/src/gpu/effects/GrConfigConversionEffect.cpp b/src/gpu/effects/GrConfigConversionEffect.cpp |
index e00ad53e5729b49339ea33c2855ad3ca02a1932b..84e60cd76cfdfc771686e2e9ee5ab22ff4286bf8 100644 |
--- a/src/gpu/effects/GrConfigConversionEffect.cpp |
+++ b/src/gpu/effects/GrConfigConversionEffect.cpp |
@@ -16,15 +16,15 @@ |
class GrGLConfigConversionEffect : public GrGLEffect { |
public: |
GrGLConfigConversionEffect(const GrBackendEffectFactory& factory, |
- const GrEffect& effect) |
+ const GrDrawEffect& drawEffect) |
: INHERITED (factory) { |
- const GrConfigConversionEffect& configConversionEffect = effect.cast<GrConfigConversionEffect>(); |
- fSwapRedAndBlue = configConversionEffect.swapsRedAndBlue(); |
- fPMConversion = configConversionEffect.pmConversion(); |
+ const GrConfigConversionEffect& effect = drawEffect.castEffect<GrConfigConversionEffect>(); |
+ fSwapRedAndBlue = effect.swapsRedAndBlue(); |
+ fPMConversion = effect.pmConversion(); |
} |
virtual void emitCode(GrGLProgramBuilder* builder, |
- const GrEffect&, |
+ const GrDrawEffect&, |
const GrEffectKey& key, |
const char* outputColor, |
const char* inputColor, |
@@ -84,9 +84,9 @@ |
fsBuilder->codeAppend(modulate.c_str()); |
} |
- static inline void GenKey(const GrEffect& effect, const GrGLCaps&, |
+ static inline void GenKey(const GrDrawEffect& drawEffect, const GrGLCaps&, |
GrEffectKeyBuilder* b) { |
- const GrConfigConversionEffect& conv = effect.cast<GrConfigConversionEffect>(); |
+ const GrConfigConversionEffect& conv = drawEffect.castEffect<GrConfigConversionEffect>(); |
uint32_t key = (conv.swapsRedAndBlue() ? 0 : 1) | (conv.pmConversion() << 1); |
b->add32(key); |
} |
@@ -119,7 +119,7 @@ |
} |
bool GrConfigConversionEffect::onIsEqual(const GrEffect& s) const { |
- const GrConfigConversionEffect& other = s.cast<GrConfigConversionEffect>(); |
+ const GrConfigConversionEffect& other = CastEffect<GrConfigConversionEffect>(s); |
return this->texture(0) == s.texture(0) && |
other.fSwapRedAndBlue == fSwapRedAndBlue && |
other.fPMConversion == fPMConversion; |