Revert "Disable multithreading in R_DrawMaskedList"

This reverts commit 5a44afcd9f.
This commit is contained in:
indev committed 2025-07-08 00:10:08 +03:00
1 parent 96f5a8adb3
commit 8d570b7ba3
1 file changed
+10 -2
+10 -2
View File
@@ -2970,8 +2970,16 @@ static void R_DrawMaskedList(drawnode_t* head)
{
drawspandata_t ds = {};
next = r2->prev;
// Force disable multithreading since it is usually slower because of waiting for each plane to render
R_DrawSinglePlane(&ds, r2->plane, false);
#ifdef HAVE_THREADS
srb2::ThreadPool::Sema tp_sema;
srb2::g_main_threadpool->begin_sema();
#endif
R_DrawSinglePlane(&ds, r2->plane, cv_parallelsoftware.value);
#ifdef HAVE_THREADS
tp_sema = srb2::g_main_threadpool->end_sema();
srb2::g_main_threadpool->notify_sema(tp_sema);
srb2::g_main_threadpool->wait_sema(tp_sema);
#endif
R_DoneWithNode(r2);
r2 = next;
}