[M108 Migration][VD] Avoid pending frame counter becoming negative
[platform/framework/web/chromium-efl.git] / cc / tiles / raster_tile_priority_queue_all.h
1 // Copyright 2015 The Chromium Authors
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CC_TILES_RASTER_TILE_PRIORITY_QUEUE_ALL_H_
6 #define CC_TILES_RASTER_TILE_PRIORITY_QUEUE_ALL_H_
7
8 #include <set>
9 #include <utility>
10 #include <vector>
11
12 #include "cc/cc_export.h"
13 #include "cc/layers/picture_layer_impl.h"
14 #include "cc/tiles/raster_tile_priority_queue.h"
15 #include "cc/tiles/tile_priority.h"
16 #include "cc/tiles/tiling_set_raster_queue_all.h"
17
18 namespace cc {
19
20 class CC_EXPORT RasterTilePriorityQueueAll : public RasterTilePriorityQueue {
21  public:
22   RasterTilePriorityQueueAll();
23   RasterTilePriorityQueueAll(const RasterTilePriorityQueueAll&) = delete;
24   ~RasterTilePriorityQueueAll() override;
25
26   RasterTilePriorityQueueAll& operator=(const RasterTilePriorityQueueAll&) =
27       delete;
28
29   bool IsEmpty() const override;
30   const PrioritizedTile& Top() const override;
31   void Pop() override;
32
33  private:
34   friend class RasterTilePriorityQueue;
35
36   void Build(const std::vector<PictureLayerImpl*>& active_layers,
37              const std::vector<PictureLayerImpl*>& pending_layers,
38              TreePriority tree_priority);
39
40   std::vector<std::unique_ptr<TilingSetRasterQueueAll>>& GetNextQueues();
41   const std::vector<std::unique_ptr<TilingSetRasterQueueAll>>& GetNextQueues()
42       const;
43
44   std::vector<std::unique_ptr<TilingSetRasterQueueAll>> active_queues_;
45   std::vector<std::unique_ptr<TilingSetRasterQueueAll>> pending_queues_;
46   TreePriority tree_priority_;
47 };
48
49 }  // namespace cc
50
51 #endif  // CC_TILES_RASTER_TILE_PRIORITY_QUEUE_ALL_H_