From b19611e841bbbb8e4886682233202e70852d0143 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=AE=8B=E6=96=87=E6=AD=A6?= Date: Sat, 12 Oct 2024 21:01:20 +0800 Subject: [PATCH] allow software renderer --- desktop_version/src/Screen.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/desktop_version/src/Screen.cpp b/desktop_version/src/Screen.cpp index cedf3115..fd5d20f7 100644 --- a/desktop_version/src/Screen.cpp +++ b/desktop_version/src/Screen.cpp @@ -62,6 +62,9 @@ void Screen::init(const struct ScreenSettings* settings) m_renderer = SDL_CreateRenderer(m_window, -1, SDL_RENDERER_ACCELERATED | SDL_RENDERER_TARGETTEXTURE); + if (m_renderer == NULL) + m_renderer = SDL_CreateRenderer(m_window, -1, 0); + if (m_renderer == NULL) { vlog_error("Could not create renderer: %s", SDL_GetError());