havoc [Thu, 14 Feb 2008 14:10:57 +0000 (14:10 +0000)]
added experimental cl_alwayssleep cvar which calls Sys_Sleep(0) at the
end of each frame
fixed a bug in the main loop that made Sys_Sleep be called with
milliseconds when it takes microseconds
divverent [Wed, 6 Feb 2008 07:38:46 +0000 (07:38 +0000)]
disable joystick by default, and make joy_enable saved;
add extension DP_QC_CVAR_TYPE that checks what type a cvar is (like, if the engine created it or the mod, or if it is saved)
will write dpextensions.qc block for it later, a start of its description is in mbuiltin.h in Nexuiz
black [Tue, 5 Feb 2008 18:15:09 +0000 (18:15 +0000)]
Comment out a line in setmodel again (needs fixing but wasn't in there before anyway)
Always clear the depth buffer in R_RenderView.
Use realtime as scene time when rendering the menu scene.
black [Tue, 5 Feb 2008 16:20:23 +0000 (16:20 +0000)]
Fix the VM's clientstate builtin to do a correct mapping between the client state and the menu's constants (now that the client state values have changed in DP itself).
havoc [Mon, 4 Feb 2008 11:47:04 +0000 (11:47 +0000)]
huge audit of dprints throughout engine, all notices of successfully
loading models/sounds/skins/etc are now tied to the cvar
developer_loading
added developer_loadfile cvar (prints every successful FS_LoadFile)
many improvements to consistency of loading notices, and some cleanups
to q3 shader handling
fixed annoying 'Bad dynamic texture name' spam at load
havoc [Mon, 4 Feb 2008 11:33:14 +0000 (11:33 +0000)]
fix bug that caused early console messages to not be put in console
history (because cls.state defaulted to ca_dedicated - now it defaults
to ca_uninitialized)
havoc [Mon, 4 Feb 2008 01:28:39 +0000 (01:28 +0000)]
modified droptofloor to try a downward trace from the bottom center of
the object if it is stuck, this manages to 'correctly' place many badly
placed entities in quake maps
additionally modified droptofloor to first try unsticking the entity
before dropping it (sv_gameplayfix_droptofloorstartsolid_nudgetocorrect)
havoc [Sun, 3 Feb 2008 11:12:42 +0000 (11:12 +0000)]
fix Black's PRVM_EDICT_NUM_ERROR return type change which did not work
(0 is not the same as NULL, compilers get upset about that)
one other minor correction of the same kind
divverent [Sat, 2 Feb 2008 18:38:38 +0000 (18:38 +0000)]
fix bugs with changing apple_mouse_noaccel and vid_dgamouse while grabbed (that previously could "destroy" mouse support until console gets pulled down and up)
black [Fri, 1 Feb 2008 16:21:37 +0000 (16:21 +0000)]
Rewrite CSQC's setmodel a bit.
Add support for CSQC_Ent_Spawn to csqc. A function that is called when a entity packet from the server arrives that requires a new entity.
entity( float entnum ) CSQC_Ent_Spawn;
CSQC_Ent_Spawn needs to spawn a new entity and set its .entnum field accordingly or simply return another existing entity or world if it wants to ignore that server entity. Subsequent CSQC_Ent_Update calls are routed to that entity (or CSQC_Ent_Spawn is called again when .Version increases).
divverent [Fri, 1 Feb 2008 08:56:31 +0000 (08:56 +0000)]
- vid_userefreshrate: when 0, a sane default is tried to be used
- win32: list valid modes, and use the closest match
- win32: vid_forcerefreshrate: don't do the listing, but just try to set it anyway
havoc [Fri, 1 Feb 2008 06:00:59 +0000 (06:00 +0000)]
renamed MATERIALFLAG_WATER to MATERIALFLAG_WATERSCROLL
changed all MATERIALFLAG_WATER materials to use MATERIALFLAG_WALL as
their primary material flag, this simplified some rendering code
did some more tweaks to fix issues with the mirror glass texture in
the tenebrae testmap
havoc [Tue, 29 Jan 2008 18:53:55 +0000 (18:53 +0000)]
changed postprocess shader to use Texture_GammaRamps instead of
Texture_Attenuation to make the code more clear (no impact on
performance)
fixed bug with viewblend being applied inversely
divverent [Tue, 29 Jan 2008 16:55:43 +0000 (16:55 +0000)]
v_glslgamma: make GLSL postprocessing take over the job of v_hwgamma completely, if set and glsl works. Costs here 1.6ms per frame, so I'll keep r_glsl_contrastboost.
divverent [Tue, 29 Jan 2008 12:29:14 +0000 (12:29 +0000)]
add an extra unused #ifdef to the glsl shader so the shader can know if it was actually enabled by r_glsl_postprocessing or if it was just forced by bloom
divverent [Tue, 29 Jan 2008 12:08:06 +0000 (12:08 +0000)]
make other parts of DP able to retrieve the gamma table, and add a serial field so other subsystems can poll if it has changed. Useful for handling it using glsl.
divverent [Tue, 29 Jan 2008 11:39:41 +0000 (11:39 +0000)]
v_contrastboost, and support for the color control functions to fill the gamma table. Goal: remove USECONTRASTBOOST and USEGAMMA in the postprocess shader, replace it by USEGAMMARAMP, and let vid_shared build the gamma tables even if hw gamma is off when glsl needs them... then add a cvar r_glsl_hwgamma that lets glsl take over gamma ramp handling
divverent [Mon, 28 Jan 2008 09:40:11 +0000 (09:40 +0000)]
add a DEMOMSG_CLIENT_TO_SERVER flag to demos (0x80000000) in the size field; packets with this flag will be ignored by playback. sv_autodemo_perclient 2 will record these packages for debugging purposes (like, recording a speedhacker's or other protocol exploiter's packets, and analyzing them with the data in the demo file manually)
havoc [Mon, 28 Jan 2008 03:36:03 +0000 (03:36 +0000)]
added r_glsl_postprocess cvar to apply a postprocessing pass over the
screen (currently only implements r_glsl_contrastboost)
this path is also activated if bloom or hdr is active with r_glsl 1
black [Mon, 28 Jan 2008 01:02:56 +0000 (01:02 +0000)]
Make fgets always return the null string on error.
Add code to FS_Open to fix bad paths (replaces \ with /). The code is nasty and #ifdefed out - #define FS_FIX_PATHS to use it.
black [Sun, 27 Jan 2008 18:49:34 +0000 (18:49 +0000)]
R_SetView now supports VF_CLEARSCREEN which decides whether to clear the screen or not when rendering the view (this is of particular interest for rendering view in views or for the menu).
black [Sun, 27 Jan 2008 17:23:08 +0000 (17:23 +0000)]
Pass the name of the instance to Gecko_Query, too.
Add setattachment, gettaginfo and gettagindex to menu builtin list, too.
Add DP_GECKO_SUPPORT and DP_QC_GETSURFACEPOINTATTRIB to dpextensions.qc.
havoc [Sun, 27 Jan 2008 08:39:42 +0000 (08:39 +0000)]
some surface rendering code cleanup
eliminated several redundant state calls
eliminated RSurf_CleanUp function
eliminated special gl_lightmaps rendering path
moved all but the basic material rendering from R_DrawTextureSurfaceList
to R_ProcessTextureSurfaceList, this simplifies the transparent callback
and allowed me to move the transparent queuing into this function
havoc [Sun, 27 Jan 2008 06:28:54 +0000 (06:28 +0000)]
implemented r_glsl_usegeneric cvar, this causes generic GLSL shaders to
be used in place of ALL conventional fixedfunction rendering, seems to
give about a 3% fps increase on NVIDIA drivers
this should fix zfighting issues involving r_depthfirst or shadows,
particularly on Mac OSX (may also fix the OSX rotating/scrolling hud)
black [Sun, 27 Jan 2008 02:18:54 +0000 (02:18 +0000)]
Add R_SelectScene and R_GetScenePointer that encapsulate access to an array of r_refdef_scene_t that is swapped into r_refdef on need.
Change the menu to use it and fix a bug that was caused because of the menu's use of the stack for backing up the client's scene.
havoc [Sun, 27 Jan 2008 00:55:22 +0000 (00:55 +0000)]
rewrote most of the VM_Polygon/DebugPolygon code, it should perform much
better now and has no upper limit on polygons, and only a 64 point limit
per polygon, and has transparent sorting again
havoc [Fri, 25 Jan 2008 23:31:06 +0000 (23:31 +0000)]
disabled size throttling of packets if csqc is used (because it was very
easy to end up with >128 byte entity updates which can in some cases
never be sent at all due to the size throttling)
havoc [Fri, 25 Jan 2008 19:47:02 +0000 (19:47 +0000)]
vary r_drawparticles_drawdistance and r_drawdecals_drawdistance for
quality limiting according to FPS, instead of skipping particles, this
looks much better (but doesn't help FPS as much)
havoc [Fri, 25 Jan 2008 08:48:57 +0000 (08:48 +0000)]
implemented framerate-dependent particle quality reduction to try to
smooth out fps swings in Ruiner in Nexuiz
added r_drawparticles_drawdistance (and one for decals)
particles and decals arrays now grow dynamically and have smaller
defaults than before
fixed bug with rain particles that made them live for about 4 minutes if
they fell out of the map
havoc [Tue, 22 Jan 2008 20:05:42 +0000 (20:05 +0000)]
merged CL_MoveParticles, CL_MoveDecals, and R_MoveExplosions into their
respective Draw functions, this gave a small fps gain (due to better
cache behavior)
redesigned input packet timing (now based on cl.time instead of
realtime, which required compensating for slowmo), this takes advantage
of the time synchronization features of the cl.time code
replaced cls.movesequence with cls.netcon->outgoing_unreliable_sequence
havoc [Tue, 22 Jan 2008 19:56:33 +0000 (19:56 +0000)]
fixed sprites rendering incorrectly in reflections (the view vectors no
longer match the actual rendering matrix in the reflection case, fixing
such problems)