15 years agorewrote much of the voodoo/tnt rtlight path, now supports fog, and now avoids renderi...
havoc [Sat, 29 Oct 2005 10:59:10 +0000 (10:59 +0000)]
rewrote much of the voodoo/tnt rtlight path, now supports fog, and now avoids rendering any black triangles (since these cards don't have a lot of fillrate it's better to cull triangles on the cpu)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5781 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoconverted vertex fogging to use a fogtable array which matches the fog texture
havoc [Sat, 29 Oct 2005 06:51:14 +0000 (06:51 +0000)]
converted vertex fogging to use a fogtable array which matches the fog texture
enabled fog texturing on GLSL lighting path (dot3 path and vertex path still need work)
changed EyeVector/LightVector in GLSL shader back to full fp32 precision because at fp16 the vectors were reaching infinity at only a few meters, which obviously broke fogging

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5780 d7cf8633-e32d-0410-b094-e92efae38249

15 years agomerged two sprite functions into the main callback to slightly clean up the code...
havoc [Sat, 29 Oct 2005 00:58:15 +0000 (00:58 +0000)]
merged two sprite functions into the main callback to slightly clean up the code and simplify it

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5779 d7cf8633-e32d-0410-b094-e92efae38249

15 years agomigrated r_lerpsprites cvar check to r_lerpanim, r_lerpmodels no longer affects sprites
havoc [Sat, 29 Oct 2005 00:39:53 +0000 (00:39 +0000)]
migrated r_lerpsprites cvar check to r_lerpanim, r_lerpmodels no longer affects sprites

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5778 d7cf8633-e32d-0410-b094-e92efae38249

15 years agotweaked GLSL lighting shader to get a bit more performance (at least 7%) on GF6 by...
havoc [Fri, 28 Oct 2005 05:44:11 +0000 (05:44 +0000)]
tweaked GLSL lighting shader to get a bit more performance (at least 7%) on GF6 by making all variables half precision except TexCoord, hopefully also helps GFFX

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5777 d7cf8633-e32d-0410-b094-e92efae38249

15 years agothe beginnings of texture fog support (to cure the vertex artifacts and simplify...
havoc [Thu, 27 Oct 2005 06:41:42 +0000 (06:41 +0000)]
the beginnings of texture fog support (to cure the vertex artifacts and simplify the renderer a bit)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5776 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoremove a debugging message related to ammo > 200 in zymotic hud
havoc [Thu, 27 Oct 2005 05:55:59 +0000 (05:55 +0000)]
remove a debugging message related to ammo > 200 in zymotic hud

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5775 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix free/malloc problems from a partial switch to Z_Free and Z_Malloc, the switch...
havoc [Wed, 26 Oct 2005 22:23:41 +0000 (22:23 +0000)]
fix free/malloc problems from a partial switch to Z_Free and Z_Malloc, the switch over is now complete

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5774 d7cf8633-e32d-0410-b094-e92efae38249

15 years agonew zymotic hud
havoc [Wed, 26 Oct 2005 10:57:05 +0000 (10:57 +0000)]
new zymotic hud

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5773 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoreplaced CL_PointQ1Contents with longer calls to contents conversion and CL_PointSupe...
havoc [Wed, 26 Oct 2005 10:13:00 +0000 (10:13 +0000)]
replaced CL_PointQ1Contents with longer calls to contents conversion and CL_PointSuperContents
changed CL_PointSuperContents to a #define calling SV_Move directly as an optimization

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5772 d7cf8633-e32d-0410-b094-e92efae38249

15 years agosplit SV_Physics_Entity into SV_Physics_Entity and SV_Physics_ClientEntity as an...
havoc [Wed, 26 Oct 2005 10:11:47 +0000 (10:11 +0000)]
split SV_Physics_Entity into SV_Physics_Entity and SV_Physics_ClientEntity as an optimization

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5771 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix stupid bug introduced by merging CL_DecayLights into CL_UpdateLights, fixed by...
havoc [Wed, 26 Oct 2005 10:09:28 +0000 (10:09 +0000)]
fix stupid bug introduced by merging CL_DecayLights into CL_UpdateLights, fixed by splitting them again, now glowing entities should work again

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5770 d7cf8633-e32d-0410-b094-e92efae38249

15 years agooptimized SV_WriteClientdataToMessage by caching weaponmodelindex in client structure...
havoc [Wed, 26 Oct 2005 02:09:48 +0000 (02:09 +0000)]
optimized SV_WriteClientdataToMessage by caching weaponmodelindex in client structure, saving 1% cpu time in masque.bsp

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5769 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoreverted bsp recursion changes (back to the BoxOnPlaneSide method) because the skippi...
havoc [Wed, 26 Oct 2005 02:02:49 +0000 (02:02 +0000)]
reverted bsp recursion changes (back to the BoxOnPlaneSide method) because the skipping of solid leafs in node bounding box generation was completely breaking q3bsp collisions, and without the reduced node boxes the bsp recursion code runs horribly slow for unknown reasons

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5768 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoupdated IP address comment for Willis's dpmaster.deathmask.net master server
havoc [Tue, 25 Oct 2005 04:29:39 +0000 (04:29 +0000)]
updated IP address comment for Willis's dpdeathmask.net master server

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5767 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix a use of cs.specialvisibilityradius before it was initialized (thanks to gcc...
havoc [Mon, 24 Oct 2005 05:55:21 +0000 (05:55 +0000)]
fix a use of cs.specialvisibilityradius before it was initialized (thanks to gcc 4 for pointing out this bug)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5766 d7cf8633-e32d-0410-b094-e92efae38249

15 years agomoved d_lightstylevalue into r_refdef.lightstyle
havoc [Mon, 24 Oct 2005 04:42:22 +0000 (04:42 +0000)]
moved d_lightstylevalue into r_refdef.lightstyle
moved r_dlights into r_redef.lights and made it an array of pointers into cl_dlights to save memory and time
merged R_UpdateLights into CL_DecayLights and renamed it CL_UpdateLights
renamed R_RTLight_UpdateFromDLight to R_RTLight_Update and made it take only the dlight pointer
implemented cl_activedlights variable to prevent scanning whole MAX_DLIGHTS range every frame

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5765 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofixed a flaw in Mod_Q1BSP_RecursiveRecalcNodeBBox, it was merging bounding boxes...
havoc [Mon, 24 Oct 2005 04:28:49 +0000 (04:28 +0000)]
fixed a flaw in Mod_Q1BSP_RecursiveRecalcNodeBBox, it was merging bounding boxes even if they came from solid leafs, which meant that the solid hull around the world was making almost all nodes have a bounding box of +-1 billion units, negating any benefit at all to node bounding boxes
10% speed gain in masque.bsp by changing pvs box checking functions to use box tests when recursing the bsp tree instead of BoxOnPlaneSide (now that the node boxes are usable)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5764 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoslightly optimized Mod_ForName to make less calls to Mod_LoadModel
havoc [Mon, 24 Oct 2005 04:22:16 +0000 (04:22 +0000)]
slightly optimized Mod_ForName to make less calls to Mod_LoadModel

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5763 d7cf8633-e32d-0410-b094-e92efae38249

15 years agomade an optimized SV_ClipMoveToWorld function to save time on large numbers of world...
havoc [Mon, 24 Oct 2005 04:19:23 +0000 (04:19 +0000)]
made an optimized SV_ClipMoveToWorld function to save time on large numbers of world collisions

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5762 d7cf8633-e32d-0410-b094-e92efae38249

15 years ago#ifdef 0'd out BoxOnPlaneSide_Separate as it is not used
havoc [Mon, 24 Oct 2005 04:17:09 +0000 (04:17 +0000)]
#ifdef 0'd out BoxOnPlaneSide_Separate as it is not used

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5761 d7cf8633-e32d-0410-b094-e92efae38249

15 years agodon't send empty lightstyles during signon
havoc [Sun, 23 Oct 2005 23:13:11 +0000 (23:13 +0000)]
don't send empty lightstyles during signon

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5760 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofixed a bug that was making "Model %s not found" warnings never appear when parsing...
havoc [Sun, 23 Oct 2005 20:24:03 +0000 (20:24 +0000)]
fixed a bug that was making "Model %s not found" warnings never appear when parsing the model precache list

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5759 d7cf8633-e32d-0410-b094-e92efae38249

15 years agogot rid of Mod_CheckLoaded, changed how model system restart works to make this work...
havoc [Sun, 23 Oct 2005 20:02:31 +0000 (20:02 +0000)]
got rid of Mod_CheckLoaded, changed how model system restart works to make this work properly
disabled model purging on level change, now only the world model is unloaded, this should improve slightly load times from level to level if a model is used in an early level, then not used in the next, and then used again in the next after that, however it also increases memory usage

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5758 d7cf8633-e32d-0410-b094-e92efae38249

15 years agochanged network entity pvs checking to cache the cluster list (updated whenever the...
havoc [Sun, 23 Oct 2005 19:42:34 +0000 (19:42 +0000)]
changed network entity pvs checking to cache the cluster list (updated whenever the cull box changes), this got a 20% speed gain in masque.bsp, also rewrote much of the network entity handling code for another 1% speed gain and slight readability improvement

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5757 d7cf8633-e32d-0410-b094-e92efae38249

15 years agorewrote r_speeds stats code, now uses renderstats global structure rather than indivi...
havoc [Sun, 23 Oct 2005 06:36:05 +0000 (06:36 +0000)]
rewrote r_speeds stats code, now uses renderstats global structure rather than individual c_ global variables, this makes maintenance a lot easier, additionally changed all the stats to be more representitive of how the engine actually works (counting entities instead of models/bmodels/sprites separately, among other changes), condensed r_speeds stats display to fewer lines

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5756 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix another g++ conversion error
havoc [Fri, 21 Oct 2005 06:35:08 +0000 (06:35 +0000)]
fix another g++ conversion error

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5754 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoadded explicit casts for agl functions when calling GL_GetProcAddress
havoc [Fri, 21 Oct 2005 06:32:19 +0000 (06:32 +0000)]
added explicit casts for agl functions when calling GL_GetProcAddress

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5753 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix another float->enum conversion error with g++ 4
havoc [Fri, 21 Oct 2005 06:15:55 +0000 (06:15 +0000)]
fix another float->enum conversion error with g++ 4

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5752 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofixed two Con_Printf format strings with the wrong type
havoc [Fri, 21 Oct 2005 06:15:25 +0000 (06:15 +0000)]
fixed two Con_Printf format strings with the wrong type

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5751 d7cf8633-e32d-0410-b094-e92efae38249

15 years agogave names to nearly all structs and enums which should make for better C++ error...
havoc [Fri, 21 Oct 2005 06:08:25 +0000 (06:08 +0000)]
gave names to nearly all structs and enums which should make for better C++ error messages, and fix any more of those anonymous struct errors

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5750 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix an anonymous struct error with g++ 4
havoc [Fri, 21 Oct 2005 05:30:33 +0000 (05:30 +0000)]
fix an anonymous struct error with g++ 4

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5749 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix a float->enum conversion error with g++ 4
havoc [Fri, 21 Oct 2005 05:28:59 +0000 (05:28 +0000)]
fix a float->enum conversion error with g++ 4

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5748 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix a float->enum conversion error with g++ on big endian systems
havoc [Fri, 21 Oct 2005 05:26:35 +0000 (05:26 +0000)]
fix a float->enum conversion error with g++ on big endian systems

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5747 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix an int->enum conversion error with g++ on big endian systems
havoc [Fri, 21 Oct 2005 05:23:37 +0000 (05:23 +0000)]
fix an int->enum conversion error with g++ on big endian systems

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5746 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoadded struct name to imageformats to cure an error in g++ 4
havoc [Fri, 21 Oct 2005 05:15:15 +0000 (05:15 +0000)]
added struct name to imageformats to cure an error in g++ 4

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5745 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoadded a struct name to envmapinfo to stop a g++ 4 error about envmapinfo (which is...
havoc [Fri, 21 Oct 2005 05:11:58 +0000 (05:11 +0000)]
added a struct name to envmapinfo to stop a g++ 4 error about envmapinfo (which is a global) using an anonymous type (a struct with no name)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5744 d7cf8633-e32d-0410-b094-e92efae38249

15 years agomade darkplaces compile successfully with g++ to test for errors C doesn't care about...
havoc [Fri, 21 Oct 2005 05:05:49 +0000 (05:05 +0000)]
made darkplaces compile successfully with g++ to test for errors C doesn't care about (result: found no actual bugs, just C++ compilers being ultra fussy)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5743 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix one more signedness warning
havoc [Thu, 20 Oct 2005 22:22:24 +0000 (22:22 +0000)]
fix one more signedness warning

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5742 d7cf8633-e32d-0410-b094-e92efae38249

15 years agogcc 4.0 signedness warning fixes and uninitialized vector fixes
havoc [Thu, 20 Oct 2005 22:14:19 +0000 (22:14 +0000)]
gcc 4.0 signedness warning fixes and uninitialized vector fixes

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5741 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoadded very preliminary zymotic hud
havoc [Mon, 17 Oct 2005 22:51:42 +0000 (22:51 +0000)]
added very preliminary zymotic hud

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5740 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix typo
havoc [Sat, 15 Oct 2005 15:36:36 +0000 (15:36 +0000)]
fix typo

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5739 d7cf8633-e32d-0410-b094-e92efae38249

15 years agodon't try to compile GL_NV_half_float shaders if the extension is missing
havoc [Sat, 15 Oct 2005 15:21:02 +0000 (15:21 +0000)]
don't try to compile GL_NV_half_float shaders if the extension is missing

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5738 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoremoved Lights Per Model setting from effects options menu, as it only affects .light...
havoc [Fri, 14 Oct 2005 07:36:45 +0000 (07:36 +0000)]
removed Lights Per Model setting from effects options menu, as it only affects .lights files now that vertex dlights are gone...  leading to much confusion among users

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5737 d7cf8633-e32d-0410-b094-e92efae38249

15 years agowork around for empty key/value pairs in nehahra neh1m8.bsp entities
havoc [Thu, 13 Oct 2005 12:03:05 +0000 (12:03 +0000)]
work around for empty key/value pairs in nehahra neh1m8.bsp entities

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5736 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix a stupid bug with the runes display on the hud (it was detecting rogue/hipnotic...
havoc [Tue, 11 Oct 2005 10:06:10 +0000 (10:06 +0000)]
fix a stupid bug with the runes display on the hud (it was detecting rogue/hipnotic hud's by the existence of the items2 field, which due to the DP progs loader always exists)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5735 d7cf8633-e32d-0410-b094-e92efae38249

15 years agochanged the unused line/sphere collision code to use Vector macros instead of doing...
havoc [Tue, 11 Oct 2005 09:58:50 +0000 (09:58 +0000)]
changed the unused line/sphere collision code to use Vector macros instead of doing everything manually (possibly improving readability)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5734 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoupdated a comment about the nehahra pmodel command/field
havoc [Tue, 11 Oct 2005 09:57:44 +0000 (09:57 +0000)]
updated a comment about the nehahra pmodel command/field

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5733 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix a stupid bug in line/sphere collision code (was using sqrt where it shouldn't)
havoc [Fri, 7 Oct 2005 12:56:54 +0000 (12:56 +0000)]
fix a stupid bug in line/sphere collision code (was using sqrt where it shouldn't)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5731 d7cf8633-e32d-0410-b094-e92efae38249

15 years agook this did not cause memory corruption because of another bug which wasted an equivi...
havoc [Thu, 6 Oct 2005 14:12:00 +0000 (14:12 +0000)]
ok this did not cause memory corruption because of another bug which wasted an equivilant amount of memory...

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5730 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix a very stupid bug in Mod_AllocSurfMesh that causes memory corruption
havoc [Thu, 6 Oct 2005 14:11:06 +0000 (14:11 +0000)]
fix a very stupid bug in Mod_AllocSurfMesh that causes memory corruption

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5729 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix recursive error (and sometimes segfault) when a Host_Error occurs during progs...
havoc [Sat, 24 Sep 2005 09:24:25 +0000 (09:24 +0000)]
fix recursive error (and sometimes segfault) when a Host_Error occurs during progs loading (such as with a corrupt progs.dat)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5727 d7cf8633-e32d-0410-b094-e92efae38249

15 years agomake glsl work on ATI's newer drivers (which don't like #define on keywords)
havoc [Fri, 23 Sep 2005 06:04:17 +0000 (06:04 +0000)]
make glsl work on ATI's newer drivers (which don't like #define on keywords)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5726 d7cf8633-e32d-0410-b094-e92efae38249

15 years ago- SFXs no longer allocate mempools, they use the sound mempool directly.
molivier [Sun, 18 Sep 2005 16:43:45 +0000 (16:43 +0000)]
- SFXs no longer allocate mempools, they use the sound mempool directly.
It saved 21KB and 129 mempools (from 191 to 62) in my quick test.
- removed unused function S_UnloadSound
- changed an endian test in the Ogg Vorbis code to look more coherent

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5725 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoMade Mem_PrintStats also print the real allocated size (including structures used...
molivier [Sun, 18 Sep 2005 16:36:14 +0000 (16:36 +0000)]
Made Mem_PrintStats also print the real allocated size (including structures used by the memory system)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5724 d7cf8633-e32d-0410-b094-e92efae38249

15 years agomoved scr_screenshot_name declaration from cl_screen.c to fs.c because fs.c depends...
havoc [Tue, 13 Sep 2005 01:33:51 +0000 (01:33 +0000)]
moved scr_screenshot_name declaration from cl_screen.c to fs.c because fs.c depends on it and creates it

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5723 d7cf8633-e32d-0410-b094-e92efae38249

15 years agochanged R_TimeReport to call glFinish to improve the accuracy of the reports on each...
havoc [Sun, 11 Sep 2005 12:58:07 +0000 (12:58 +0000)]
changed R_TimeReport to call glFinish to improve the accuracy of the reports on each subsystem (not allowing deferred rendering - yes this knocks your framerate down a lot)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5722 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix a crash on vertex lighting q1bsp/hlbsp surfaces with no lightmap samples data
havoc [Sun, 11 Sep 2005 12:02:02 +0000 (12:02 +0000)]
fix a crash on vertex lighting q1bsp/hlbsp surfaces with no lightmap samples data

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5721 d7cf8633-e32d-0410-b094-e92efae38249

15 years agorewrote colormapping handling to store colormap_pantscolor and colormap_shirtcolor...
havoc [Sun, 11 Sep 2005 11:48:17 +0000 (11:48 +0000)]
rewrote colormapping handling to store colormap_pantscolor and colormap_shirtcolor in entity_render_t rather than having the annoying palette lookups in the renderer, while doing this I removed support for fullbright rendering of colormap colors 14 and 15 (this shouldn't really affect anyone, stock quake did not even let you use these colors, and they're ugly colors anyway :)
rewrote portions of surface renderer again, to improve readability and overbright handling, this shouldn't change anything visually

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5720 d7cf8633-e32d-0410-b094-e92efae38249

15 years agouse a better check for bmodels when clearing stainmaps which won't happen on old...
havoc [Sun, 11 Sep 2005 11:38:38 +0000 (11:38 +0000)]
use a better check for bmodels when clearing stainmaps which won't happen on old submodels (which might not be unloaded yet when this function is called)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5719 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix Sajt's bug in q1bsp/hlbsp hullsizes (off by one on the hull index)
havoc [Sun, 11 Sep 2005 10:39:45 +0000 (10:39 +0000)]
fix Sajt's bug in q1bsp/hlbsp hullsizes (off by one on the hull index)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5718 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix a stupid typo in the vertex shader
havoc [Sun, 11 Sep 2005 08:33:52 +0000 (08:33 +0000)]
fix a stupid typo in the vertex shader

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5717 d7cf8633-e32d-0410-b094-e92efae38249

15 years ago- Updated Zlib definitions to version 1.2.3. The only difference is that
molivier [Sun, 11 Sep 2005 07:30:26 +0000 (07:30 +0000)]
- Updated Zlib definitions to version 1.2.3. The only difference is that
the function calling convention has changed on Win32 (previously, the
zlib DLL used WINAPI). YOU NOW NEED AN OFFICIAL "zlib1.dll" version
1.2.x instead of your old "zlib.dll" (get it from http://www.zlib.net/).
If you still want to use a DLL with the old calling convention,
uncomment line 101 and recompile (such a DLL can be found at
- Removed QuakeForge copyright since the last bit of QF
code was removed months ago by LordHavoc
- Changed the way we test the presence of the O_NONBLOCK flag

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5716 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoAfter the swarm of angry mail I received from owners of manufacturerly-diverse proces...
sajt [Sat, 10 Sep 2005 22:00:21 +0000 (22:00 +0000)]
After the swarm of angry mail I received from owners of manufacturerly-diverse processors, I finally gave in.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5714 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoRemoved the evil evil prototype
sajt [Sat, 10 Sep 2005 21:38:50 +0000 (21:38 +0000)]
Removed the evil evil prototype

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5713 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoremoved a lot of texture_t fields that were used by the old renderer
havoc [Sat, 10 Sep 2005 12:12:34 +0000 (12:12 +0000)]
removed a lot of texture_t fields that were used by the old renderer

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5711 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoremoved old surface renderer
havoc [Sat, 10 Sep 2005 11:33:11 +0000 (11:33 +0000)]
removed old surface renderer

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5710 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoThe MCBSP header has been fixed but it will still crash your NASA lunar module landin...
sajt [Sat, 10 Sep 2005 10:30:05 +0000 (10:30 +0000)]
The MCBSP header has been fixed but it will still crash your NASA lunar module landing mainframe

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5709 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoRename dhullinfo_t to hullinfo_t, fix byte->qbyte. More fixes later! Don't complain...
sajt [Sat, 10 Sep 2005 10:07:25 +0000 (10:07 +0000)]
Rename dhullinfo_t to hullinfo_t, fix byte->qbyte. More fixes later! Don't complain if this crashes your Sun supercomputer!

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5707 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoMCBSP version 2 loading in the engine.. Some very ugly code (will be rewritten)....
sajt [Sat, 10 Sep 2005 06:49:57 +0000 (06:49 +0000)]
MCBSP version 2 loading in the engine.. Some very ugly code (will be rewritten). Also, I haven't thought of how bboxes will round to hull sizes yet, so don't even bother trying to use the format yet. Also, someone might want to add a dhullinfo_t instance in the model struct or something, so the rounding functions would be able to access the hull sizes. I'm not sure how that will all work yet.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5706 d7cf8633-e32d-0410-b094-e92efae38249

15 years agonew surface renderer, builds a layer list in R_UpdateTextureInfo, currently requires...
havoc [Fri, 9 Sep 2005 13:57:56 +0000 (13:57 +0000)]
new surface renderer, builds a layer list in R_UpdateTextureInfo, currently requires r_test to be 1 to use it, will be removing old surface renderer (still available) soon

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5702 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix a bug that made the world render colormapped (no effect but a speed loss)
havoc [Fri, 9 Sep 2005 12:37:25 +0000 (12:37 +0000)]
fix a bug that made the world render colormapped (no effect but a speed loss)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5701 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoMac OS X OpenGL and input module, using Carbon and AGL. Still in development, but...
molivier [Fri, 9 Sep 2005 08:32:50 +0000 (08:32 +0000)]
Mac OS X OpenGL and input module, using Carbon and AGL. Still in development, but stable enough for a player to use. Notable problems and missing features: no hardware gamma support, no desktop menus, mouse movement scaling NOT disabled (please, if someone knows how to do that with Carbon, let me know), and the fact that it has only be tested on one computer so far (my iBook G4)...

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5700 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoremoved detail texturing (it only worked in q1bsp and hlbsp maps, did not work proper...
havoc [Thu, 8 Sep 2005 11:49:00 +0000 (11:49 +0000)]
removed detail texturing (it only worked in q1bsp and hlbsp maps, did not work properly with rtlights, was liked by some people and disliked by many more, and consumed some memory)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5699 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoremoved distortion textures formerly used by GF3 water shader, this frees up 128K...
havoc [Thu, 8 Sep 2005 09:12:16 +0000 (09:12 +0000)]
removed distortion textures formerly used by GF3 water shader, this frees up 128K of texture memory

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5698 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoremoved GF3 water shader (entirely), it probably won't be coming back
havoc [Thu, 8 Sep 2005 09:08:45 +0000 (09:08 +0000)]
removed GF3 water shader (entirely), it probably won't be coming back

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5697 d7cf8633-e32d-0410-b094-e92efae38249

15 years agomoved waterscrollmatrix handling into texture->currentexmatrix to simplify texture...
havoc [Thu, 8 Sep 2005 04:15:17 +0000 (04:15 +0000)]
moved waterscrollmatrix handling into texture->currentexmatrix to simplify texture matrix shaders like water, and added support in R_Shadow_RenderLighting functions

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5696 d7cf8633-e32d-0410-b094-e92efae38249

15 years agochanged Mod_Q3BSP_LoadEffects to allow brushindex -1 (for effects applied to the...
havoc [Wed, 7 Sep 2005 17:41:03 +0000 (17:41 +0000)]
changed Mod_Q3BSP_LoadEffects to allow brushindex -1 (for effects applied to the whole map), and made it use a warning instead of an error for invalid brushindex

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5695 d7cf8633-e32d-0410-b094-e92efae38249

15 years agomigrated surface list iteration into the RenderLighting paths for more efficient...
havoc [Wed, 7 Sep 2005 16:07:47 +0000 (16:07 +0000)]
migrated surface list iteration into the RenderLighting paths for more efficient handling of surfaces, this increased GLSL performance, and vertex lighting performance (rewrote most of it), dot3 path is still quite slow however

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5694 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix a few very small mistakes by Black and Elric: precompiler directives (#define...
havoc [Wed, 7 Sep 2005 16:05:54 +0000 (16:05 +0000)]
fix a few very small mistakes by Black and Elric: precompiler directives (#define) can not have whitespace before them, but can have whitespace after the #

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5693 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix a crash in Cmd_ExecuteAlias when $* is used with no parameters
havoc [Wed, 7 Sep 2005 09:58:37 +0000 (09:58 +0000)]
fix a crash in Cmd_ExecuteAlias when $* is used with no parameters

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5692 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoAdded CoreAudio (Mac OS X) sound driver. Changed / fixed a couple of Mac OS X related...
molivier [Wed, 7 Sep 2005 09:58:15 +0000 (09:58 +0000)]
Added CoreAudio (Mac OS X) sound driver. Changed / fixed a couple of Mac OS X related lines in the makefiles. The sound format is now printed at sound module startup.

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5691 d7cf8633-e32d-0410-b094-e92efae38249

15 years agosplit model->DrawShadowVolume into CompileShadowVolume and DrawShadowVolume to simpli...
havoc [Wed, 7 Sep 2005 09:56:23 +0000 (09:56 +0000)]
split model->DrawShadowVolume into CompileShadowVolume and DrawShadowVolume to simplify things
moved ShadowMesh creation from R_RTLight_Compile to R_Q1BSP_CompileShadowVolume
split R_Shadow_RenderLighting into several functions for different paths to (very slightly) improve readability
fixed a bug introduced by recent specularscale optimizations (it wasn't being passed to RenderLighting)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5690 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoFixed the SDL video driver on Mac OS X (crash when restarting). Thanks to BigMac...
molivier [Wed, 7 Sep 2005 09:54:30 +0000 (09:54 +0000)]
Fixed the SDL video driver on Mac OS X (crash when restarting). Thanks to BigMac for the patch

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5689 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoremoved r_shadow_realtime_world_compilelight cvar and all code relating to it (no...
havoc [Wed, 7 Sep 2005 08:47:55 +0000 (08:47 +0000)]
removed r_shadow_realtime_world_compilelight cvar and all code relating to it (no longer compiles lighting geometry), this is necessary for proper handling of water and animated textures

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5688 d7cf8633-e32d-0410-b094-e92efae38249

15 years agomigrated a lot of error handling out of R_Shadow_RenderLighting and into the loading...
havoc [Wed, 7 Sep 2005 08:40:12 +0000 (08:40 +0000)]
migrated a lot of error handling out of R_Shadow_RenderLighting and into the loading code or DrawLight code, this makes r_shadow_realtime_world_compilelight
0 faster than it was, still not quite as fast as compilelight 1 however

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5687 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoDot crosshair is now a tad bigger (and centred properly)
sajt [Wed, 7 Sep 2005 02:43:41 +0000 (02:43 +0000)]
Dot crosshair is now a tad bigger (and centred properly)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5686 d7cf8633-e32d-0410-b094-e92efae38249

15 years ago396 again
sajt [Tue, 6 Sep 2005 11:28:25 +0000 (11:28 +0000)]
396 again
A few items look like they should be fixed by now: line #'s 47, 51, 208, ... (only looked through a few of them)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5685 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoNew MCBSP format, used for my mod. It differs from bsp 29 in that it stores coloured...
sajt [Tue, 6 Sep 2005 11:17:35 +0000 (11:17 +0000)]
New MCBSP format, used for my mod. It differs from bsp 29 in that it stores coloured lighting data in the bsp file itself, it has a different set of hulls, and a differently formatted header (I used a few hacks to pull that off without adding a new header struct... maybe be changed later).

Anyway, do NOT use this format yet! The format is WIP and backward compatibility will not be kept!

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5684 d7cf8633-e32d-0410-b094-e92efae38249

15 years agonow has two precision error workaround cases rather than one, lifts have been success...
havoc [Tue, 6 Sep 2005 06:51:19 +0000 (06:51 +0000)]
now has two precision error workaround cases rather than one, lifts have been successfully tested at 1 million frames per second
slight cleaning of some variable declarations

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5683 d7cf8633-e32d-0410-b094-e92efae38249

15 years agodon't remove onground flag when riding a pusher, this fixes the e3m2 silver key not...
havoc [Tue, 6 Sep 2005 06:10:51 +0000 (06:10 +0000)]
don't remove onground flag when riding a pusher, this fixes the e3m2 silver key not falling with the platform it is riding

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5682 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoremoved (int) casts added by Sajt's last commit, as they are probably a slowdown...
havoc [Tue, 6 Sep 2005 05:33:53 +0000 (05:33 +0000)]
removed (int) casts added by Sajt's last commit, as they are probably a slowdown in most cases

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5681 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoThe broken pushers are PARTLY fixed. They will now stop when in contact with an entit...
sajt [Tue, 6 Sep 2005 02:17:40 +0000 (02:17 +0000)]
The broken pushers are PARTLY fixed. They will now stop when in contact with an entity and call their blocked() QC function. However they appear to have a tiny portion stuck in the player, so the developer console will still be spammed with 'player is stuck.' messages, and the player can still jump while a crusher is on his head.

Note to smart people: I'm not sure what to stick in movetype for the SV_ClipMoveToEntity calls, so I put 0 since it's not important. Maybe that should be changed to the appropriate value for the sake of Good(tm).

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5680 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix a bug that called player thinks during a level change, this bug may have even...
havoc [Fri, 2 Sep 2005 11:20:51 +0000 (11:20 +0000)]
fix a bug that called player thinks during a level change, this bug may have even been in stock quake

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5679 d7cf8633-e32d-0410-b094-e92efae38249

15 years agofix a memory leak in one error case in LoadTGA and clean up things a little
havoc [Fri, 2 Sep 2005 11:10:10 +0000 (11:10 +0000)]
fix a memory leak in one error case in LoadTGA and clean up things a little

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5678 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoNo longer gives fail message when skybox loads properly, and no longer gives two...
sajt [Thu, 1 Sep 2005 01:59:04 +0000 (01:59 +0000)]
No longer gives fail message when skybox loads properly, and no longer gives two fail messages when skybox doesn't load properly

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5676 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoinitialize red to false (fixes an uninitialized variable warning which appears to...
havoc [Wed, 31 Aug 2005 14:05:59 +0000 (14:05 +0000)]
initialize red to false (fixes an uninitialized variable warning which appears to be a genuine bug)

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5675 d7cf8633-e32d-0410-b094-e92efae38249

15 years agochange GAME_ZYMOTIC default data dir to basezym
havoc [Wed, 31 Aug 2005 09:21:25 +0000 (09:21 +0000)]
change GAME_ZYMOTIC default data dir to basezym

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5674 d7cf8633-e32d-0410-b094-e92efae38249

15 years agoAnother MSVC error fixed
sajt [Tue, 30 Aug 2005 09:40:02 +0000 (09:40 +0000)]
Another MSVC error fixed

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5673 d7cf8633-e32d-0410-b094-e92efae38249

15 years agomodified Mod_ValidateElements to fix broken elements rather than crashing later
havoc [Tue, 30 Aug 2005 08:53:01 +0000 (08:53 +0000)]
modified Mod_ValidateElements to fix broken elements rather than crashing later

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5672 d7cf8633-e32d-0410-b094-e92efae38249