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

Unified Diff: src/gpu/GrDrawingManager.h

Issue 1572653002: Reland of Make a single GrSingleOwner in GrContext (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 11 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/GrDrawContext.cpp ('k') | src/gpu/GrDrawingManager.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrDrawingManager.h
diff --git a/src/gpu/GrDrawingManager.h b/src/gpu/GrDrawingManager.h
index c72dad976bd184b7b88c48a143d8c40ef5c96507..df6c71a322eb06069815446f794bedac5e90f32a 100644
--- a/src/gpu/GrDrawingManager.h
+++ b/src/gpu/GrDrawingManager.h
@@ -16,6 +16,7 @@
class GrContext;
class GrDrawContext;
+class GrSingleOWner;
class GrSoftwarePathRenderer;
class GrTextContext;
@@ -53,9 +54,11 @@
static bool ProgramUnitTest(GrContext* context, int maxStages);
private:
- GrDrawingManager(GrContext* context, const GrDrawTarget::Options& optionsForDrawTargets)
+ GrDrawingManager(GrContext* context, const GrDrawTarget::Options& optionsForDrawTargets,
+ GrSingleOwner* singleOwner)
: fContext(context)
, fOptionsForDrawTargets(optionsForDrawTargets)
+ , fSingleOwner(singleOwner)
, fAbandoned(false)
, fNVPRTextContext(nullptr)
, fPathRendererChain(nullptr)
@@ -78,6 +81,9 @@
GrContext* fContext;
GrDrawTarget::Options fOptionsForDrawTargets;
+ // In debug builds we guard against improper thread handling
+ GrSingleOwner* fSingleOwner;
+
bool fAbandoned;
SkTDArray<GrDrawTarget*> fDrawTargets;
« no previous file with comments | « src/gpu/GrDrawContext.cpp ('k') | src/gpu/GrDrawingManager.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698