Pressing two mouse buttons at the same time didn't work properly, only
one had effect, e.g. when pressing LMB to walk forward and RMB to shoot
(when bound like that...)
Not sure why that was, but the old mouse button handling (inherited from
the super-old win32 backend where it was supposed to work around bugs in
WinAPI or whatever, where sometimes there were two mouse button presses
in one event or something) was unnecessarily complicated anyway so I
replaced it with something simpler.
Make non global functions static, give some better names to variables,
remove unneccessary special cases and remove some superflous functions.
Form most - if not all - users this changes should be a no-op.
This should ease the overwriting of systemwide installed libs with
specialized versions. Also distributors may use this facility to supply
libraries next to the binaries. Maybe the same should be added for the
other platforms, but I'm not sure if and how they support RPATHes.
I neither have a Mac nor the time to maintain this platform. SDL 2.0
requires some more complex changes than the usual "two lines to track
Unix and Windows" so suspend OS X support until someone steps up.
SDL2 can and should be statically linked. This is much more easier than
linking it dynamically and more comfortable for the user. One libs less
to care about.
Without this change the width of the render windows was required to be a
multiple of 8, making it unable to use strange resolutions like 1366x768.
This change is based upon an idea submitted by "tmcp" in pull request
27.
The quake2 binary now gets -DSDL2 in the CFLAGS, so Win32/OSX can
use different #include paths accordingly.
This is also (ab)used to print which SDL version is used on startup.
Don't use this for anything else, use
#if SDL_VERSION_ATLEAST(2, 0, 0)
instead.
I haven't tested building on/for Win32 or OSX, there may be more
work to do.
Furthermore I added Copyright-Info about CalculateGammaRamp()
in refresh.c (it's from SDL2)
* Fix input issues (mouse-wheel and mouse input)
* SDL2 is not default anymore in the Makefile (use WITH_SDL2=yes)
* If SDL2 is enabled, CD audio is disabled (SDL2 doesn't support
that - use OGG/Vorbis instead)
* Small fix to make it compile with SDL1.2 again
Makefile is adjusted, it compiles and works mostly, but
* For some reason (bug in SDL_GetRelativeMouseState() ?)
mouse input doesn't work properly.. it seems to be bound
to window borders, even if input is grabbed
* some keys can't be used anymore because there's no SDLK_*
for them anymore (gotta find out if this is important)
* Maybe some of the changes need cleanup
Those extensions have become part of ARB about 15 years ago and most if
not all video cards still in use should support the ARB versions. I
believe that at least parts of this code were disfunctional.
This removes the need to define the old qgl function names to the
official OpenGL names. The OpenGL functions are now called directly
without any abstraction.
With this change the "refresh" make target doesn't any longer exists.
It was merged into the "client" target. One will need a "make clean"
before building yQ2 after this change.
This is a manual merge of Hecatomb Q2 ref b8952d5. Manual since git
couldn't do an automerge for some reasons... Notable changes are:
- QGL function pointers are removed, libGL is linked directly
- The OpenGL log framework is removed. It was disfunctional
- The gl_driver cvar is finaly gone
This change is currently untested on Windows and OS. There should
be no problems but a better Makefile integration of libGL is needed.
VID_LoadRefresh with no parameters
VID_LoadRefresh doesn't need a DLL name (because there isn't one)
Rename reflib_active to ref_active
Reference to client input callbacks
All declarations are at the beginning of the file
Full reimplementation of VID_Shutdown
VID_Shutdown does all the refresher cleanup
Reimplementation of VID_FreeReflib
Implementation of VID_LoadRefresh
Normally setting gl_mode cvar would result in VID_LoadRefresh because
of vid_ref being "modified". After removing vid_ref out of the picture
it will "modify" vid_fullscreen to replicate the same behaviour.
Variable "name" (who used to hold refresh dll name) is now left unused
All references to vid_ref cvar has been taken out ...