fix portal culling
This commit is contained in:
1 parent
4c815bd3bf
commit
83de4399fd
3 files changed
+3
-8
No files matched your search
@@ -5091,10 +5091,12 @@ void HWR_SetStencilState(int state, int level)
|
||||
// Renders the current viewpoint, though takes portal arguments for recursive portals.
|
||||
void HWR_RenderViewpoint(gl_portal_t *rootportal, const float fpov, player_t *player, int stencil_level, boolean allow_portals)
|
||||
{
|
||||
gl_portallist_t portallist;
|
||||
|
||||
const boolean skybox = (skyboxmo[0] && cv_skybox.value);
|
||||
const boolean useportals = cv_glportals.value && gl_maphasportals && allow_portals;
|
||||
|
||||
HWR_Portal_InitList();
|
||||
portallist.base = portallist.cap = NULL;
|
||||
|
||||
if (useportals && stencil_level < cv_maxportals.value) // if recursion limit is not reached
|
||||
{
|
||||
|
||||
@@ -30,7 +30,6 @@
|
||||
|
||||
SINT8 gl_portal_state = GLPORTAL_OFF;
|
||||
|
||||
gl_portallist_t portallist;
|
||||
gl_portallist_t *currentportallist;
|
||||
|
||||
// Adds an entry to the clipper for portal rendering
|
||||
|
||||
@@ -58,14 +58,8 @@ typedef struct gl_portallist_s
|
||||
extern SINT8 gl_portal_state;
|
||||
|
||||
// new thing
|
||||
extern gl_portallist_t portallist;
|
||||
extern gl_portallist_t *currentportallist;
|
||||
|
||||
static inline void HWR_Portal_InitList (void)
|
||||
{
|
||||
portallist.base = portallist.cap = NULL;
|
||||
}
|
||||
|
||||
static inline void HWR_SetPortalState (SINT8 state)
|
||||
{
|
||||
gl_portal_state = state;
|
||||
|
||||
Reference in new issue
Block a user