aboutsummaryrefslogtreecommitdiff
path: root/backend/headless/backend.c
diff options
context:
space:
mode:
authoremersion <contact@emersion.fr>2017-12-17 13:35:07 +0100
committeremersion <contact@emersion.fr>2017-12-17 13:35:07 +0100
commitb852fb9a2b3842dc6d122a2483c11322beb7a489 (patch)
treea25fbd34078ae03a7e42eb323509189947fda001 /backend/headless/backend.c
parent3970264ccffd30ab1bf06d7dab4f6cc176b9d797 (diff)
Minimal working headless output
Diffstat (limited to 'backend/headless/backend.c')
-rw-r--r--backend/headless/backend.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/backend/headless/backend.c b/backend/headless/backend.c
index c60eb7e5..bc2de2f2 100644
--- a/backend/headless/backend.c
+++ b/backend/headless/backend.c
@@ -26,6 +26,9 @@ static void backend_destroy(struct wlr_backend *wlr_backend) {
}
wl_list_remove(&backend->display_destroy.link);
+
+ // TODO: destroy outputs
+
wlr_egl_finish(&backend->egl);
free(backend);
}
@@ -61,6 +64,12 @@ static bool egl_get_config(EGLDisplay disp, EGLConfig *out) {
static const EGLint attribs[] = {
EGL_SURFACE_TYPE, EGL_PBUFFER_BIT,
+ EGL_BUFFER_SIZE, 32,
+ EGL_ALPHA_SIZE, 0,
+ EGL_BLUE_SIZE, 8,
+ EGL_GREEN_SIZE, 8,
+ EGL_RED_SIZE, 8,
+ EGL_RENDERABLE_TYPE, EGL_OPENGL_ES2_BIT,
EGL_NONE,
};
@@ -146,6 +155,7 @@ struct wlr_backend *wlr_headless_backend_create(struct wl_display *display) {
}
wlr_backend_init(&backend->backend, &backend_impl);
backend->display = display;
+ wl_list_init(&backend->outputs);
egl_init(&backend->egl);