output: add generic wlr_output_export_dmabuf implementation

When wlr_output manages its own swap-chain, there's no need to
hook into the backend to grab DMA-BUFs. Instead, maintain a
wlr_output.front_buffer field with the latest committed buffer.
This commit is contained in:
Simon Ser 2021-06-08 09:39:24 +02:00 committed by Simon Zeni
parent 28aa803916
commit 87e8c60faf
2 changed files with 26 additions and 4 deletions

View file

@ -186,7 +186,7 @@ struct wlr_output {
int software_cursor_locks; // number of locks forcing software cursors
struct wlr_swapchain *swapchain;
struct wlr_buffer *back_buffer;
struct wlr_buffer *back_buffer, *front_buffer;
struct wl_listener display_destroy;