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

Side by Side Diff: cc/CCTextureUpdateQueue.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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « cc/CCTextureUpdateControllerTest.cpp ('k') | cc/CCTextureUpdateQueue.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CCTextureUpdateQueue_h 5 #ifndef CCTextureUpdateQueue_h
6 #define CCTextureUpdateQueue_h 6 #define CCTextureUpdateQueue_h
7 7
8 #include "TextureCopier.h" 8 #include "TextureCopier.h"
9 #include "TextureUploader.h" 9 #include "TextureUploader.h"
10 #include <wtf/Deque.h> 10 #include <wtf/Deque.h>
11 #include <wtf/Noncopyable.h> 11 #include <wtf/Noncopyable.h>
12 12
13 namespace cc { 13 namespace cc {
14 14
15 class CCTextureUpdateQueue { 15 class CCTextureUpdateQueue {
16 WTF_MAKE_NONCOPYABLE(CCTextureUpdateQueue); 16 WTF_MAKE_NONCOPYABLE(CCTextureUpdateQueue);
17 public: 17 public:
18 CCTextureUpdateQueue(); 18 CCTextureUpdateQueue();
19 virtual ~CCTextureUpdateQueue(); 19 virtual ~CCTextureUpdateQueue();
20 20
21 void appendFullUpload(TextureUploader::Parameters); 21 void appendFullUpload(TextureUploader::Parameters);
22 void appendPartialUpload(TextureUploader::Parameters); 22 void appendPartialUpload(TextureUploader::Parameters);
23 void appendCopy(TextureCopier::Parameters); 23 void appendCopy(TextureCopier::Parameters);
24 24
25 void clearUploads(); 25 void clearUploadsToEvictedResources();
26 26
27 TextureUploader::Parameters takeFirstFullUpload(); 27 TextureUploader::Parameters takeFirstFullUpload();
28 TextureUploader::Parameters takeFirstPartialUpload(); 28 TextureUploader::Parameters takeFirstPartialUpload();
29 TextureCopier::Parameters takeFirstCopy(); 29 TextureCopier::Parameters takeFirstCopy();
30 30
31 size_t fullUploadSize() const { return m_fullEntries.size(); } 31 size_t fullUploadSize() const { return m_fullEntries.size(); }
32 size_t partialUploadSize() const { return m_partialEntries.size(); } 32 size_t partialUploadSize() const { return m_partialEntries.size(); }
33 size_t copySize() const { return m_copyEntries.size(); } 33 size_t copySize() const { return m_copyEntries.size(); }
34 34
35 bool hasMoreUpdates() const; 35 bool hasMoreUpdates() const;
36 36
37 private: 37 private:
38 void clearUploadsToEvictedResources(Deque<TextureUploader::Parameters>& entr yQueue);
38 Deque<TextureUploader::Parameters> m_fullEntries; 39 Deque<TextureUploader::Parameters> m_fullEntries;
39 Deque<TextureUploader::Parameters> m_partialEntries; 40 Deque<TextureUploader::Parameters> m_partialEntries;
40 Deque<TextureCopier::Parameters> m_copyEntries; 41 Deque<TextureCopier::Parameters> m_copyEntries;
41 }; 42 };
42 43
43 } 44 }
44 45
45 #endif // CCTextureUpdateQueue_h 46 #endif // CCTextureUpdateQueue_h
OLDNEW
« no previous file with comments | « cc/CCTextureUpdateControllerTest.cpp ('k') | cc/CCTextureUpdateQueue.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698