glTF culling bugfix caused by uninitialized variable

This commit is contained in:
Robert Beckebans 2024-12-18 23:13:47 +01:00
parent 9a9596b812
commit 375039c57c
4 changed files with 4 additions and 3 deletions

View file

@ -509,6 +509,7 @@ void idInteraction::UnlinkAndFree()
{
// clear the table pointer
idRenderWorldLocal* renderWorld = this->lightDef->world;
// RB: added check for NULL
if( renderWorld->interactionTable != NULL )
{

View file

@ -75,7 +75,7 @@ private:
bool fileExclusive;
bool hasAnimations;
float maxJointVertDist; // maximum distance a vertex is separated from a joint
float maxJointVertDist = 10.0f; // maximum distance a vertex is separated from a joint
idList<int, TAG_MODEL> animIds;
idList<int, TAG_MODEL> bones;
idList<int, TAG_MODEL> MeshNodeIds;

View file

@ -1710,7 +1710,7 @@ void idRenderBackend::RenderInteractions( const drawSurf_t* surfList, const view
// are added single-threaded, and there is only a negligable amount
// of benefit to trying to sort by materials.
//---------------------------------
static const int MAX_INTERACTIONS_PER_LIGHT = 1024;
static const int MAX_INTERACTIONS_PER_LIGHT = 2048; // 1024 in BFG
static const int MAX_COMPLEX_INTERACTIONS_PER_LIGHT = 256;
idStaticList< const drawSurf_t*, MAX_INTERACTIONS_PER_LIGHT > allSurfaces;
idStaticList< const drawSurf_t*, MAX_COMPLEX_INTERACTIONS_PER_LIGHT > complexSurfaces;

View file

@ -249,7 +249,7 @@ public:
idBlockAlloc<areaReference_t, 1024> areaReferenceAllocator;
idBlockAlloc<idInteraction, 256> interactionAllocator;
#ifdef ID_PC
#if 1 //def ID_PC
static const int MAX_DECAL_SURFACES = 32;
#else
static const int MAX_DECAL_SURFACES = 16;