From cace5079fe81fb03b63cc5d10db6b47a4b933c2d Mon Sep 17 00:00:00 2001 From: Magnus Norddahl Date: Thu, 9 May 2019 16:06:18 +0200 Subject: [PATCH] - oops, patched the wrong file --- src/rendering/swrenderer/drawers/r_thread.cpp | 12 +++++++++++- src/rendering/swrenderer/scene/r_scene.cpp | 10 ---------- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/src/rendering/swrenderer/drawers/r_thread.cpp b/src/rendering/swrenderer/drawers/r_thread.cpp index b04bde383..d5b9124fd 100644 --- a/src/rendering/swrenderer/drawers/r_thread.cpp +++ b/src/rendering/swrenderer/drawers/r_thread.cpp @@ -187,7 +187,17 @@ void DrawerThreads::StartThreads() int num_threads = num_numathreads; if (num_threads == 0) - num_threads = 4; + { + static bool firstCall = true; + if (firstCall) + { + firstCall = false; + if (r_multithreaded == 1) + Printf("Warning: Unable to determine number of CPU cores/threads for this computer. To improve performance, please type 'r_multithreaded x' in the console, where x is the number of threads to use.\n"); + } + + num_threads = 1; + } if (r_multithreaded == 0) num_threads = 1; diff --git a/src/rendering/swrenderer/scene/r_scene.cpp b/src/rendering/swrenderer/scene/r_scene.cpp index a4c06d311..76fbec103 100644 --- a/src/rendering/swrenderer/scene/r_scene.cpp +++ b/src/rendering/swrenderer/scene/r_scene.cpp @@ -200,17 +200,7 @@ namespace swrenderer { int numThreads = std::thread::hardware_concurrency(); if (numThreads == 0) - { - static bool firstCall = true; - if (firstCall) - { - firstCall = false; - if (r_multithreaded == 1) - Printf("Warning: Unable to determine number of CPU cores/threads for this computer. To improve performance, please type 'r_multithreaded x' in the console, where x is the number of threads to use.\n"); - } - numThreads = 1; - } if (r_scene_multithreaded == 0 || r_multithreaded == 0) numThreads = 1;