lordhavoc [Fri, 1 Mar 2002 12:27:33 +0000 (12:27 +0000)]
reenabled loading plaques (and cleaned up that code a lot)
moved screenshot/envmap code from gl_backend.c to cl_screen.c (except for the GL SCR_ScreenShot function of course)
cleaned up trailing whitespace in console.c
backend between-batch overhead is now pretty much non-existent (set up state at start of frame, keep it until end of 3D rendering)
default batch size is now 0 triangles (never batch)
index array is not offset for first mesh in batch (which might be the only mesh in the batch)
does not lock arrays until it tries to render the first mesh
moved GL_LockArray/GL_UnlockArray from gl_models.c to gl_backend.c
made GL calls in r_sky.c unnecessary (now uses R_Mesh_ClearDepth)
made every enum in GL_PrintError (used by CHECKGLERROR) optional, for consistency (not that any GL headers would lack most of them)
inlined MYgluPerspective
removed a few unnecessary GL calls in frame setup code
reformatted uses of CHECKGLERROR to be on the same line as the function they are checking (looks cleaner)
increased MAX_TEXTUREUNITS from 4 to 8 (not that there is any code trying to use more than 2 textures anyway)
calling R_RenderView with no worldmodel is no longer fatal (just returns)
R_Mesh_Clear renamed to R_Mesh_Start
R_Mesh_Finish added (ends 3D rendering)
cleaned up some cruft in screen.h
moved gldepthmin/max from vid_ files to gl_backend, and then commented it out anyway (not currently used)
lordhavoc [Mon, 25 Feb 2002 12:52:56 +0000 (12:52 +0000)]
cleaned up backend code a bit more, added R_Mesh_Draw_GetBuffer (untested - returns addresses in geometry buffers to fill in, to save memcpy on singlepass objects), rewrote Q2 model loading (now Q2 models are the same as Q1 models after loading), removed Q2 model renderer (and good riddence!), changed aliasvert array from 3 float to 4 float alignment to make copies faster
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)