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

Unified Diff: src/gpu/GrDrawTarget.h

Issue 1414903002: Dependencies are now added between the drawTargets in GrPipeline (Closed) Base URL: https://skia.googlesource.com/skia.git@mdb-adddeps
Patch Set: Fix leak on abandon issue Created 5 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 | « include/gpu/GrRenderTarget.h ('k') | src/gpu/GrDrawTarget.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrDrawTarget.h
diff --git a/src/gpu/GrDrawTarget.h b/src/gpu/GrDrawTarget.h
index a487785a8b0c9650dd63eadd2e76d25b80ef98bb..d77615e6555faedcf6769b187cafa92f7da3cefa 100644
--- a/src/gpu/GrDrawTarget.h
+++ b/src/gpu/GrDrawTarget.h
@@ -33,6 +33,8 @@
#include "SkTypes.h"
#include "SkXfermode.h"
+//#define ENABLE_MDB 1
+
class GrBatch;
class GrBatchFlushState;
class GrClip;
@@ -49,7 +51,7 @@ public:
// The context may not be fully constructed and should not be used during GrDrawTarget
// construction.
- GrDrawTarget(GrGpu* gpu, GrResourceProvider*, const Options& options);
+ GrDrawTarget(GrRenderTarget* rt, GrGpu* gpu, GrResourceProvider*, const Options& options);
~GrDrawTarget() override;
@@ -62,6 +64,10 @@ public:
}
bool isClosed() const { return this->isSetFlag(kClosed_Flag); }
+ // TODO: this entry point is only needed in the non-MDB world. Remove when
+ // we make the switch to MDB
+ void clearRT() { fRenderTarget = nullptr; }
+
/*
* Notify this drawTarget that it relies on the contents of 'dependedOn'
*/
@@ -318,6 +324,7 @@ private:
// 'this' drawTarget relies on the output of the drawTargets in 'fDependencies'
SkTDArray<GrDrawTarget*> fDependencies;
+ GrRenderTarget* fRenderTarget;
typedef SkRefCnt INHERITED;
};
« no previous file with comments | « include/gpu/GrRenderTarget.h ('k') | src/gpu/GrDrawTarget.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698