render: introduce wlr_render_rect_pass

Split rectangle rendering out of wlr_render_pass and add a dedicated
wlr_render_rect_pass interface.

Remove the add_rect hook from wlr_render_pass_impl and implement
rectangle rendering separately in the pixman, GLES2 and Vulkan
renderers.
This commit is contained in:
YaoBing Xiao 2026-03-13 10:49:41 +08:00
parent fd870f6d27
commit 33a27b055c
13 changed files with 258 additions and 9 deletions

View file

@ -26,6 +26,10 @@ struct wlr_fbox;
* A renderer for basic 2D operations.
*/
struct wlr_renderer {
struct wlr_render_rect_pass *rect_pass;
void *data;
// Capabilities required for the buffer used as a render target (bitmask of
// enum wlr_buffer_cap)
uint32_t render_buffer_caps;