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

Unified Diff: src/gpu/GrRODrawState.h

Issue 509153002: Initial change to create GeometryProcessor (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: small fixes Created 6 years, 3 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
Index: src/gpu/GrRODrawState.h
diff --git a/src/gpu/GrRODrawState.h b/src/gpu/GrRODrawState.h
index 0abd4a6aa54cce8169f5f9a16c93983a747a74d3..4a3812340f09e87ca5457306f4474f3c2345f8fa 100644
--- a/src/gpu/GrRODrawState.h
+++ b/src/gpu/GrRODrawState.h
@@ -121,8 +121,13 @@ public:
int numColorStages() const { return fColorStages.count(); }
int numCoverageStages() const { return fCoverageStages.count(); }
- int numTotalStages() const { return this->numColorStages() + this->numCoverageStages(); }
+ int numTotalStages() const {
+ return this->numColorStages() + this->numCoverageStages() +
+ (this->hasGeometryProcessor() ? 1 : 0);
+ }
+ bool hasGeometryProcessor() const { return NULL != fGeometryProcessor.get(); }
+ const GrEffectStage* getGeometryProcessor() const { return fGeometryProcessor.get(); }
const GrEffectStage& getColorStage(int stageIdx) const { return fColorStages[stageIdx]; }
const GrEffectStage& getCoverageStage(int stageIdx) const { return fCoverageStages[stageIdx]; }
@@ -359,6 +364,7 @@ protected:
GrBlendCoeff fDstBlend;
typedef SkSTArray<4, GrEffectStage> EffectStageArray;
+ SkAutoTDelete<GrEffectStage> fGeometryProcessor;
EffectStageArray fColorStages;
EffectStageArray fCoverageStages;

Powered by Google App Engine
This is Rietveld 408576698