summaryrefslogtreecommitdiffstats
path: root/src/render
diff options
context:
space:
mode:
authorSergeanur <s.anureev@yandex.ua>2020-05-05 17:33:32 +0200
committerSergeanur <s.anureev@yandex.ua>2020-05-05 17:33:32 +0200
commit12fbf8ceded75438d1c5ac532f83319405fbb02d (patch)
tree2062de5cd1582676c62ed4f8673eaa5d7ba8a2e4 /src/render
parentMerge pull request #514 from Nick007J/miami (diff)
parentRemove GTA_TRAIN, GTA_BRIDGE, GTA_ZONECULL (diff)
downloadre3-12fbf8ceded75438d1c5ac532f83319405fbb02d.tar
re3-12fbf8ceded75438d1c5ac532f83319405fbb02d.tar.gz
re3-12fbf8ceded75438d1c5ac532f83319405fbb02d.tar.bz2
re3-12fbf8ceded75438d1c5ac532f83319405fbb02d.tar.lz
re3-12fbf8ceded75438d1c5ac532f83319405fbb02d.tar.xz
re3-12fbf8ceded75438d1c5ac532f83319405fbb02d.tar.zst
re3-12fbf8ceded75438d1c5ac532f83319405fbb02d.zip
Diffstat (limited to 'src/render')
-rw-r--r--src/render/Renderer.cpp12
-rw-r--r--src/render/Renderer.h2
2 files changed, 0 insertions, 14 deletions
diff --git a/src/render/Renderer.cpp b/src/render/Renderer.cpp
index 03bc175a..982c61cd 100644
--- a/src/render/Renderer.cpp
+++ b/src/render/Renderer.cpp
@@ -1263,9 +1263,7 @@ CRenderer::ScanSectorList(CPtrList *lists)
continue; // already seen
ent->m_scanCode = CWorld::GetCurrentScanCode();
-#ifdef GTA_ZONECULL
if(IsEntityCullZoneVisible(ent))
-#endif
switch(SetupEntityVisibility(ent)){
case VIS_VISIBLE:
ms_aVisibleEntityPtrs[ms_nNoOfVisibleEntities++] = ent;
@@ -1288,14 +1286,12 @@ CRenderer::ScanSectorList(CPtrList *lists)
CStreaming::RequestModel(ent->GetModelIndex(), 0);
break;
}
-#ifdef GTA_ZONECULL
else if(ent->IsBuilding() && ((CBuilding*)ent)->GetIsATreadable()){
if(!CStreaming::ms_disableStreaming)
if(SetupEntityVisibility(ent) == VIS_STREAMME)
if(!m_loadingPriority || CStreaming::ms_numModelsRequested < 10)
CStreaming::RequestModel(ent->GetModelIndex(), 0);
}
-#endif
}
}
}
@@ -1317,9 +1313,7 @@ CRenderer::ScanSectorList_Priority(CPtrList *lists)
continue; // already seen
ent->m_scanCode = CWorld::GetCurrentScanCode();
-#ifdef GTA_ZONECULL
if(IsEntityCullZoneVisible(ent))
-#endif
switch(SetupEntityVisibility(ent)){
case VIS_VISIBLE:
ms_aVisibleEntityPtrs[ms_nNoOfVisibleEntities++] = ent;
@@ -1344,13 +1338,11 @@ CRenderer::ScanSectorList_Priority(CPtrList *lists)
}
break;
}
-#ifdef GTA_ZONECULL
else if(ent->IsBuilding() && ((CBuilding*)ent)->GetIsATreadable()){
if(!CStreaming::ms_disableStreaming)
if(SetupEntityVisibility(ent) == VIS_STREAMME)
CStreaming::RequestModel(ent->GetModelIndex(), 0);
}
-#endif
}
}
}
@@ -1403,9 +1395,7 @@ CRenderer::ScanSectorList_RequestModels(CPtrList *lists)
if(ent->m_scanCode == CWorld::GetCurrentScanCode())
continue; // already seen
ent->m_scanCode = CWorld::GetCurrentScanCode();
-#ifdef GTA_ZONECULL
if(IsEntityCullZoneVisible(ent))
-#endif
if(ShouldModelBeStreamed(ent))
CStreaming::RequestModel(ent->GetModelIndex(), 0);
}
@@ -1451,7 +1441,6 @@ CRenderer::ShouldModelBeStreamed(CEntity *ent)
return dist - FADE_DISTANCE - STREAM_DISTANCE < mi->GetLargestLodDistance();
}
-#ifdef GTA_ZONECULL
bool
CRenderer::IsEntityCullZoneVisible(CEntity *ent)
{
@@ -1494,7 +1483,6 @@ CRenderer::IsVehicleCullZoneVisible(CEntity *ent)
return !(v->m_pCurGroundEntity && v->m_pCurGroundEntity->bZoneCulled2);
return true;
}
-#endif
void
CRenderer::RemoveVehiclePedLights(CEntity *ent, bool reset)
diff --git a/src/render/Renderer.h b/src/render/Renderer.h
index e28995c3..362741e3 100644
--- a/src/render/Renderer.h
+++ b/src/render/Renderer.h
@@ -64,10 +64,8 @@ public:
static void SortBIGBuildingsForSectorList(CPtrList *list);
static bool ShouldModelBeStreamed(CEntity *ent);
-#ifdef GTA_ZONECULL
static bool IsEntityCullZoneVisible(CEntity *ent);
static bool IsVehicleCullZoneVisible(CEntity *ent);
-#endif
static void RemoveVehiclePedLights(CEntity *ent, bool reset);
};