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

Unified Diff: src/gpu/GrTextureProxy.cpp

Issue 2301523003: Have GrSurfaceProxys and GrGpuResources draw from the same pool of unique ids (Closed)
Patch Set: Add test 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
Index: src/gpu/GrTextureProxy.cpp
diff --git a/src/gpu/GrTextureProxy.cpp b/src/gpu/GrTextureProxy.cpp
index f28b29eee027d46b7911718bc05c09a2c1779c15..88ffd5a76aef00531b86c5fee2b8d6e446181317 100644
--- a/src/gpu/GrTextureProxy.cpp
+++ b/src/gpu/GrTextureProxy.cpp
@@ -10,8 +10,15 @@
#include "GrTextureProvider.h"
#include "GrGpuResourcePriv.h"
+GrTextureProxy::GrTextureProxy(const GrSurfaceDesc& srcDesc, SkBackingFit fit, SkBudgeted budgeted,
+ const void* /*srcData*/, size_t /*rowBytes*/)
+ : INHERITED(srcDesc, fit, budgeted) {
+ // TODO: Handle 'srcData' here
+}
+
GrTextureProxy::GrTextureProxy(sk_sp<GrTexture> tex)
- : INHERITED(tex->desc(), SkBackingFit::kExact, tex->resourcePriv().isBudgeted())
+ : INHERITED(tex->desc(), SkBackingFit::kExact,
+ tex->resourcePriv().isBudgeted(), tex->getUniqueID())
, fTexture(std::move(tex)) {
}

Powered by Google App Engine
This is Rietveld 408576698