Make wayland required

Signed-off-by: Slendi <slendi@socopon.com>
This commit is contained in:
2026-02-01 20:18:20 +02:00
parent 92912a321c
commit 864a0fd2fe

View File

@@ -719,7 +719,8 @@ auto Application::run() -> void
float fps { 0.0f };
while (m_running) {
GZoneScopedN("Frame");
if (m_wayland) {
{
assert(m_wayland);
m_wayland->dispatch();
m_wayland->flush();
}
@@ -1082,7 +1083,8 @@ auto Application::run() -> void
render_hands(gl, view_projection);
}
if (m_wayland) {
assert(m_wayland);
auto const wayland_draw_extent { m_renderer->draw_extent() };
auto const draw_width { static_cast<float>(
wayland_draw_extent.width) };
@@ -1102,14 +1104,12 @@ auto Application::run() -> void
continue;
}
auto const width { static_cast<float>(buffer->width) };
auto const height { static_cast<float>(
buffer->height) };
auto const height { static_cast<float>(buffer->height) };
auto const size { smath::Vec2 {
(width / draw_width) * 2.0f,
(height / draw_height) * 2.0f,
} };
auto const pos { smath::Vec2 {
-1.0f, 1.0f - size.y() } };
auto const pos { smath::Vec2 { -1.0f, 1.0f - size.y() } };
auto image { m_renderer->create_image(
*texture, vk::ImageUsageFlagBits::eSampled) };
gl.set_texture(&image);
@@ -1121,7 +1121,6 @@ auto Application::run() -> void
gl.use_pipeline(m_renderer->mesh_pipeline());
gl.set_culling(true);
}
}
} };
if (xr_active) {