From 51bbf779ba2c9d5954e2c9470a8eae7c1ddd38a5 Mon Sep 17 00:00:00 2001 From: Phil Jones Date: Tue, 7 Jun 2022 13:47:35 +0100 Subject: Switch from using (E)GL to wl_shm. eglInitialize() is slow (~50-100ms), and uses a fair amount of memory (~100 MB). For such a small, simple program that just wants to launch as quickly as possible, wl_shm performs better. --- src/tofi.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/tofi.h') diff --git a/src/tofi.h b/src/tofi.h index 87c0dfe..36869a6 100644 --- a/src/tofi.h +++ b/src/tofi.h @@ -3,7 +3,6 @@ #include #include -#include #include "color.h" #include "entry.h" #include "image.h" @@ -17,6 +16,7 @@ struct tofi { struct wl_compositor *wl_compositor; struct wl_seat *wl_seat; struct wl_output *wl_output; + struct wl_shm *wl_shm; struct zwlr_layer_shell_v1 *zwlr_layer_shell; uint32_t wl_display_name; @@ -24,6 +24,7 @@ struct tofi { uint32_t wl_compositor_name; uint32_t wl_seat_name; uint32_t wl_output_name; + uint32_t wl_shm_name; uint32_t zwlr_layer_shell_name; /* Objects */ -- cgit v1.2.3