[PATCH weston v2 5/8] compositor-x11: init linux_dmabuf support
Pekka Paalanen
ppaalanen at gmail.com
Wed Jul 1 07:56:17 PDT 2015
From: Pekka Paalanen <pekka.paalanen at collabora.co.uk>
v2 changes:
- only initialize linux_dmabuf if renderer supports it
Signed-off-by: Pekka Paalanen <pekka.paalanen at collabora.co.uk>
Reviewed-by: Daniel Stone <daniels at collabora.com>
---
src/compositor-x11.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/src/compositor-x11.c b/src/compositor-x11.c
index 80ed8c0..286fdff 100644
--- a/src/compositor-x11.c
+++ b/src/compositor-x11.c
@@ -56,6 +56,7 @@
#include "shared/helpers.h"
#include "shared/image-loader.h"
#include "presentation_timing-server-protocol.h"
+#include "linux-dmabuf.h"
#define DEFAULT_AXIS_STEP_DISTANCE wl_fixed_from_int(10)
@@ -1659,6 +1660,12 @@ x11_compositor_create(struct wl_display *display,
x11_compositor_handle_event, c);
wl_event_source_check(c->xcb_source);
+ if (c->base.renderer->import_dmabuf) {
+ if (linux_dmabuf_setup(&c->base) < 0)
+ weston_log("Error: initializing dmabuf "
+ "support failed.\n");
+ }
+
return &c->base;
err_x11_input:
--
2.3.6
More information about the wayland-devel
mailing list