Commit graph

939 commits

Author SHA1 Message Date
Yamagi Burmeister
e3690bcaab Bump version number to 4.90
This is done to distinguish the upcoming "Yamagi Quake II - Windows Test I"
from the normal 4.21 version.
2012-06-18 09:51:59 +02:00
Yamagi Burmeister
ba9d83e084 Merge branch 'windows'
This brings in support for Microsoft Windows. While more testing is
necessary, the code seems to work quite well (tested by playing through
the first 3 units). Supported Windows versions are Windows XP and
above. Remaining problems are:
- The keyboard layout is always US QWERTY. This is due to a bug
  in SDL. While a work around is possible, most likely it won't
  be applied to Yamagi Quake II.
- The SDL sound backend needs the "dsound" SDL driver which is
  unavailable for 64 bit apllications on 64 bit Windows and
  Windows 8. Users should use the OpenAL backend.
- There me be problems if the %PROFILEDIR% containts unicode
  characters.
2012-06-18 09:33:40 +02:00
Yamagi Burmeister
088ed50566 Merge branch 'scanbuild'
This branch brings fixes to some potential problems found by clangs
"scan-build" tool. The biggest change is es new PRNG, which should
fox some problems related to bad pseudo random number, noticeable
especially after long session. The new PRNG is also a prerequiste
to Windows support.
2012-06-18 09:26:58 +02:00
Yamagi Burmeister
7b54f3d668 Merge branch 'master' into windows
Conflicts:
	src/client/sound/snd_al.c
2012-06-14 12:27:09 +02:00
Yamagi Burmeister
61b10f12da Fix a crash when entering water with s_openal = 0 2012-06-14 12:24:29 +02:00
Yamagi Burmeister
341014eda0 Merge branch 'scanbuild' into windows 2012-06-14 12:18:15 +02:00
Yamagi Burmeister
73e6dc6307 Revert "Convert random() to randk() and crandom() to crandk()"
This reverts commit 12ce981d64.
2012-06-14 12:12:57 +02:00
Yamagi Burmeister
61e8fbdea1 Mention different Windows localizations 2012-06-14 10:49:08 +02:00
Yamagi Burmeister
661599ed99 Add a TODO with the 6 remaining "problems" 2012-06-13 10:55:16 +02:00
Yamagi Burmeister
1f6d0282ee Add an application icon for Windows
The Windows icon is embedded into the executable. It's the same as under
Unix platforms, just converted into .ico.
2012-06-11 11:13:10 +02:00
Yamagi Burmeister
2c0148bab5 Enlargen MAX_OSPATH to 256 on Windows
This is necessary due to the extrem long homedir-pathes in some Windows
localizations. While it would be nice to have the same value on all
platform it would break existing savegames and don't think that it's
worth that.
2012-06-11 10:25:12 +02:00
Yamagi Burmeister
47707a728e Use Windows headers on Windows 2012-06-11 10:18:44 +02:00
Yamagi Burmeister
e70067ceba Refactor the "home"-path finding logic into own functions
With this change the homedir is no longer selected in the filesystem,
but in platform dependend functions. This allows us to use WINABI calls
for selection, resulting using the apropriate diretory on localized
versions of Windows XP.
2012-06-11 09:55:54 +02:00
Yamagi Burmeister
e8eea857e4 Fix another buffer overflow, this time when writing the config.cfg
This overflow is a problem on all platforms but manifested itself
especially on a german Windows XP due to it's long profile path.
2012-06-10 18:45:14 +02:00
Yamagi Burmeister
6c2f97927e Add a missing brace twisting the logic of the Windows XP check 2012-06-09 11:42:35 +02:00
Yamagi Burmeister
16e57ede33 Fix some indention issues 2012-06-06 18:06:08 +02:00
Yamagi Burmeister
39677c1b0f Fix a potential buffer overflow 2012-06-06 17:55:37 +02:00
Yamagi Burmeister
915eea8fef Fix a typo 2012-06-06 17:55:37 +02:00
Yamagi Burmeister
55c11e8475 Document the Windows support in the README 2012-06-06 12:39:53 +02:00
Yamagi Burmeister
29a98c330b Remove "Windows" project, add "Mac OS X" port. 2012-06-06 11:45:40 +02:00
Yamagi Burmeister
d8e35b82c7 Reformat the sound system code
caedes and some other people will probably kill me for this, but I'm the
idiot who has to maintain the code. And that's much easier if it's in a
readable und writeable state.
2012-06-06 11:13:07 +02:00
Yamagi Burmeister
51cc3369b1 Provide an optimized case for mixing 16 bit / 2 chan sound
With sound quality "high" nearly all sound is provided as 16 bit PCM
with 2 channels. Since most players use this setting, provide an optimed
case for it. This should also solve the cracking due to overshot
soundbuffers, which was especially noticeable on Windows. This changes
only effects the old SDL soundbackend and not OpenAL.
2012-06-06 10:34:36 +02:00
Yamagi Burmeister
15400b2133 Use memset() instead of array magic 2012-06-06 10:02:55 +02:00
Yamagi Burmeister
272b897919 Reformat snd_mix.c 2012-06-06 09:58:06 +02:00
Yamagi Burmeister
f5233db0b2 Add IPv6 support for Windows
This is essentially a port of unix/network.c to windows.
2012-06-06 09:48:48 +02:00
Yamagi Burmeister
0c74a1af75 Create profile in Documents instead of AppData 2012-06-05 14:28:34 +02:00
Yamagi Burmeister
d17d996dc5 Import Sys_Mkdir() into the refresher 2012-06-05 14:19:29 +02:00
Yamagi Burmeister
f116882160 Remove TODO 2012-06-05 12:54:54 +02:00
Yamagi Burmeister
7715592aaa Write config data in AppData
Under Windows all config data is written to %USERPROFILE%\AppData\
Local\YamagiQ2. To archive this code was added that translates Windows
pathes with backslashes into Unix pathes with normal slashes.
2012-06-05 12:52:44 +02:00
Yamagi Burmeister
3de98e3b7b Add a comment for WITH_SYSTEMWIDE under Windows 2012-06-05 11:12:23 +02:00
Yamagi Burmeister
e5bc9d08ec No console window for the client 2012-06-05 11:02:48 +02:00
Yamagi Burmeister
0b9ec45eb7 Remove leftovers from the softrenderer 2012-06-05 10:54:47 +02:00
Yamagi Burmeister
de3e53069f Remove Alt-Tab handling. It's done by SDL 2012-06-05 10:50:24 +02:00
Yamagi Burmeister
a55d717a80 Replace atoi() with strtol() in Windows code 2012-06-05 10:46:15 +02:00
Yamagi Burmeister
af83f80dff Add header guards to new headers 2012-06-05 10:42:30 +02:00
Yamagi Burmeister
bf590cbba5 Clean up the Makefile 2012-06-05 10:37:34 +02:00
Yamagi Burmeister
28be8cda8e Work around the missing _controlfp prototypes in MinGW 2012-06-05 10:29:20 +02:00
Yamagi Burmeister
58c3b22c8a Add platform defines for Windows 2012-06-05 10:17:01 +02:00
Yamagi Burmeister
ca18af254e Remove Sys_AppActivate()
This code is unnecessary because SDL handles all activation events,
brings the Window into foreground, etc.
2012-06-05 10:11:29 +02:00
Yamagi Burmeister
21ab0de692 Remove support for the Windows clipboard
This was just broken and rewriting it is not worth the efford
2012-06-05 10:09:24 +02:00
Yamagi Burmeister
67a147014a Reenable retexturing 2012-06-05 10:06:13 +02:00
Yamagi Burmeister
d1008a564d Port OpenAL to Windows and enable it by default 2012-06-05 09:57:30 +02:00
Yamagi Burmeister
4021087a38 Make the SDL sounddriver selectable via s_sdldriver
This is necessary since the default "waveout" driver on windows is
incompatible to Quake II (due to too big output buffers) and "dsound"
can't be forced since it's not available on some installations. The
default driver is choosen by platform:

Windows -> dsound
FreeBSD -> dsp
Linux   -> alsa
2012-06-05 09:03:46 +02:00
Yamagi Burmeister
2629f908ae Initialize randk() and startup 2012-06-04 16:24:37 +02:00
Yamagi Burmeister
7b01ac3452 Fix build under !Windows 2012-06-04 14:07:32 +02:00
Yamagi Burmeister
7c41b66821 Merge branch 'windows' of github.com:yquake2/yquake2 into windows
Conflicts:
	Makefile
	TODO
	src/windows/header/winquake.h
	src/windows/system.c
2012-06-04 14:04:11 +02:00
Yamagi Burmeister
d8dc40fdb4 Update the TODO. We're now able to start the game and watch the demo loop 2012-06-04 13:53:00 +02:00
Yamagi Burmeister
ea02b14ca7 Poke the input subsystem at every frame to process events 2012-06-04 13:51:46 +02:00
Yamagi Burmeister
6b650e9ea7 Initialize the input backend 2012-06-04 13:40:23 +02:00
Yamagi Burmeister
6b7bc06074 opengl32.dll is the default gldriver on Windows 2012-06-04 13:13:14 +02:00