aboutsummaryrefslogtreecommitdiff
path: root/include/backend/wayland.h
diff options
context:
space:
mode:
authorDrew DeVault <sir@cmpwn.com>2017-06-20 17:54:33 -0400
committerGitHub <noreply@github.com>2017-06-20 17:54:33 -0400
commit33f2c66fca6e8a628fe3f36d1abacf87226042de (patch)
tree1381f243d1bb9df41691e2b92593a8495bb80f37 /include/backend/wayland.h
parent2f03ea0a6bea6c099f148eb745a725ca77813885 (diff)
parentb9d36c8149536cff1aa229f59337dcfa2f70a37b (diff)
Merge pull request #17 from nyorain/wayland-backend
Basic Wayland backend
Diffstat (limited to 'include/backend/wayland.h')
-rw-r--r--include/backend/wayland.h40
1 files changed, 34 insertions, 6 deletions
diff --git a/include/backend/wayland.h b/include/backend/wayland.h
index 94aa0962..03667c9a 100644
--- a/include/backend/wayland.h
+++ b/include/backend/wayland.h
@@ -3,10 +3,12 @@
#include <wayland-client.h>
#include <wayland-server.h>
+#include <wayland-egl.h>
#include <wlr/common/list.h>
-#include <wlr/wayland.h>
+#include <wlr/backend/wayland.h>
+#include "backend/egl.h"
-struct wlr_wl_backend {
+struct wlr_backend_state {
/* local state */
struct wl_display *local_display;
/* remote state */
@@ -15,13 +17,39 @@ struct wlr_wl_backend {
struct wl_compositor *compositor;
struct wl_shell *shell;
struct wl_shm *shm;
- struct wlr_wl_seat *seat;
- list_t *outputs;
+ struct wl_seat *seat;
+ const char *seatName;
+
+ struct wlr_backend *backend;
+ list_t *devices;
+
+ struct wl_event_source* remote_display_src;
+
+ size_t num_outputs;
+ struct wlr_output **outputs;
+ struct wlr_egl egl;
+};
+
+struct wlr_output_state {
+ size_t id;
+ struct wlr_backend_state *backend;
+ struct wlr_output *output;
+ struct wl_surface *surface;
+ struct wl_shell_surface *shell_surface;
+ struct wl_egl_window* egl_window;
+ struct wl_callback* frame_callback;
+ void* egl_surface;
+};
+
+struct wlr_input_device_state {
+ enum wlr_input_device_type type;
+ void *resource;
};
-void wlr_wlb_registry_poll(struct wlr_wl_backend *backend);
+void wlr_wl_registry_poll(struct wlr_backend_state *backend);
+struct wlr_output *wlr_wl_output_create(struct wlr_backend_state* backend,
+ size_t id);
extern const struct wl_seat_listener seat_listener;
-extern const struct wl_output_listener output_listener;
#endif