Own runtime threads and thin platform/canvas seams

This commit is contained in:
2026-06-16 07:34:59 +02:00
parent 17b603536b
commit 6f4bd4b26f
10 changed files with 354 additions and 200 deletions

View File

@@ -43,12 +43,12 @@ public:
void notify_ui_worker() noexcept;
void render_thread_tick(App& app);
void render_thread_main(App& app);
void render_thread_main(App& app, std::stop_token stop_token);
void render_thread_start(App& app);
void render_thread_stop();
void ui_thread_tick(App& app);
void ui_thread_main(App& app);
void ui_thread_main(App& app, std::stop_token stop_token);
void ui_thread_start(App& app);
void ui_thread_stop();
@@ -202,14 +202,14 @@ private:
std::deque<AppTask> render_tasklist_;
std::mutex render_task_mutex_;
std::condition_variable render_cv_;
std::thread render_thread_;
std::jthread render_thread_;
std::thread::id render_thread_id_;
bool render_running_ = false;
std::deque<AppTask> ui_tasklist_;
std::mutex ui_task_mutex_;
std::condition_variable ui_cv_;
std::thread ui_thread_;
std::jthread ui_thread_;
std::thread::id ui_thread_id_;
bool ui_running_ = false;
bool request_redraw_ = false;