diff options
author | Isaac Freund <mail@isaacfreund.com> | 2021-12-11 12:25:53 +0100 |
---|---|---|
committer | Simon Ser <contact@emersion.fr> | 2021-12-13 15:21:05 +0000 |
commit | fb1f613510b871bcc117179a9d3a32aabc4508c0 (patch) | |
tree | b0d41204945e23fb6615bf431f353b92351f65dd /include/wlr | |
parent | 0215dffba51b63dc394ee028039ac811e1330c60 (diff) |
scene: add primary output to wlr_scene_surface
This allows compositors to avoid sending multiple frame done events
to a surface that is rendered on multiple outputs at once. This may
also be used in the same way for presentation feedback.
Diffstat (limited to 'include/wlr')
-rw-r--r-- | include/wlr/types/wlr_scene.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/include/wlr/types/wlr_scene.h b/include/wlr/types/wlr_scene.h index 1238653d..6c2928ee 100644 --- a/include/wlr/types/wlr_scene.h +++ b/include/wlr/types/wlr_scene.h @@ -74,6 +74,14 @@ struct wlr_scene_surface { struct wlr_scene_node node; struct wlr_surface *surface; + /** + * The output that the largest area of this surface is displayed on. + * This may be NULL if the surface is not currently displayed on any + * outputs. This is the output that should be used for frame callbacks, + * presentation feedback, etc. + */ + struct wlr_output *primary_output; + // private state int prev_width, prev_height; |