Commit Graph

921 Commits

Author SHA1 Message Date
Bill Currie 7feaa3d631 Want for the mouse to move when going fullscreen before moving the
viewport. This should fix the uncetnered viewport when going fullscreen.
Also discard mouse events caused by fullscreen toggling to avoid chaning
orientation.
2004-03-21 05:21:27 +00:00
Bill Currie 0b808b0c49 so that's why you would want to use XMaskEvent... don't lose the FocusIn
and EnterNotify events when starting fullscreened
2004-03-21 00:34:24 +00:00
Bill Currie 78fd6d2513 minor cleanup of window position handling. hopefully no more window off
screen issues (wait for ConfigureNotify instead of MapNotify on window
creation (ConfigureNotify gives us our window position)).
2004-03-19 20:24:26 +00:00
Bill Currie 9099baeb6d minor cleanups preparing for an overhaul 2004-03-18 06:05:59 +00:00
Bill Currie ff5b215c13 multi statement macro fixes as pointed out by Grievre 2004-03-16 04:15:07 +00:00
Bill Currie e24cbd75e0 M_BUTTON6 and M_BUTTON7. nuff said :) 2004-03-16 04:12:28 +00:00
Ragnvald Maartmann-Moe IV 29502c8f5a Lots of optimizations, particularly for GL state changes, and tweak lighting a
bit more.

Also a cleanup from Grievre: Use VectorIsZero in two places in gl_mod_alias.c.
2004-03-15 21:32:19 +00:00
Ragnvald Maartmann-Moe IV 9cd16b8dfd Grievre's lighting patch, plus some of my own changes.
My changes:
Emit normals if truform is enabled.
Attempt to avoid 0,0,0 normals (makes lighting & tesselation unhappy).
Fix some (ancient) apparent bugs in GetAliasFrameVerts16().
Clamp minlight, instead of adding it.
Apply colormod as glColor, rather than adding it to emission, to prevent QSG2
 issues with fullbrights.
Rearrange init code, and don't go quite as wild with responsiveness to lights.

Material & lightmode settings will need tweaking & testing to work well on all
 cards. Feedback needed there.
2004-03-10 08:14:38 +00:00
Ragnvald Maartmann-Moe IV b7df0b5278 Remove gl_doublebright, remove fractional overbrights, clean up init a bit,
uglify init a bit. Stuff for taniwha to look at. Nothing to see here, move
along.
2004-03-07 23:51:29 +00:00
Bill Currie 37024a4419 final (?) cleanup of center printing. turns out there's no reason to keep
it in the renderer and every reason to pull it out (ok, some might
disagree:)
2004-03-02 03:55:18 +00:00
Bill Currie 39fc0fe721 more centerprint cleanup. 2004-03-02 00:58:13 +00:00
Bill Currie 2955fac550 first step of centerprint/finale cleanup. fixes the misplaced text for
end-of-episode text
2004-03-01 23:47:39 +00:00
Ragnvald Maartmann-Moe IV 0c133699d0 Whee. 2004-02-29 02:58:15 +00:00
Ragnvald Maartmann-Moe IV 44c89c1904 Optimize fullbright testing for brushes, assorted other cleanups, test for
functions built into current GL drivers, as well as the old extensions, and
add incorrectly rendering BGRA support.
Whee!
2004-02-24 20:50:55 +00:00
Bill Currie f7a8645fad make dist fix 2004-02-23 21:40:23 +00:00
Bill Currie f9b95cee92 some micro-optimisations 2004-02-23 07:17:41 +00:00
Ragnvald Maartmann-Moe IV 872498a1f0 Reorder a lot of code, removing tons of ifs. multitexture paths are a bit more
sane now. Also optimize QSG2 color handling, and fix some QSG2 bugs. Not that
anyone cares, nobody uses it anyways.
Should be faster, but isn't here. *grmbl*
2004-02-22 06:00:15 +00:00
Bill Currie b502cfc3ce move ClientReliable* from sv_nchan to MSG_Reliabe* in msg_backbuf so the
backbuffer code can be shared between qw-server and qtv
2004-02-22 05:40:08 +00:00
Ragnvald Maartmann-Moe IV 5157f668ad Fix a bunch of state leaks that made multitextured fullbrights smear the world.
Now just have one (known) issue with bmodels with fullbright textures not
rendering their base texture. Floating fullbrights are nifty!

Also a number of optimizations, which need wider performance testing.
2004-02-21 05:36:19 +00:00
Bill Currie 6e6df349e4 move the ucmd message code into a common qw lib (more will likely follow) 2004-02-21 05:09:02 +00:00
Bill Currie 1033f7e322 move qw/include/protocol.h to include/qw/protocol.h making life easier
qtv can now connect to a server (won't stay connected though)
2004-02-21 02:31:22 +00:00
Bill Currie 2262d02b1a disable logging for outgoing packets until I come up with a clean way of
enabling it
2004-02-19 23:11:15 +00:00
Bill Currie 0e1a9e5082 a bit more netchan cleanup 2004-02-19 23:06:47 +00:00
Bill Currie fa58b795f2 except for packet logging, netchan is much cleaner (no more cls in the
server!)
2004-02-19 08:58:42 +00:00
Bill Currie 8069becadf pkgincludedir and pkglibdir patch from
"Alexey I. Froloff" <sir_raorn@immo.ru> (raorn)
2004-02-18 06:28:37 +00:00
Chris Ison 6642686e33 removal of legacy MGL block_drawing variable. Fixed window restore bug that prevented the screen from being updated. 2004-02-15 03:40:50 +00:00
Ragnvald Maartmann-Moe IV fef9b30bd7 QF, now complete with underbrights, thanks to Grievre.
Play with gl_overbright and gl_doublebright. That's an order.
2004-02-15 00:02:04 +00:00
Bill Currie 85a268c62f Grievre's lightmap/fullbright multitexture patch (fbs not tested due to
lack of drivers supporting 3 tmus)
2004-02-14 05:10:29 +00:00
Bill Currie f34335a0c9 provide a builtin to draw a crosshair. 2004-02-13 23:16:33 +00:00
Bill Currie a821f048a0 change FNC to FN and fnc to fn for function based opcodes 2004-02-11 06:52:19 +00:00
Bill Currie c3f41e3e69 new opcode: state.f. same as state, but takes a 3rd float operand to
specify the step for calculating nextthink. accessed using
[frame, think, step] (state is [frame, think])
2004-02-11 01:43:33 +00:00
Ragnvald Maartmann-Moe IV c4402e07bd Working towards merging q2 model, sprite, and map support. Check back in a few
years, might be finished. ;)
2004-02-08 02:49:38 +00:00
Bill Currie 8ea7690530 serious cleanup of refdef calculations. 2004-02-08 00:37:11 +00:00
Bill Currie 893d3ec290 hash.[ch]:
add Hash_NumElements to get the number of elements in the hash table
qfplist.[ch]:
	add PL_A_NumObjects and PL_D_NumKeys, to get the number of objects or
	number of keys in the array or dictionary, respectively
2004-02-07 07:47:23 +00:00
Bill Currie a45981bc6a don't look up the gl functions until after the context has been setup, just
incase it affects which functions glGetProcAddress actually returns.
2004-02-06 00:58:35 +00:00
Bill Currie 77d266d938 use a little less make recursion. should speed up builds a bit 2004-02-04 07:36:47 +00:00
Bill Currie 9784ba5954 Grievre's gamedir callback patch to fix mangled sounds on gamedir change
plus a couple minor tweaks I notcied needed doing.
2004-02-03 03:01:06 +00:00
Bill Currie 24294c8778 make printing of global contents in PR_PrintStatement optional so
disassembly output is cleaner
2004-01-31 04:26:01 +00:00
Ragnvald Maartmann-Moe IV 0e6681a069 Add QFGL_WANT, and ability to handle non-required extensions. 2004-01-28 02:49:57 +00:00
Ragnvald Maartmann-Moe IV e1146a541c TruForm support. Controlled by gl_tessellate 2004-01-26 00:13:47 +00:00
Bill Currie bb31308953 ruamoko math functions from Grievre 2004-01-22 05:43:18 +00:00
Bill Currie db32c8394b export BoxOnPlaneSide properly in windows so it doesn't cause a segfault 2004-01-22 02:26:08 +00:00
Bill Currie 390ca99a92 first step to making qfdefs redundant. "standard" progs now get resolved
staticly rather than looking up the defs. "broken" progs should now work.
2004-01-21 08:09:47 +00:00
Bill Currie d5a33c9545 extend the sound api slightly to ease things like cd_file and make cd_file
work as intended :)
2004-01-21 02:52:12 +00:00
Bill Currie 19ef80c555 this should fix static win32 builds 2004-01-21 00:15:35 +00:00
Bill Currie f7fe0a4a8c remove two redundant functions from cd_funcs_t and convert all the cd
plugins to using pre-initialized structs
2004-01-20 08:34:57 +00:00
Bill Currie 6d02004ca8 Mike Gorchak's <mike@malva.ua> second (final for now:) QNX patch. renames
msg_t to qmsg_t.
2004-01-20 06:11:00 +00:00
Bill Currie e154c9add5 be consistent with WIN32 and _WIN32 (now all _WIN32) 2004-01-20 03:47:27 +00:00
Ragnvald Maartmann-Moe IV 459503e61b Argh. 2004-01-19 21:48:45 +00:00
Bill Currie 77b2942982 several libs can now get built as dlls in windows: console, gamecode,
gamecode_builtins, gib, image, modules, object, ruamoko and util.
2004-01-19 07:47:41 +00:00
Bill Currie eb69be5e5a more doxygen fixes 2004-01-17 08:09:30 +00:00
Bill Currie 249aee2e9f move the OO runtime support code from libQFgamecode to libQFruamoko where
it really belongs :)
2004-01-16 08:02:31 +00:00
Bill Currie e7ffad8772 more rua cleanups: now just one init function to call (it calls the rest) 2004-01-16 07:03:58 +00:00
Bill Currie 01392c78bb move the bulk of what whas libQFcsqc to libQFruamoko. 2004-01-16 05:46:19 +00:00
Ragnvald Maartmann-Moe IV 710a6c9e2d Fix headers for alsa 0.9. 2004-01-16 00:45:42 +00:00
Bill Currie 31d970aca0 can now dump a map's textures to a wad file (name currently based on bsp
file name (eg, foo.bsp -> foo.wad)
2004-01-15 07:16:44 +00:00
Bill Currie 2a399cc4b4 Sys_PathType has been unnecessary for a while so nuke it 2004-01-13 21:30:13 +00:00
Chris Ison 0d755a0dd6 dirent.c and dirent.h brought in from cygwin for win32 builds 2004-01-12 02:23:36 +00:00
Bill Currie 03a24be4de partial work on wad file access cleanup in preparation of making a wad
utility
2004-01-09 23:34:32 +00:00
Bill Currie 808baf2198 doxygen didn't like that construct 2004-01-09 03:32:00 +00:00
Bill Currie c5c5c33e7d I had forgotten the free string refs list /had/ to be in the progs vm 2004-01-08 04:03:47 +00:00
Bill Currie ccfa9081b0 fix shm properly :) 2004-01-08 03:46:11 +00:00
Bill Currie deb8137db7 more sound static cleanup 2004-01-08 01:48:02 +00:00
Bill Currie 16f0a54a84 fix some inconsistencies pointed out by doxygen 2004-01-07 20:06:15 +00:00
Bill Currie b3f76e1e48 add some string builtins (only the basics for now, but enough to deal with
temporary strings) and fix the game load/save menus.
2004-01-07 07:36:17 +00:00
Jeff Teunissen eb6b179add plist functions that add objects return qboolean, not int. Also doc fixes. 2004-01-07 07:01:31 +00:00
Bill Currie 9c92a916ff change the dict and array add functions to return true/false and add some
more docs
2004-01-07 06:19:11 +00:00
Bill Currie e455b760ca use a cycled pool of "return strings". I'd love to come up with something
better, but this will do (similar to what qwe does, but qf style:)
2004-01-07 05:22:57 +00:00
Jeff Teunissen d1b4c5df72 Change PL_D_AddObject() so that it replaces values instead of stacking them.
Add PL_D_AllKeys(), which returns a list of all keys in a dictionary.
Rename PL_FreeItem() to PL_Free() -- what was I smoking?
Document some of the property list system for doxygen.
2004-01-06 11:09:40 +00:00
Bill Currie 133879f8fa provide builtin mappings for id (none, really), qf and ktpro/qwe (qw only),
add qwe builtin extensions to qw-server. provide sv_progs_ext to control
the builtin mapping. valid values are "id", "qf" (our old static builtins),
"qwe"/"ktpro" (either works. for ktpro mod support) and "none" (no
mapping). any other value is equivalent to "none".
2004-01-06 07:00:39 +00:00
Bill Currie d7592781d7 add builtin mapping support (not used yet) and fix an uninitialized
variable
2004-01-06 06:08:59 +00:00
Bill Currie acd54afff7 move to using a hash table for builtin number -> builtin lookup so sparse
ranges can be used efficiently. move the auto-allocated builtins to
0x10000000-0x7fffffff. should be more than enough :)

use static builtin tables ("nul" terminated) instead of a series of
function calls to add builtins to a vm. should be more memory efficient.
2004-01-06 05:51:09 +00:00
Bill Currie 595280decb do the builtin function lookup at load time rather than runtime and store
the function address in the progs function descriptor. this will speed up
calls to builtin functions, especially when ranges get introduced.
2004-01-05 08:08:46 +00:00
Bill Currie dfc83c1f5f add PR_PushFrame and PR_PopFrame so temp strings are easy to use for
parameters to progs functions.

double the progs stack sizes (call depth of 32? eek)

allow one extra call on the progs stack :)

misc minor cleanups
2004-01-05 07:10:32 +00:00
Bill Currie dfe7f263c7 new internal printf engine for progs, mostly thanks to Deek.
also a few cleanup bits
2004-01-04 07:42:43 +00:00
Bill Currie a533761770 Nuke PR_GarbageCollect as it's both redundant with the new temp strings
and wrong anyway (could free strings it wasn't supposed to).

Don't free the string pointed to by a strref since it's already been
implicity freed (whole memory space nuked). Fixes new map crash.
2004-01-04 02:03:30 +00:00
Bill Currie bd561fafc3 o all progs strings are now stored in progs memory
o  temporary strings automaticly get freed when the function they're
    created in (results of str + str and most strings returned from
	builtins). a way to keep temp strings will be provided later
 o	fix up qwaq to test the temp strings
2004-01-03 08:43:57 +00:00
Ragnvald Maartmann-Moe IV 1be98dcf08 gl_external_textures -> gl_textures_external, plus whitespace & codingstyle. 2003-12-23 20:05:52 +00:00
Bill Currie 4b6b5135ac more texture tweeks from Griever: gl_external_textures 2003-12-23 08:38:33 +00:00
Bill Currie 5eff81b005 dstrings now have individual memory management functions 2003-12-22 23:35:22 +00:00
Ragnvald Maartmann-Moe IV 5f76017d2a Update ALSA sound target to support 1.0.
Breaks 0.9 support, but 1.0 is in 2.6.0. So either update, or revert to older
snd_alsa.c & alsa_funcs_list.h.
2003-12-22 01:07:49 +00:00
Bill Currie 9e3f33f318 don't need to see these :) 2003-12-19 04:25:07 +00:00
Brian Koropoff f8baa5be27 Added a finalize method to all Objects and modified the garbage
collector to deal with objects that might gain references during
finalization.
2003-12-09 06:57:35 +00:00
Brian Koropoff 991fc06360 Garbage collection:
Moved from reference counting over to a mark and sweep method.  Objects
are now required to implement an allRefs method which returns a pointer
to a list of all other referenced objects.  How the list is maintained
is up to each object.  The retain/release mechanism still works; objects
with any references will not be garbage collected, even if the collector
thinks they should be.
2003-12-09 02:01:05 +00:00
Brian Koropoff e498b196fe Fix a bug with ArrayList_Deinit_f (tried too hard to be clever), and add
an incremental, reference counting garbage collector for QFobjects.  A
different kind of collector will eventually be needed to run once in a
while to sweep up cyclic structures.
2003-12-07 22:45:32 +00:00
Brian Koropoff 7598ab35fb Move the QF object system into it's own library, fix up the standard
classes.
2003-12-07 04:50:46 +00:00
Bill Currie 09143b7fb1 more whitespace 2003-12-06 22:49:18 +00:00
Bill Currie 4d3ca27227 white space 2003-12-05 22:33:11 +00:00
Brian Koropoff a0b8566337 Add the instanceOf() macro and supporting function, and try to fix
gcc 2.95 support again.
2003-11-29 23:09:50 +00:00
Brian Koropoff dfe1dbe4bf This should fix object.h on gcc 2.95. 2003-11-29 22:51:16 +00:00
Brian Koropoff 55181621bd First commit of an experimental low-level object system. At some point
GIB will be reworked to use it, and hopefully Rua will also so that the
two languages can share objects, events, etc.

Warning: This uses quite a few hacks and tortured macros, it might cause
breakage.
2003-11-29 04:40:25 +00:00
Brian Koropoff 37a64e59ab Change some error names, mark a few things static that should be. Instead
of using a colon to specify a parent class in a GIB class definition,
"extends" is now used.  If no parent class is specified, it now defaults to
Object.
2003-11-29 02:01:31 +00:00
Bill Currie cd8035319d PR_GetString should have been returning const char *. now does 2003-11-21 21:34:53 +00:00
Bill Currie 5f5662a063 PF_VarString return a plain char * and make it easier to add "at load" init
functions
2003-11-20 07:46:56 +00:00
Bill Currie b3c6e763cd allow cbufs to have a callback for unknown commands. if the callback
returns non-zero the unknown command is assumed to have been handled and no
error is reported
2003-11-20 07:02:14 +00:00
Bill Currie 481c9c4e8d add Sys_TimeOfDay from QWE (HighlandeR) 2003-11-20 07:00:07 +00:00
Ragnvald Maartmann-Moe IV 5686ff51e5 Make R_DarkFieldParticles & R_EntityParticles work in all renderers. 2003-10-22 06:00:36 +00:00
Brian Koropoff f4c174184d Add support for named arguments in GIB functions and methods, fix a few
bugs, allow subclasses of classes written in GIB to access the same set
of instance variables.
2003-10-19 00:51:47 +00:00
Brian Koropoff ad61e0684c Make GIB_Reply an actual function, store object handles as a string, add
the ObjectHash class.
2003-09-21 00:30:47 +00:00
Bill Currie 84ea81a770 fix E_POINTER and E_FUNCTION 2003-09-12 23:12:21 +00:00