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

Unified Diff: cc/CCPrioritizedTexture.h

Issue 10947017: Enable removing uploads to evicted textures from texture upload queues. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Incorporate review feedback Created 8 years, 3 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 | « cc/CCLayerTreeHost.cpp ('k') | cc/CCPrioritizedTexture.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/CCPrioritizedTexture.h
diff --git a/cc/CCPrioritizedTexture.h b/cc/CCPrioritizedTexture.h
index a65a782d06d311ffe83c908e8637b55eb23e2b1b..cd33d11ec1e5c62cdd403b42db893c139c353a96 100644
--- a/cc/CCPrioritizedTexture.h
+++ b/cc/CCPrioritizedTexture.h
@@ -52,6 +52,8 @@ public:
// taken away "soon".
bool haveBackingTexture() const { return !!backing(); }
+ bool backingResourceWasEvicted() const;
+
// If canAcquireBackingTexture() is true acquireBackingTexture() will acquire
// a backing texture for use. Call this whenever the texture is actually needed.
void acquireBackingTexture(CCResourceProvider*);
@@ -85,7 +87,7 @@ private:
class Backing : public CCTexture {
WTF_MAKE_NONCOPYABLE(Backing);
public:
- Backing(unsigned id, IntSize, GC3Denum format);
+ Backing(unsigned id, CCResourceProvider*, IntSize, GC3Denum format);
~Backing();
void updatePriority();
@@ -94,12 +96,19 @@ private:
bool requestPriorityAtLastPriorityUpdate() const { return m_priorityAtLastPriorityUpdate; }
bool wasAbovePriorityCutoffAtLastPriorityUpdate() const { return m_wasAbovePriorityCutoffAtLastPriorityUpdate; }
+ void deleteResource(CCResourceProvider*);
+ bool resourceHasBeenDeleted() const;
+
private:
friend class CCPrioritizedTexture;
CCPrioritizedTexture* m_owner;
int m_priorityAtLastPriorityUpdate;
bool m_ownerExistedAtLastPriorityUpdate;
bool m_wasAbovePriorityCutoffAtLastPriorityUpdate;
+ bool m_resourceHasBeenDeleted;
+#ifndef NDEBUG
+ CCResourceProvider* m_resourceProvider;
+#endif
};
CCPrioritizedTexture(CCPrioritizedTextureManager*, IntSize, GC3Denum format);
« no previous file with comments | « cc/CCLayerTreeHost.cpp ('k') | cc/CCPrioritizedTexture.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698