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

Unified Diff: src/gpu/GrDrawContext.cpp

Issue 2208483004: Remove GrRenderTarget member variable from SkGpuDevice (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 4 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 | « no previous file | src/gpu/GrDrawContextPriv.h » ('j') | src/gpu/SkGpuDevice.cpp » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrDrawContext.cpp
diff --git a/src/gpu/GrDrawContext.cpp b/src/gpu/GrDrawContext.cpp
index 195cb7a91176c0d28986bd1f9195663d3a5b9b86..9cfd34e006f84e8b83445bbc1f2ef6565a33fc91 100644
--- a/src/gpu/GrDrawContext.cpp
+++ b/src/gpu/GrDrawContext.cpp
@@ -10,6 +10,7 @@
#include "GrDrawContext.h"
#include "GrDrawContextPriv.h"
#include "GrDrawingManager.h"
+#include "GrGpuResourcePriv.h"
#include "GrOvalRenderer.h"
#include "GrPathRenderer.h"
#include "GrPipelineBuilder.h"
@@ -1216,6 +1217,18 @@ bool GrDrawContextPriv::drawAndStencilPath(const GrFixedClip& clip,
return true;
}
+SkBudgeted GrDrawContextPriv::isBudgeted() const {
+ ASSERT_SINGLE_OWNER_PRIV
+
+ if (fDrawContext->fDrawingManager->wasAbandoned()) {
egdaniel 2016/08/03 19:55:06 can we just do fDrawContext->wasAbandoned()?
robertphillips 2016/08/03 20:36:09 Done.
+ return SkBudgeted::kNo;
+ }
+
+ SkDEBUGCODE(fDrawContext->validate();)
+
+ return fDrawContext->fRenderTarget->resourcePriv().isBudgeted();
+}
+
void GrDrawContext::internalDrawPath(const GrClip& clip,
const GrPaint& paint,
const SkMatrix& viewMatrix,
« no previous file with comments | « no previous file | src/gpu/GrDrawContextPriv.h » ('j') | src/gpu/SkGpuDevice.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698