- Move polyobj rendering to be handled as a special case in RenderPolyScene

This commit is contained in:
Magnus Norddahl 2017-05-12 17:26:17 +02:00
commit 5c6cbd17a1
3 changed files with 102 additions and 28 deletions

View file

@ -70,26 +70,6 @@ void PolyCull::CullNode(void *node)
void PolyCull::CullSubsector(subsector_t *sub)
{
// Mark poly objects first
if (sub->polys)
{
if (sub->BSP == nullptr || sub->BSP->bDirty)
{
sub->BuildPolyBSP();
}
if (sub->BSP->Nodes.Size() == 0)
{
CullSubsector(&sub->BSP->Subsectors[0]);
}
else
{
CullNode(&sub->BSP->Nodes.Last());
}
return; // Hmm, seems a bit strange the subsector is then ignored. But that's what the sw renderer seems to be doing..
}
// Update sky heights for the scene
if (!FirstSkyHeight)
{