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 #include "cc/playback/largest_display_item.h" | 5 #include "cc/playback/largest_display_item.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 | 8 |
9 #include "cc/playback/clip_display_item.h" | 9 #include "cc/playback/clip_display_item.h" |
10 #include "cc/playback/clip_path_display_item.h" | 10 #include "cc/playback/clip_path_display_item.h" |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
61 static_assert(sizeof(TransformDisplayItem) <= kLargestDisplayItemSize, | 61 static_assert(sizeof(TransformDisplayItem) <= kLargestDisplayItemSize, |
62 "Largest Draw Quad size needs update. TransformDisplayItem" | 62 "Largest Draw Quad size needs update. TransformDisplayItem" |
63 " is currently largest."); | 63 " is currently largest."); |
64 static_assert(sizeof(EndTransformDisplayItem) <= kLargestDisplayItemSize, | 64 static_assert(sizeof(EndTransformDisplayItem) <= kLargestDisplayItemSize, |
65 "Largest Draw Quad size needs update. EndTransformDisplayItem" | 65 "Largest Draw Quad size needs update. EndTransformDisplayItem" |
66 " is currently largest."); | 66 " is currently largest."); |
67 | 67 |
68 return kLargestDisplayItemSize; | 68 return kLargestDisplayItemSize; |
69 } | 69 } |
70 | 70 |
| 71 size_t TypicalDisplayItemSize() { |
| 72 // We expect most DisplayItems in a large page to be DrawingDisplayItem. |
| 73 return sizeof(DrawingDisplayItem); |
| 74 } |
| 75 |
71 } // namespace cc | 76 } // namespace cc |
OLD | NEW |