allow threaded render for maskedlist planes

since sky synchronizuation issues are fixed, this no longer causes any issues and gives a nice speed bump in some occasions
This commit is contained in:
Alug 2025-06-27 12:49:01 +02:00
parent f30d472ad2
commit c8ef0fb705
2 changed files with 6 additions and 2 deletions

View file

@ -1527,7 +1527,6 @@ void R_RenderPlayerView(void)
{
INT32 nummasks = 1;
maskcount_t* masks = static_cast<maskcount_t*>(malloc(sizeof(maskcount_t)));
player_t * player = &players[displayplayers[viewssnum]];
const boolean skybox = (skyboxmo[0] && cv_skybox.value);
const boolean oldsky = (skybox && mapnamespace == MNS_SRB2KART);

View file

@ -3814,7 +3814,12 @@ static void R_DrawMaskedList (drawnode_t* head)
{
drawspandata_t ds = {0};
next = r2->prev;
R_DrawSinglePlane(&ds, r2->plane, false);
srb2::ThreadPool::Sema tp_sema;
srb2::g_main_threadpool->begin_sema();
R_DrawSinglePlane(&ds, r2->plane, cv_parallelsoftware.value);
tp_sema = srb2::g_main_threadpool->end_sema();
srb2::g_main_threadpool->notify_sema(tp_sema);
srb2::g_main_threadpool->wait_sema(tp_sema);
R_DoneWithNode(r2);
r2 = next;
}