aboutsummaryrefslogtreecommitdiff
path: root/rootston/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'rootston/main.c')
-rw-r--r--rootston/main.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/rootston/main.c b/rootston/main.c
index 58e5a5e5..d17079d3 100644
--- a/rootston/main.c
+++ b/rootston/main.c
@@ -4,6 +4,7 @@
#include <unistd.h>
#include <wayland-server.h>
#include <wlr/backend.h>
+#include <wlr/backend/headless.h>
#include <wlr/render.h>
#include <wlr/render/gles2.h>
#include <wlr/util/log.h>
@@ -29,7 +30,11 @@ int main(int argc, char **argv) {
assert(server.wl_display = wl_display_create());
assert(server.wl_event_loop = wl_display_get_event_loop(server.wl_display));
- assert(server.backend = wlr_backend_autocreate(server.wl_display));
+ //assert(server.backend = wlr_backend_autocreate(server.wl_display));
+ assert(server.backend = wlr_headless_backend_create(server.wl_display));
+ wlr_headless_add_output(server.backend, 1280, 720);
+ wlr_headless_add_input_device(server.backend, WLR_INPUT_DEVICE_KEYBOARD);
+ wlr_headless_add_input_device(server.backend, WLR_INPUT_DEVICE_POINTER);
assert(server.renderer = wlr_gles2_renderer_create(server.backend));
server.data_device_manager =