aboutsummaryrefslogtreecommitdiffstats
path: root/include/sway/output.h
diff options
context:
space:
mode:
authorLibravatar emersion <contact@emersion.fr>2018-07-07 10:30:52 +0100
committerLibravatar emersion <contact@emersion.fr>2018-07-07 10:30:52 +0100
commitf9625d1d56482a2c8fce4a2d4743d36607fc639d (patch)
tree1e3109750e276782e331ba70f1dfc70bb987c46c /include/sway/output.h
parentMerge pull request #2216 from RedSoxFan/fix-2213 (diff)
downloadsway-f9625d1d56482a2c8fce4a2d4743d36607fc639d.tar.gz
sway-f9625d1d56482a2c8fce4a2d4743d36607fc639d.tar.zst
sway-f9625d1d56482a2c8fce4a2d4743d36607fc639d.zip
Split renderer
Diffstat (limited to 'include/sway/output.h')
-rw-r--r--include/sway/output.h41
1 files changed, 40 insertions, 1 deletions
diff --git a/include/sway/output.h b/include/sway/output.h
index e6fe55c6..b6cda83c 100644
--- a/include/sway/output.h
+++ b/include/sway/output.h
@@ -38,6 +38,16 @@ struct sway_output {
38 } events; 38 } events;
39}; 39};
40 40
41/**
42 * Contains a surface's root geometry information. For instance, when rendering
43 * a popup, this will contain the parent view's position and size.
44 */
45struct root_geometry {
46 double x, y;
47 int width, height;
48 float rotation;
49};
50
41void output_damage_whole(struct sway_output *output); 51void output_damage_whole(struct sway_output *output);
42 52
43void output_damage_surface(struct sway_output *output, double ox, double oy, 53void output_damage_surface(struct sway_output *output, double ox, double oy,
@@ -56,6 +66,35 @@ struct sway_container *output_by_name(const char *name);
56void output_enable(struct sway_output *output); 66void output_enable(struct sway_output *output);
57 67
58bool output_has_opaque_lockscreen(struct sway_output *output, 68bool output_has_opaque_lockscreen(struct sway_output *output,
59 struct sway_seat *seat); 69 struct sway_seat *seat);
70
71struct sway_container *output_get_active_workspace(struct sway_output *output);
72
73void output_render(struct sway_output *output, struct timespec *when,
74 pixman_region32_t *damage);
75
76bool output_get_surface_box(struct root_geometry *geo,
77 struct sway_output *output, struct wlr_surface *surface, int sx, int sy,
78 struct wlr_box *surface_box);
79
80void output_surface_for_each_surface(struct wlr_surface *surface,
81 double ox, double oy, struct root_geometry *geo,
82 wlr_surface_iterator_func_t iterator, void *user_data);
83
84void output_view_for_each_surface(struct sway_view *view,
85 struct sway_output *output, struct root_geometry *geo,
86 wlr_surface_iterator_func_t iterator, void *user_data);
87
88void output_layer_for_each_surface(struct wl_list *layer_surfaces,
89 struct root_geometry *geo, wlr_surface_iterator_func_t iterator,
90 void *user_data);
91
92void output_unmanaged_for_each_surface(struct wl_list *unmanaged,
93 struct sway_output *output, struct root_geometry *geo,
94 wlr_surface_iterator_func_t iterator, void *user_data);
95
96void output_drag_icons_for_each_surface(struct wl_list *drag_icons,
97 struct sway_output *output, struct root_geometry *geo,
98 wlr_surface_iterator_func_t iterator, void *user_data);
60 99
61#endif 100#endif