From b6ed613006398a0962bd09c8bf89e68e5cd2ec7c Mon Sep 17 00:00:00 2001 From: divverent Date: Sun, 22 Aug 2010 15:13:36 +0000 Subject: [PATCH] support more level network eyes, and make them static instead of on-stack. Now 8k of memory are used for warpzones. git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@10411 d7cf8633-e32d-0410-b094-e92efae38249 --- quakedef.h | 4 ++-- sv_main.c | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/quakedef.h b/quakedef.h index d1e50f93..dd06836f 100644 --- a/quakedef.h +++ b/quakedef.h @@ -148,8 +148,8 @@ extern char engineversion[128]; #define MAX_DEMONAME 16 ///< max demo name length for demos command #define MAX_SAVEGAMES 12 ///< max savegames listed in savegame menu #define SAVEGAME_COMMENT_LENGTH 39 ///< max comment length of savegame in menu -#define MAX_CLIENTNETWORKEYES 8 ///< max number of locations that can be added to pvs when culling network entities (must be at least 2 for prediction) -#define MAX_LEVELNETWORKEYES 64 ///< max number of locations that can be added to pvs when culling network entities (must be at least 2 for prediction) +#define MAX_CLIENTNETWORKEYES 16 ///< max number of locations that can be added to pvs when culling network entities (must be at least 2 for prediction) +#define MAX_LEVELNETWORKEYES 512 ///< max number of locations that can be added to pvs when culling network entities (must be at least 2 for prediction) #define MAX_OCCLUSION_QUERIES 4096 ///< max number of GL_ARB_occlusion_query objects that can be used in one frame #define MAX_WATERPLANES 16 ///< max number of water planes visible (each one causes additional view renders) diff --git a/sv_main.c b/sv_main.c index 336676ff..0705b7c1 100644 --- a/sv_main.c +++ b/sv_main.c @@ -1608,9 +1608,9 @@ void SV_AddCameraEyes(void) { int e, i, j, k; prvm_edict_t *ed; - int cameras[MAX_LEVELNETWORKEYES]; - vec3_t camera_origins[MAX_LEVELNETWORKEYES]; - int eye_levels[MAX_CLIENTNETWORKEYES]; + static int cameras[MAX_LEVELNETWORKEYES]; + static vec3_t camera_origins[MAX_LEVELNETWORKEYES]; + static int eye_levels[MAX_CLIENTNETWORKEYES]; int n_cameras = 0; vec3_t mi, ma; prvm_eval_t *valendpos, *val; -- 2.39.2