diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/private/GrOpList.h | 21 |
1 files changed, 10 insertions, 11 deletions
diff --git a/include/private/GrOpList.h b/include/private/GrOpList.h index 0d5a1a245a..a4e541c81d 100644 --- a/include/private/GrOpList.h +++ b/include/private/GrOpList.h @@ -67,15 +67,7 @@ public: /* * Does this opList depend on 'dependedOn'? */ - bool dependsOn(GrOpList* dependedOn) const { - for (int i = 0; i < fDependencies.count(); ++i) { - if (fDependencies[i] == dependedOn) { - return true; - } - } - - return false; - } + bool dependsOn(const GrOpList* dependedOn) const; /* * Safely cast this GrOpList to a GrTextureOpList (if possible). @@ -120,6 +112,13 @@ protected: private: friend class GrDrawingManager; // for resetFlag, TopoSortTraits & gatherProxyIntervals + void addDependency(GrOpList* dependedOn); + void addDependent(GrOpList* dependent); + SkDEBUGCODE(bool isDependedent(const GrOpList* dependent) const); + SkDEBUGCODE(void validate() const); + + void closeThoseWhoDependOnMe(const GrCaps&); + // Remove all Ops which reference proxies that have not been instantiated. virtual void purgeOpsWithUninstantiatedProxies() = 0; @@ -174,13 +173,13 @@ private: virtual void onPrepare(GrOpFlushState* flushState) = 0; virtual bool onExecute(GrOpFlushState* flushState) = 0; - void addDependency(GrOpList* dependedOn); - uint32_t fUniqueID; uint32_t fFlags; // 'this' GrOpList relies on the output of the GrOpLists in 'fDependencies' SkSTArray<1, GrOpList*, true> fDependencies; + // 'this' GrOpList's output is relied on by the GrOpLists in 'fDependents' + SkSTArray<1, GrOpList*, true> fDependents; typedef SkRefCnt INHERITED; }; |