mirror of
https://gitlab.freedesktop.org/wlroots/wlroots.git
synced 2025-11-02 09:01:38 -05:00
wlr_scene: Introduce buffer opaque region metadata
This commit is contained in:
parent
0a9a941ba3
commit
18417026be
2 changed files with 20 additions and 0 deletions
|
|
@ -156,6 +156,7 @@ struct wlr_scene_buffer {
|
|||
struct wlr_fbox src_box;
|
||||
int dst_width, dst_height;
|
||||
enum wl_output_transform transform;
|
||||
pixman_region32_t opaque_region;
|
||||
};
|
||||
|
||||
struct wlr_scene_output_render_list {
|
||||
|
|
@ -346,6 +347,13 @@ void wlr_scene_buffer_set_buffer(struct wlr_scene_buffer *scene_buffer,
|
|||
void wlr_scene_buffer_set_buffer_with_damage(struct wlr_scene_buffer *scene_buffer,
|
||||
struct wlr_buffer *buffer, pixman_region32_t *region);
|
||||
|
||||
/**
|
||||
* Sets the buffer's opaque region. This is an optimization hint used to
|
||||
* determine if buffers which reside under this one need to be rendered or not.
|
||||
*/
|
||||
void wlr_scene_buffer_set_opaque_region(struct wlr_scene_buffer *scene_buffer,
|
||||
pixman_region32_t *region);
|
||||
|
||||
/**
|
||||
* Set the source rectangle describing the region of the buffer which will be
|
||||
* sampled to render this node. This allows cropping the buffer.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue