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

Unified Diff: cc/resources/eviction_tile_priority_queue.h

Issue 900073003: cc: Rework how picture layer tiling set gets into raster queues. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: update Created 5 years, 10 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/layers/picture_layer_impl_unittest.cc ('k') | cc/resources/eviction_tile_priority_queue.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/resources/eviction_tile_priority_queue.h
diff --git a/cc/resources/eviction_tile_priority_queue.h b/cc/resources/eviction_tile_priority_queue.h
index ab705f71d8057a86e9f4439fb664df5aa2b91352..a16b6f6c6ec65b1edaa421055a046c18ae18b4aa 100644
--- a/cc/resources/eviction_tile_priority_queue.h
+++ b/cc/resources/eviction_tile_priority_queue.h
@@ -9,6 +9,7 @@
#include <utility>
#include <vector>
+#include "base/containers/hash_tables.h"
#include "cc/base/cc_export.h"
#include "cc/layers/picture_layer_impl.h"
#include "cc/resources/tile_priority.h"
@@ -20,7 +21,8 @@ class CC_EXPORT EvictionTilePriorityQueue {
public:
struct PairedTilingSetQueue {
PairedTilingSetQueue();
- PairedTilingSetQueue(const PictureLayerImpl::Pair& layer_pair,
+ PairedTilingSetQueue(PictureLayerTilingSet* active_set,
+ PictureLayerTilingSet* pending_set,
TreePriority tree_priority);
~PairedTilingSetQueue();
@@ -37,17 +39,26 @@ class CC_EXPORT EvictionTilePriorityQueue {
std::set<const Tile*> returned_tiles_for_debug;
};
- EvictionTilePriorityQueue();
- ~EvictionTilePriorityQueue();
+ static scoped_ptr<EvictionTilePriorityQueue> Create(
+ const base::hash_map<int, PictureLayerTilingSet::Pair>&
+ paired_picture_layer_tiling_sets,
+ bool has_pending_tree,
+ TreePriority tree_priority);
- void Build(const std::vector<PictureLayerImpl::Pair>& paired_layers,
- TreePriority tree_priority);
+ ~EvictionTilePriorityQueue();
bool IsEmpty() const;
Tile* Top();
void Pop();
private:
+ EvictionTilePriorityQueue();
+
+ void Build(const base::hash_map<int, PictureLayerTilingSet::Pair>&
+ paired_picture_layer_tiling_sets,
+ bool has_pending_tree,
+ TreePriority tree_priority);
+
// TODO(vmpstr): This is potentially unnecessary if it becomes the case that
// PairedTilingSetQueue is fast enough to copy. In that case, we can use
// objects directly (ie std::vector<PairedTilingSetQueue>).
« 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