Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(161)

Unified Diff: src/effects/SkArithmeticMode.cpp

Issue 617853003: Revert of Add isSingleComponent bool to getConstantColorComponent (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/effects/SkAlphaThresholdFilter.cpp ('k') | src/effects/SkBlurMaskFilter.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/effects/SkArithmeticMode.cpp
diff --git a/src/effects/SkArithmeticMode.cpp b/src/effects/SkArithmeticMode.cpp
index b62b33db9a4ebcf30881104f877ccc001b71ae5f..85af19cf551fd636f31c13d01ce680e8b3394b00 100644
--- a/src/effects/SkArithmeticMode.cpp
+++ b/src/effects/SkArithmeticMode.cpp
@@ -289,6 +289,8 @@
static const char* Name() { return "Arithmetic"; }
GrTexture* backgroundTexture() const { return fBackgroundAccess.getTexture(); }
+ virtual void getConstantColorComponents(GrColor* color, uint32_t* validFlags) const SK_OVERRIDE;
+
float k1() const { return fK1; }
float k2() const { return fK2; }
float k3() const { return fK3; }
@@ -297,8 +299,6 @@
private:
virtual bool onIsEqual(const GrProcessor&) const SK_OVERRIDE;
-
- virtual void onComputeInvariantOutput(InvariantOutput* inout) const SK_OVERRIDE;
GrArithmeticEffect(float k1, float k2, float k3, float k4, bool enforcePMColor,
GrTexture* background);
@@ -344,10 +344,9 @@
return GrTBackendFragmentProcessorFactory<GrArithmeticEffect>::getInstance();
}
-void GrArithmeticEffect::onComputeInvariantOutput(InvariantOutput* inout) const {
+void GrArithmeticEffect::getConstantColorComponents(GrColor* color, uint32_t* validFlags) const {
// TODO: optimize this
- inout->fValidFlags = 0;
- inout->fIsSingleComponent = false;
+ *validFlags = 0;
}
///////////////////////////////////////////////////////////////////////////////
« no previous file with comments | « src/effects/SkAlphaThresholdFilter.cpp ('k') | src/effects/SkBlurMaskFilter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698