render/pixman: Add dmabuf support

Adds linux-dmabuf support to the pixman renderer.  The main reason is so
clients can use GPU-accelerated rendering even if the compositor is
using the pixman renderer for whatever reason.  This also allows the
pixman renderer to import dmabufs (only RGB/ARGB formats, not YUV for
now).

Since after this change all renderers store a DRM FD, I move the drm_fd
from the individual implementations to the shared wlr_renderer base.
This means that renderer_autocreate() can set pixman's drm_fd for it and
the pixman renderer doesn't have to know about DRM at all.

Originally based on
961edfe44e
This commit is contained in:
David Turner 2024-06-10 17:10:20 +01:00
parent 27bbb91abf
commit e4ccc8e822
10 changed files with 36 additions and 42 deletions

View file

@ -55,6 +55,7 @@ struct wlr_renderer {
struct {
const struct wlr_renderer_impl *impl;
int drm_fd;
} WLR_PRIVATE;
};