Add useful wayland RAII wrappers

Signed-off-by: Slendi <slendi@socopon.com>
This commit is contained in:
2026-01-26 18:27:27 +02:00
parent efa6e289b6
commit e04f1cf291
7 changed files with 617 additions and 1 deletions

View File

@@ -5,7 +5,6 @@
#include <filesystem>
#include <functional>
#include <memory>
#include <string>
#include <vector>
#include <SDL3/SDL_video.h>
@@ -19,6 +18,7 @@
#include "Logger.h"
#include "Skybox.h"
#include "Types.h"
#include "wayland/Display.h"
struct libinput;
struct libinput_event_keyboard;
@@ -55,6 +55,7 @@ private:
auto init_input() -> void;
auto init_test_meshes() -> void;
auto init_wayland() -> void;
auto asset_directory() -> std::filesystem::path;
auto shutdown_input() -> void;
auto process_libinput_events() -> void;
@@ -79,6 +80,10 @@ private:
auto render_hands(
VulkanRenderer::GL &gl, smath::Mat4 const &view_projection) -> void;
struct {
Wayland::Display display;
} m_wayland;
SDL_Window *m_window { nullptr };
Backend m_backend { Backend::SDL };
Logger m_logger { "Lunar" };