From 203fc0f4e4afd71b200a76ff335f6886cf5b9695 Mon Sep 17 00:00:00 2001 From: Maximilian Seidler <78690852+PaideiaDilemma@users.noreply.github.com> Date: Tue, 24 Sep 2024 19:09:40 +0000 Subject: [PATCH] headless: add a default mode for headless outputs (#87) --- src/backend/Headless.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/backend/Headless.cpp b/src/backend/Headless.cpp index 1d6124b..16fd5d9 100644 --- a/src/backend/Headless.cpp +++ b/src/backend/Headless.cpp @@ -131,6 +131,7 @@ std::vector Aquamarine::CHeadlessBackend::getCursorFormats() { bool Aquamarine::CHeadlessBackend::createOutput(const std::string& name) { auto output = SP(new CHeadlessOutput(name.empty() ? std::format("HEADLESS-{}", ++outputIDCounter) : name, self.lock())); outputs.emplace_back(output); + output->modes.emplace_back(SP(new SOutputMode(Vector2D{1920, 1080}, 60, true))); output->swapchain = CSwapchain::create(backend->primaryAllocator, self.lock()); output->self = output; backend->events.newOutput.emit(SP(output));