| OLD | NEW |
| 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 CC_RESOURCES_TILE_H_ | 5 #ifndef CC_RESOURCES_TILE_H_ |
| 6 #define CC_RESOURCES_TILE_H_ | 6 #define CC_RESOURCES_TILE_H_ |
| 7 | 7 |
| 8 #include "base/memory/ref_counted.h" | 8 #include "base/memory/ref_counted.h" |
| 9 #include "cc/base/ref_counted_managed.h" | 9 #include "cc/base/ref_counted_managed.h" |
| 10 #include "cc/resources/raster_source.h" | 10 #include "cc/resources/raster_source.h" |
| (...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 85 bool use_picture_analysis() const { | 85 bool use_picture_analysis() const { |
| 86 return !!(flags_ & USE_PICTURE_ANALYSIS); | 86 return !!(flags_ & USE_PICTURE_ANALYSIS); |
| 87 } | 87 } |
| 88 | 88 |
| 89 bool HasResource() const { return draw_info_.has_resource(); } | 89 bool HasResource() const { return draw_info_.has_resource(); } |
| 90 bool NeedsRaster() const { | 90 bool NeedsRaster() const { |
| 91 return draw_info_.mode() == TileDrawInfo::OOM_MODE || | 91 return draw_info_.mode() == TileDrawInfo::OOM_MODE || |
| 92 !draw_info_.IsReadyToDraw(); | 92 !draw_info_.IsReadyToDraw(); |
| 93 } | 93 } |
| 94 | 94 |
| 95 void AsValueInto(base::trace_event::TracedValue* dict) const; | 95 void AsValueWithPriorityInto(const TilePriority& priority, |
| 96 base::trace_event::TracedValue* dict) const; |
| 96 | 97 |
| 97 inline bool IsReadyToDraw() const { return draw_info_.IsReadyToDraw(); } | 98 inline bool IsReadyToDraw() const { return draw_info_.IsReadyToDraw(); } |
| 98 | 99 |
| 99 const TileDrawInfo& draw_info() const { return draw_info_; } | 100 const TileDrawInfo& draw_info() const { return draw_info_; } |
| 100 | 101 |
| 101 TileDrawInfo& draw_info() { return draw_info_; } | 102 TileDrawInfo& draw_info() { return draw_info_; } |
| 102 | 103 |
| 103 float contents_scale() const { return contents_scale_; } | 104 float contents_scale() const { return contents_scale_; } |
| 104 gfx::Rect content_rect() const { return content_rect_; } | 105 gfx::Rect content_rect() const { return content_rect_; } |
| 105 | 106 |
| (...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 170 unsigned scheduled_priority_; | 171 unsigned scheduled_priority_; |
| 171 | 172 |
| 172 scoped_refptr<RasterTask> raster_task_; | 173 scoped_refptr<RasterTask> raster_task_; |
| 173 | 174 |
| 174 DISALLOW_COPY_AND_ASSIGN(Tile); | 175 DISALLOW_COPY_AND_ASSIGN(Tile); |
| 175 }; | 176 }; |
| 176 | 177 |
| 177 } // namespace cc | 178 } // namespace cc |
| 178 | 179 |
| 179 #endif // CC_RESOURCES_TILE_H_ | 180 #endif // CC_RESOURCES_TILE_H_ |
| OLD | NEW |