1
0
Fork 0
forked from fte/fteqw

fix some rtlight issues on q2bsp. this has a sideeffect of about trippling framerates, as well as enabling shadows and stopping glitches... a win all round... yay.

git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4551 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
Spoike 2013-12-01 10:54:16 +00:00
parent e000c2db3b
commit 409c17b9fc

View file

@ -803,7 +803,9 @@ static void SHM_RecursiveWorldNodeQ2_r (dlight_t *dl, mnode_t *node)
if (node->contents != -1)
{
pleaf = (mleaf_t *)node;
SHM_Shadow_Cache_Leaf(pleaf);
if (pleaf->cluster >= 0)
sh_shmesh->litleaves[pleaf->cluster>>3] |= 1<<(pleaf->cluster&7);
mark = pleaf->firstmarksurface;
c = pleaf->nummarksurfaces;
@ -901,6 +903,11 @@ static void SHM_RecursiveWorldNodeQ2_r (dlight_t *dl, mnode_t *node)
if ((s*s+t*t+dot*dot) < maxdist)
{
SHM_Shadow_Cache_Surface(surf);
if (sh_shmesh->type == SMT_SHADOWMAP)
{
SHM_MeshFrontOnly(surf->mesh->numvertexes, surf->mesh->xyz_array, surf->mesh->numindexes, surf->mesh->indexes);
continue;
}
if (sh_shmesh->type != SMT_STENCILVOLUME)
continue;