OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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_OUTPUT_COMPOSITOR_FRAME_METADATA_H_ | 5 #ifndef CC_OUTPUT_COMPOSITOR_FRAME_METADATA_H_ |
6 #define CC_OUTPUT_COMPOSITOR_FRAME_METADATA_H_ | 6 #define CC_OUTPUT_COMPOSITOR_FRAME_METADATA_H_ |
7 | 7 |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <vector> | 10 #include <vector> |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
70 // it's too small to fill the box the parent reserved for it. | 70 // it's too small to fill the box the parent reserved for it. |
71 SkColor root_background_color = SK_ColorWHITE; | 71 SkColor root_background_color = SK_ColorWHITE; |
72 | 72 |
73 // Provides selection region updates relative to the current viewport. If the | 73 // Provides selection region updates relative to the current viewport. If the |
74 // selection is empty or otherwise unused, the bound types will indicate such. | 74 // selection is empty or otherwise unused, the bound types will indicate such. |
75 Selection<gfx::SelectionBound> selection; | 75 Selection<gfx::SelectionBound> selection; |
76 | 76 |
77 std::vector<ui::LatencyInfo> latency_info; | 77 std::vector<ui::LatencyInfo> latency_info; |
78 | 78 |
79 // This is the set of Surfaces that are referenced by this frame. | 79 // This is the set of Surfaces that are referenced by this frame. |
| 80 // Note: this includes occluded and clipped surfaces and surfaces that may |
| 81 // be accessed by this CompositorFrame in the future. |
| 82 // TODO(fsamuel): In the future, a generalized frame eviction system will |
| 83 // determine which surfaces to retain and which to evict. It will likely |
| 84 // be unnecessary for the embedder to explicitly specify which surfaces to |
| 85 // retain. Thus, this field will likely go away. |
80 std::vector<SurfaceId> referenced_surfaces; | 86 std::vector<SurfaceId> referenced_surfaces; |
81 | 87 |
| 88 // This is the set of SurfaceIds embedded in DrawQuads. |
| 89 std::vector<SurfaceId> embedded_surfaces; |
| 90 |
82 // This indicates whether this CompositorFrame can be activated before | 91 // This indicates whether this CompositorFrame can be activated before |
83 // dependencies have been resolved. | 92 // dependencies have been resolved. |
84 bool can_activate_before_dependencies = true; | 93 bool can_activate_before_dependencies = true; |
85 | 94 |
86 // This is a value that allows the browser to associate compositor frames | 95 // This is a value that allows the browser to associate compositor frames |
87 // with the content that they represent -- typically top-level page loads. | 96 // with the content that they represent -- typically top-level page loads. |
88 // TODO(kenrb, fsamuel): This should eventually by SurfaceID, when they | 97 // TODO(kenrb, fsamuel): This should eventually by SurfaceID, when they |
89 // become available in all renderer processes. See https://crbug.com/695579. | 98 // become available in all renderer processes. See https://crbug.com/695579. |
90 uint32_t content_source_id = 0; | 99 uint32_t content_source_id = 0; |
91 | 100 |
92 // BeginFrameAck for the BeginFrame that this CompositorFrame answers. | 101 // BeginFrameAck for the BeginFrame that this CompositorFrame answers. |
93 BeginFrameAck begin_frame_ack; | 102 BeginFrameAck begin_frame_ack; |
94 | 103 |
95 // Once the display compositor processes a frame containing a non-zero frame | 104 // Once the display compositor processes a frame containing a non-zero frame |
96 // token, the token is sent to embedder of the frame. This is helpful when | 105 // token, the token is sent to embedder of the frame. This is helpful when |
97 // the embedder wants to do something after a particular frame is processed. | 106 // the embedder wants to do something after a particular frame is processed. |
98 uint32_t frame_token = 0; | 107 uint32_t frame_token = 0; |
99 | 108 |
100 private: | 109 private: |
101 CompositorFrameMetadata(const CompositorFrameMetadata& other); | 110 CompositorFrameMetadata(const CompositorFrameMetadata& other); |
102 CompositorFrameMetadata operator=(const CompositorFrameMetadata&) = delete; | 111 CompositorFrameMetadata operator=(const CompositorFrameMetadata&) = delete; |
103 }; | 112 }; |
104 | 113 |
105 } // namespace cc | 114 } // namespace cc |
106 | 115 |
107 #endif // CC_OUTPUT_COMPOSITOR_FRAME_METADATA_H_ | 116 #endif // CC_OUTPUT_COMPOSITOR_FRAME_METADATA_H_ |
OLD | NEW |