Misc bugfixes, including q3bsp-rtlights and bloom. Matrix use clarifications. Working towards skeletal glsl code.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@3890 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
parent
4dba0e3f28
commit
729d6181c2
70 changed files with 2062 additions and 1311 deletions
|
@ -111,7 +111,7 @@ int SVQ1_RecursiveLightPoint3C (model_t *model, mnode_t *node, vec3_t start, vec
|
|||
tex = surf->texinfo;
|
||||
|
||||
s = DotProduct (mid, tex->vecs[0]) + tex->vecs[0][3];
|
||||
t = DotProduct (mid, tex->vecs[1]) + tex->vecs[1][3];;
|
||||
t = DotProduct (mid, tex->vecs[1]) + tex->vecs[1][3];
|
||||
|
||||
if (s < surf->texturemins[0] ||
|
||||
t < surf->texturemins[1])
|
||||
|
@ -126,23 +126,20 @@ int SVQ1_RecursiveLightPoint3C (model_t *model, mnode_t *node, vec3_t start, vec
|
|||
if (!surf->samples)
|
||||
return 0;
|
||||
|
||||
ds >>= 4;
|
||||
dt >>= 4;
|
||||
|
||||
lightmap = surf->samples;
|
||||
r = 0;
|
||||
if (lightmap)
|
||||
{
|
||||
|
||||
lightmap += (dt * ((surf->extents[0]>>4)+1) + ds)*3;
|
||||
lightmap += (dt * ((surf->extents[0])+1) + ds)*3;
|
||||
|
||||
for (maps = 0 ; maps < MAXLIGHTMAPS && surf->styles[maps] != 255 ;
|
||||
maps++)
|
||||
{
|
||||
scale = sv.strings.lightstyles[surf->styles[maps]][0];
|
||||
r += (lightmap[0]+lightmap[1]+lightmap[2])/3 * scale;
|
||||
lightmap += ((surf->extents[0]>>4)+1) *
|
||||
((surf->extents[1]>>4)+1)*3;
|
||||
lightmap += ((surf->extents[0])+1) *
|
||||
((surf->extents[1])+1)*3;
|
||||
}
|
||||
|
||||
r >>= 8;
|
||||
|
@ -1018,8 +1015,8 @@ void CalcSurfaceExtents (msurface_t *s);
|
|||
bmins[i] = floor(mins[i]/16);
|
||||
bmaxs[i] = ceil(maxs[i]/16);
|
||||
|
||||
s->texturemins[i] = bmins[i] * 16;
|
||||
s->extents[i] = (bmaxs[i] - bmins[i]) * 16;
|
||||
s->texturemins[i] = bmins[i];
|
||||
s->extents[i] = (bmaxs[i] - bmins[i]);
|
||||
// if ( !(tex->flags & TEX_SPECIAL) && s->extents[i] > 256)
|
||||
// SV_Error ("Bad surface extents");
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue