move line polyseg check out of the lööp if theres no polyobjs on le map

seems to reduce a hotspot there significantly
This commit is contained in:
Alug committed 2025-04-12 19:42:35 +02:00
1 parent fa757c6695
commit b4416c32ed
1 file changed
+14 -3
+14 -3
View File
@@ -3143,11 +3143,22 @@ doaddline:
// without talking about the overdraw of course.
sub->sector->validcount = validcount;/// \todo fix that in a better way
while (count--)
if (numPolyObjects)
{
if (LIKELY(!line->polyseg)) // ignore segs that belong to polyobjects
while (count--)
{
if (LIKELY(!line->polyseg)) // ignore segs that belong to polyobjects
HWR_AddLine(line);
line++;
}
}
else
{
while (count--)
{
HWR_AddLine(line);
line++;
line++;
}
}
}