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

Unified Diff: src/gpu/effects/GrDashingEffect.cpp

Issue 608253002: Add isSingleComponent bool to getConstantColorComponent (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Fix isSolidWhite 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/gpu/effects/GrCustomCoordsTextureEffect.cpp ('k') | src/gpu/effects/GrDistanceFieldTextureEffect.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/effects/GrDashingEffect.cpp
diff --git a/src/gpu/effects/GrDashingEffect.cpp b/src/gpu/effects/GrDashingEffect.cpp
index 704a6ac3e67b39d0cc4644fa54a7d46cd86b3b6a..4df1f02558e9a1d5ea1cc629c09b87f66fb388a6 100644
--- a/src/gpu/effects/GrDashingEffect.cpp
+++ b/src/gpu/effects/GrDashingEffect.cpp
@@ -456,8 +456,6 @@ public:
typedef GLDashingCircleEffect GLProcessor;
- virtual void getConstantColorComponents(GrColor* color, uint32_t* validFlags) const SK_OVERRIDE;
-
virtual const GrBackendGeometryProcessorFactory& getFactory() const SK_OVERRIDE;
private:
@@ -465,6 +463,8 @@ private:
virtual bool onIsEqual(const GrProcessor& other) const SK_OVERRIDE;
+ virtual void onComputeInvariantOutput(InvariantOutput* inout) const SK_OVERRIDE;
+
GrPrimitiveEdgeType fEdgeType;
const GrShaderVar& fInCoord;
SkScalar fIntervalLength;
@@ -584,8 +584,9 @@ GrGeometryProcessor* DashingCircleEffect::Create(GrPrimitiveEdgeType edgeType, c
DashingCircleEffect::~DashingCircleEffect() {}
-void DashingCircleEffect::getConstantColorComponents(GrColor* color, uint32_t* validFlags) const {
- *validFlags = 0;
+void DashingCircleEffect::onComputeInvariantOutput(InvariantOutput* inout) const {
+ inout->fValidFlags = 0;
+ inout->fIsSingleComponent = false;
}
const GrBackendGeometryProcessorFactory& DashingCircleEffect::getFactory() const {
@@ -668,8 +669,6 @@ public:
typedef GLDashingLineEffect GLProcessor;
- virtual void getConstantColorComponents(GrColor* color, uint32_t* validFlags) const SK_OVERRIDE;
-
virtual const GrBackendGeometryProcessorFactory& getFactory() const SK_OVERRIDE;
private:
@@ -677,6 +676,8 @@ private:
virtual bool onIsEqual(const GrProcessor& other) const SK_OVERRIDE;
+ virtual void onComputeInvariantOutput(InvariantOutput* inout) const SK_OVERRIDE;
+
GrPrimitiveEdgeType fEdgeType;
const GrShaderVar& fInCoord;
SkRect fRect;
@@ -807,8 +808,9 @@ GrGeometryProcessor* DashingLineEffect::Create(GrPrimitiveEdgeType edgeType,
DashingLineEffect::~DashingLineEffect() {}
-void DashingLineEffect::getConstantColorComponents(GrColor* color, uint32_t* validFlags) const {
- *validFlags = 0;
+void DashingLineEffect::onComputeInvariantOutput(InvariantOutput* inout) const {
+ inout->fValidFlags = 0;
+ inout->fIsSingleComponent = false;
}
const GrBackendGeometryProcessorFactory& DashingLineEffect::getFactory() const {
« no previous file with comments | « src/gpu/effects/GrCustomCoordsTextureEffect.cpp ('k') | src/gpu/effects/GrDistanceFieldTextureEffect.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698