lordhavoc [Sun, 24 Feb 2002 05:06:26 +0000 (05:06 +0000)]
cleaned up lots of unused code, restructured where certain operations are done (index lists are now relative to mesh->firstvert until R_Mesh_Render, for instance)
working toward major speed gains by avoiding geometry copying
lordhavoc [Tue, 19 Feb 2002 10:56:54 +0000 (10:56 +0000)]
added viewzoom extension to QC and client (smooth sniper zooming, with sensitivity scaling)
protocol should be able to masq now (not a perfect fix like net_chan, but a fix for most people - I hope) - server waits to send serverinfo until first reply from client (any clc_ message will do), client spams clc_nop every 3 seconds until it gets serverinfo (FIXME: maybe only once would do?)
upgraded aiming angles sent from client to floats in DPPROTOCOL_VERSION2 mode
updated cl_shownet 2 svc name list in cl_parse.c (it was quite outdated)
lordhavoc [Fri, 15 Feb 2002 23:50:36 +0000 (23:50 +0000)]
changed bgmvolume/volume to always be registered, sliders for them always work (even with -nosound), but the items are displayed ghosted if -nosound or -nocdaudio is used
changed all Cvar_SetValue calls to Cvar_SetValueQuick
lordhavoc [Fri, 15 Feb 2002 22:28:08 +0000 (22:28 +0000)]
moved a lot of 2D/screen stuff out of gl_screen.c into cl_screen.c
moved remainder of gl_screen.c into gl_backend.c
removed gl_screen.c
inlined GL_BrightenScreen in gl_draw.c
moved a lot of GL stuff out of gl_rmain.c into gl_backend.c
converted polyblend to R_Mesh based
replaced lighthalf/gl_lightmode with v_overbrightbits
renamed contrast to brightness, and brightness to contrast (to match monitor controls)
merged hardware and software brightness/contrast/gamma into v_contrast, v_brightness, v_gamma, etc, switchable using v_hwgamma (automatically forced off if hardware gamma support is unavailable)
added ghostable menu items (unavailable gamma, for example)
rearranged options menu
2D resolution slider added (from 320x240 to full resolution)
fixed misuse of strncmp for bindings menu (thanks Elric)
adjustable crosshair size
renamed GL_BeginRendering to VID_GetWindowSize
renamed GL_EndRendering to VID_Finish
made screenshot and envmap share one function for grabbing images
moved underwater warping into cl_screen code
starting work on new entity protocol (not hooked up yet)
lordhavoc [Tue, 5 Feb 2002 03:08:32 +0000 (03:08 +0000)]
cleaned up entity culling in server code, implemented new option - sv_cullentities_trace - traces a line from eye to random locations in the model box, if a trace succeeds it marks the entity visibility timeout for 1 second in the future, and if it fails and the timeout has expired by then, it culls the entity. this method works great for most cases, and is far more aggressive (and faster) than pvs culling
lordhavoc [Sun, 3 Feb 2002 10:40:46 +0000 (10:40 +0000)]
rearranged r_speeds report a bit, and split up reporting of meshtris into normal and transparent categories, also displays number of meshs of each type
made byte color array format work (byte format is very slightly faster than float)
disabled float color array format to save some memory
added gl_mesh_sorttransbymesh cvar (default: on) to get a performance gain in mingled mesh conditions (by never mingling triangles of different meshs), this mode can batch render transparent triangles too (unlike the other two modes)
increased default maxtriangles to 8192
lordhavoc [Fri, 1 Feb 2002 11:40:21 +0000 (11:40 +0000)]
added gib shower effect, they leave no trails but make blood marks where they hit... (note: this is still highly experimental and cgame might be removed at some point, and no mods use this anyway)
lordhavoc [Thu, 31 Jan 2002 16:41:59 +0000 (16:41 +0000)]
got rid of buildnumber.c and buildnum program, now uses builddate.c (touched each time it is built to keep the date changing)
clientside TraceLine can now hit brush model entities (TraceLine_ScanForBModels updates list of entities to check)
added *highly experimental* clientside gamecode (currently embedded in the engine, just trying things out) which currently doesn't do anything really
made CL_RelinkEntities only called when the client is connected and there is a world model
added fractalnoisequick (variant of fractalnoise that does not allocate/free a temporary buffer, and to achieve this does not use the range remapping)
added stainmap effects (stained lightmaps), which will probably soon replace decals
spark showers now pay attention to the velocity in the TE_SPARKSHOWER packet (if the mod uses this), bullet impacts still have no velocity
added TE_PLASMABURN (combination of TE_SMALLFLASH and a stain on the walls)
added svc_cgame (DO NOT USE THIS, EXPERIMENTAL, but so is the cgame code itself)
Cmd_TokenizeString now uses a fixed size buffer instead of many little allocations (speedup by not having Z_Malloc/Z_Free happening constantly)
cvar code tries very hard to avoid reallocating string now
va() function now uses a cycling set of 8 string buffers to try to avoid conflicts
console logging no longer uses va()
reduced default mesh buffer size from 21760 triangles to 4096 (transparent triangles are costly enough it's not a good idea to exceed this anyway)
texture management code now uses 3 memory pools to give better memory reports according to type of data
R_UpdateTexture has better memory behavior on non-procedural textures now (replaces inputtexels if it has not been uploaded yet, otherwise just uploads it directly)
added -developer commandline option (which is rather hacky) to force developer on for entire startup process, to get logging before the configs are read
decals stick to brush model entities now
stains stick to embedded bmodels (ones that are part of the map, not ones instanced from outside like ammo boxes)
skingroups above 0 are not automatically precached now (if you have a lot of mods installed in your id1 directory, they tend to not use all the skins, which is wasteful)
starting a new game (from the singleplayer menu) forces deathmatch and coop to 0 now
lightmaps are precached again (can't remember why I ever disabled this)
changed VectorSet's parameter order to be more consistent with other vector ops
removed a duplicate registration of the vid_mouse cvar (in vid_glx.c)
lordhavoc [Fri, 25 Jan 2002 00:45:55 +0000 (00:45 +0000)]
added cl_screen.c/h (eventually most 2D stuff should be moved here)
removed view.h (merged into client.h)
cleaned up the animation interpolation code (CL_LerpUpdate) a bit more
increased interpolation 'teleport' tolerance from 400 units to 1000 units per frame
changed calls to Mod_ForName to not use checkdisk (except for viewthing model changes and map changes)
added viewent to r_refdef
moved v_blend to r_refdef
all 2D art now goes through Draw_CachePic
cachepic replaced qpic (in all non-wad code)
moved all engine generated pics (mousepointer, crosshairs) to gl_draw.c (they are called by Draw_CachePic)
cachepic now uses a hash lookup instead of just a string search
added drawqueue to r_refdef
all 2D art now goes through DrawQ_ functions (drawqueue)
DrawQ_String now stretchs the character texture a tiny bit, and always uses default filtering
cleaned out some old cruft in console drawing code
fixed some silly bugs in showfps
made showfps display use only 4 characters, and made the text larger, and moved it down a little
moved showfps from gl_screen.c to sbar.c
moved Draw_ConsoleBackground to console.c
removed drawinput parameter from Con_DrawConsole (it was always true)
c_alias_polys now counts all meshs rendered (a model may be rendered multiple times), not just the total number of triangles in the model, much more accurate
r_speeds2 renamed to r_speeds
disabled all Mem_CheckSentinelsGlobal calls during gameplay (they were wasting time)
r_speeds now displays time spent throughout SCR_UpdateScreen code, not just R_RenderView
frame is now rendered in 'finish begin render' order instead of 'begin render finish' order in SCR_Updatescreen - not sure if this is a speedup or not
BLOCK_SIZE in gl_textures.c renamed to block_size and now adjustable (r_max_scrapsize cvar), r_restart for changes to take effect, 1024 (default) or less recommended
menu, r_speeds, and showfps now have a darkened (50% black) background beneath them to improve readability
menu is now centered on the screen
menu text is now white
translatepic code now updates texture rather than constantly cache mismatching
cleaned up cshift code
cleaned up viewent setup code
W_GetLumpinfo failing to find a lump is no longer fatal
added R_Mesh_DrawDecal for the highly specialized task of adding decals/particles/sprites to the mesh system (trying to get a minor speed gain)
decals, particles, and sprites now use R_Mesh_DrawDecal
lordhavoc [Sat, 19 Jan 2002 21:36:53 +0000 (21:36 +0000)]
rearranged error checking during portal building so it will only Host_Error when an error occurs, and changed tempmempool allocations for portal processing to use the loadmodel mempool so portals can be freed after an error (using modelflush)
lordhavoc [Fri, 18 Jan 2002 20:33:38 +0000 (20:33 +0000)]
cleaned up a lot of particle rendering properties (mainly related to rain code), rain looks nice now.
added depthdisable to rmeshinfo_t
gl_backend now uses glDrawRangeElements on non-win32 (need to use dynamic GL binding to get it on win32), nice speedup
rearranged r_speeds2 time reporting code, now times more things (in gl_screen.c especially)
lordhavoc [Thu, 17 Jan 2002 01:09:28 +0000 (01:09 +0000)]
removed (experimental, and broken) particles with polygonal explosion (after some testing I found it looked lousy)
fixed particles disappearing when using slowmo 0