diff options
author | random human <random.bored.human@gmail.com> | 2018-10-04 02:01:04 +0530 |
---|---|---|
committer | random human <random.bored.human@gmail.com> | 2018-10-04 02:19:09 +0530 |
commit | 3e0a0f3c3acef811bc355af766b2a46c625fecd2 (patch) | |
tree | d9d803a00006fa1a06fa6e3e487d120843b4130c /include/wlr | |
parent | 84ecfb546bdb2e5b21907d1ef62f6aa7477ff094 (diff) |
wlr_surface: add wlr_surface_get_effective_damage
This calculates and returns the effective damage of the surface in
surface coordinates, including the client damage (in buffer
coordinates), and damage induced by resize or move events.
Diffstat (limited to 'include/wlr')
-rw-r--r-- | include/wlr/types/wlr_surface.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/include/wlr/types/wlr_surface.h b/include/wlr/types/wlr_surface.h index 063f9e26..ef789b82 100644 --- a/include/wlr/types/wlr_surface.h +++ b/include/wlr/types/wlr_surface.h @@ -229,4 +229,12 @@ struct wlr_surface *wlr_surface_from_resource(struct wl_resource *resource); void wlr_surface_for_each_surface(struct wlr_surface *surface, wlr_surface_iterator_func_t iterator, void *user_data); +/** + * Get the effective damage to the surface in terms of surface local + * coordinates. This includes damage induced by resizing and moving the + * surface. The damage is not expected to be bounded by the surface itself. + */ +void wlr_surface_get_effective_damage(struct wlr_surface *surface, + pixman_region32_t *damage); + #endif |