This commit is contained in:
2026-05-19 22:35:10 +02:00
parent d93e71e716
commit 0b45643ef2
21 changed files with 806 additions and 235 deletions

View File

@@ -28,6 +28,8 @@ namespace Game::Window {
static SDL_Window* getSDLWindowBackend() { std::scoped_lock lock(sMutex); return sWindowBackend; }
Renderer::Renderer* getRenderer() { std::scoped_lock lock(mMutex); return &mRenderer; }
// Post a task to be executed on the window/event thread.
static void postToMainThread(std::function<void()> fn);
private:
mutable std::mutex mMutex;