surfacevisframes[*mark] = r_framecount;
// follow portals into other leafs
for (p = leaf->portals;p;p = p->next)
- if (DotProduct(r_vieworigin, p->plane.normal) < (p->plane.dist + 1) && p->past->visframe != r_framecount && !R_CullBox(p->mins, p->maxs) && CHECKPVSBIT(r_pvsbits, p->past->clusterindex))
+ if (DotProduct(r_vieworigin, p->plane.normal) < (p->plane.dist + 1) && p->past->visframe != r_framecount && CHECKPVSBIT(r_pvsbits, p->past->clusterindex) && !R_CullBox(p->mins, p->maxs))
leafstack[leafstackpos++] = p->past;
}
}
int numsurfaces;
msurface_t *surfaces;
int *surfacevisframes;
- int *surfacepvsframes;
msurface_t *surfacepvsnext;
int numsurfedges;
int numlights;
mlight_t *lights;
- // pvs visibility marking
- mleaf_t *pvsviewleaf;
- int pvsviewleafnovis;
- int pvsframecount;
- mleaf_t *pvsleafchain;
- int *pvssurflist;
- int pvssurflistlength;
- // these get rebuilt as the player moves around if this is the world,
- // otherwise they are left alone (no pvs for bmodels)
- msurface_t ***pvstexturechains;
- msurface_t **pvstexturechainsbuffer;
- int *pvstexturechainslength;
-
// lightmap update chains for light styles
int light_styles;
qbyte *light_style;
msurface_t **light_styleupdatechainsbuffer;
mleaf_t *(*PointInLeaf)(struct model_s *model, const float *p);
- void (*BuildPVSTextureChains)(struct model_s *model);
}
model_brushq1_t;