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

Unified Diff: src/gpu/gl/GrGLStencilAttachment.h

Issue 1810323002: Cache render targets that render to wrapped textures Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 9 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
Index: src/gpu/gl/GrGLStencilAttachment.h
diff --git a/src/gpu/gl/GrGLStencilAttachment.h b/src/gpu/gl/GrGLStencilAttachment.h
index 3b89a5aa21123e1a16af4e3b3d93ac89b1aee66b..90a9a9149f0637e3dd911cb14211e9d8483bcbf6 100644
--- a/src/gpu/gl/GrGLStencilAttachment.h
+++ b/src/gpu/gl/GrGLStencilAttachment.h
@@ -24,9 +24,8 @@ public:
};
struct IDDesc {
- IDDesc() : fRenderbufferID(0), fLifeCycle(kCached_LifeCycle) {}
+ IDDesc() : fRenderbufferID(0) {}
GrGLuint fRenderbufferID;
- GrGpuResource::LifeCycle fLifeCycle;
};
GrGLStencilAttachment(GrGpu* gpu,
@@ -34,7 +33,7 @@ public:
int width, int height,
int sampleCnt,
const Format& format)
- : GrStencilAttachment(gpu, idDesc.fLifeCycle, width, height, format.fStencilBits, sampleCnt)
+ : GrStencilAttachment(gpu, SkBudgeted::kYes, width, height, format.fStencilBits, sampleCnt)
, fFormat(format)
, fRenderbufferID(idDesc.fRenderbufferID) {
this->registerWithCache();
@@ -50,6 +49,7 @@ protected:
// overrides of GrResource
void onRelease() override;
void onAbandon() override;
+ bool refsWrappedResources() const override { return false; }
void setMemoryBacking(SkTraceMemoryDump* traceMemoryDump,
const SkString& dumpName) const override;

Powered by Google App Engine
This is Rietveld 408576698