OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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_TILES_PRIORITIZED_TILE_H_ | 5 #ifndef CC_TILES_PRIORITIZED_TILE_H_ |
6 #define CC_TILES_PRIORITIZED_TILE_H_ | 6 #define CC_TILES_PRIORITIZED_TILE_H_ |
7 | 7 |
8 #include "cc/base/cc_export.h" | 8 #include "cc/base/cc_export.h" |
9 #include "cc/playback/display_list_raster_source.h" | 9 #include "cc/playback/raster_source.h" |
10 #include "cc/tiles/tile.h" | 10 #include "cc/tiles/tile.h" |
11 #include "cc/tiles/tile_priority.h" | 11 #include "cc/tiles/tile_priority.h" |
12 | 12 |
13 namespace cc { | 13 namespace cc { |
14 class DisplayListRasterSource; | 14 class RasterSource; |
15 class PictureLayerTiling; | 15 class PictureLayerTiling; |
16 | 16 |
17 class CC_EXPORT PrioritizedTile { | 17 class CC_EXPORT PrioritizedTile { |
18 public: | 18 public: |
19 // This class is constructed and returned by a |PictureLayerTiling|, and | 19 // This class is constructed and returned by a |PictureLayerTiling|, and |
20 // represents a tile and its priority. | 20 // represents a tile and its priority. |
21 PrioritizedTile(); | 21 PrioritizedTile(); |
22 PrioritizedTile(const PrioritizedTile& other); | 22 PrioritizedTile(const PrioritizedTile& other); |
23 ~PrioritizedTile(); | 23 ~PrioritizedTile(); |
24 | 24 |
25 Tile* tile() const { return tile_; } | 25 Tile* tile() const { return tile_; } |
26 const scoped_refptr<DisplayListRasterSource>& raster_source() const { | 26 const scoped_refptr<RasterSource>& raster_source() const { |
27 return raster_source_; | 27 return raster_source_; |
28 } | 28 } |
29 const TilePriority& priority() const { return priority_; } | 29 const TilePriority& priority() const { return priority_; } |
30 bool is_occluded() const { return is_occluded_; } | 30 bool is_occluded() const { return is_occluded_; } |
31 | 31 |
32 void AsValueInto(base::trace_event::TracedValue* value) const; | 32 void AsValueInto(base::trace_event::TracedValue* value) const; |
33 | 33 |
34 private: | 34 private: |
35 friend class PictureLayerTiling; | 35 friend class PictureLayerTiling; |
36 | 36 |
37 PrioritizedTile(Tile* tile, | 37 PrioritizedTile(Tile* tile, |
38 scoped_refptr<DisplayListRasterSource> raster_source, | 38 scoped_refptr<RasterSource> raster_source, |
39 const TilePriority priority, | 39 const TilePriority priority, |
40 bool is_occluded); | 40 bool is_occluded); |
41 | 41 |
42 Tile* tile_; | 42 Tile* tile_; |
43 scoped_refptr<DisplayListRasterSource> raster_source_; | 43 scoped_refptr<RasterSource> raster_source_; |
44 TilePriority priority_; | 44 TilePriority priority_; |
45 bool is_occluded_; | 45 bool is_occluded_; |
46 }; | 46 }; |
47 | 47 |
48 } // namespace cc | 48 } // namespace cc |
49 | 49 |
50 #endif // CC_TILES_PRIORITIZED_TILE_H_ | 50 #endif // CC_TILES_PRIORITIZED_TILE_H_ |
OLD | NEW |