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

Side by Side Diff: cc/resources/eviction_tile_priority_queue.h

Issue 1130123003: cc: Separate the priority from the tile and put in new PrioritizedTile (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: merge Created 5 years, 7 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
« no previous file with comments | « cc/layers/picture_layer_impl_unittest.cc ('k') | cc/resources/eviction_tile_priority_queue.cc » ('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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 CC_RESOURCES_EVICTION_TILE_PRIORITY_QUEUE_H_ 5 #ifndef CC_RESOURCES_EVICTION_TILE_PRIORITY_QUEUE_H_
6 #define CC_RESOURCES_EVICTION_TILE_PRIORITY_QUEUE_H_ 6 #define CC_RESOURCES_EVICTION_TILE_PRIORITY_QUEUE_H_
7 7
8 #include <set> 8 #include <set>
9 #include <utility> 9 #include <utility>
10 #include <vector> 10 #include <vector>
11 11
12 #include "cc/base/cc_export.h" 12 #include "cc/base/cc_export.h"
13 #include "cc/layers/picture_layer_impl.h" 13 #include "cc/layers/picture_layer_impl.h"
14 #include "cc/resources/tile_priority.h" 14 #include "cc/resources/tile_priority.h"
15 #include "cc/resources/tiling_set_eviction_queue.h" 15 #include "cc/resources/tiling_set_eviction_queue.h"
16 16
17 namespace cc { 17 namespace cc {
18 class PrioritizedTile;
18 19
19 class CC_EXPORT EvictionTilePriorityQueue { 20 class CC_EXPORT EvictionTilePriorityQueue {
20 public: 21 public:
21 EvictionTilePriorityQueue(); 22 EvictionTilePriorityQueue();
22 ~EvictionTilePriorityQueue(); 23 ~EvictionTilePriorityQueue();
23 24
24 void Build(const std::vector<PictureLayerImpl*>& active_layers, 25 void Build(const std::vector<PictureLayerImpl*>& active_layers,
25 const std::vector<PictureLayerImpl*>& pending_layers, 26 const std::vector<PictureLayerImpl*>& pending_layers,
26 TreePriority tree_priority); 27 TreePriority tree_priority);
27 28
28 bool IsEmpty() const; 29 bool IsEmpty() const;
29 Tile* Top(); 30 const PrioritizedTile& Top() const;
30 void Pop(); 31 void Pop();
31 32
32 private: 33 private:
33 ScopedPtrVector<TilingSetEvictionQueue>& GetNextQueues(); 34 ScopedPtrVector<TilingSetEvictionQueue>& GetNextQueues();
35 const ScopedPtrVector<TilingSetEvictionQueue>& GetNextQueues() const;
34 36
35 ScopedPtrVector<TilingSetEvictionQueue> active_queues_; 37 ScopedPtrVector<TilingSetEvictionQueue> active_queues_;
36 ScopedPtrVector<TilingSetEvictionQueue> pending_queues_; 38 ScopedPtrVector<TilingSetEvictionQueue> pending_queues_;
37 TreePriority tree_priority_; 39 TreePriority tree_priority_;
38 40
39 DISALLOW_COPY_AND_ASSIGN(EvictionTilePriorityQueue); 41 DISALLOW_COPY_AND_ASSIGN(EvictionTilePriorityQueue);
40 }; 42 };
41 43
42 } // namespace cc 44 } // namespace cc
43 45
44 #endif // CC_RESOURCES_EVICTION_TILE_PRIORITY_QUEUE_H_ 46 #endif // CC_RESOURCES_EVICTION_TILE_PRIORITY_QUEUE_H_
OLDNEW
« no previous file with comments | « cc/layers/picture_layer_impl_unittest.cc ('k') | cc/resources/eviction_tile_priority_queue.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698