Index: src/gpu/GrOptDrawState.h |
diff --git a/src/gpu/GrOptDrawState.h b/src/gpu/GrOptDrawState.h |
index 544f1f53ba2dcd969cb2bc1b3550f0672b382cb5..5c6b6036f06c998dbe778c4ed08f89bb51b7cb66 100644 |
--- a/src/gpu/GrOptDrawState.h |
+++ b/src/gpu/GrOptDrawState.h |
@@ -23,6 +23,10 @@ public: |
bool inputColorIsUsed() const { return fInputColorIsUsed; } |
bool inputCoverageIsUsed() const { return fInputCoverageIsUsed; } |
+ bool readsDst() const { return fReadsDst; } |
+ bool readsFragPosition() const { return fReadsFragPosition; } |
+ bool requiresVertexShader() const { return fRequiresVertexShader; } |
+ |
private: |
/** |
* Constructs and optimized drawState out of a GrRODrawState. |
@@ -73,11 +77,22 @@ private: |
*/ |
void remapEffectStagesVAIndices(); |
+ /** |
+ * Loop over the effect stages to determine various info like what data they will read and what |
+ * shaders they require. |
+ */ |
+ void getStageStats(); |
+ |
// These flags are needed to protect the code from creating an unused uniform color/coverage |
// which will cause shader compiler errors. |
bool fInputColorIsUsed; |
bool fInputCoverageIsUsed; |
+ // These flags give general info on the effect stages that are used when building the programs |
bsalomon
2014/09/05 15:27:55
general info -> aggregated info?
egdaniel
2014/09/08 19:19:49
Done.
|
+ bool fReadsDst; |
+ bool fReadsFragPosition; |
+ bool fRequiresVertexShader; |
+ |
SkAutoSTArray<4, GrVertexAttrib> fOptVA; |
SkAutoSTArray<4, int> fVAIndexMap; |