Commit graph

1935 commits

Author SHA1 Message Date
Clownacy
09fa34cbc7 Do not link libSDL2main.a
Causes stupid annoying errors and CSE2 doesn't even need it anyway so
wtf
2020-04-05 20:13:24 +01:00
Clownacy
bcd883e767 Fix weird buzzing in the software mixer
Not really sure why this causes it, but apparently it does.
2020-04-05 18:17:38 +01:00
Clownacy
0aa65f7cd3 Fix pkg-config static linking
For some reason, [LIB]_STATIC_LINK_LIBRARIES is blank. Thanks a lot,
CMake.
2020-04-05 16:58:52 +01:00
Clownacy
eaef25d5da Change how backend keyboard status stuff works 2020-04-05 13:26:08 +01:00
Clownacy
aef0f81f28 Offload keyboard tracker to the engine
Centralising it in the backend breaks the enhanced branch's rebinding
menu.
2020-04-05 04:31:11 +01:00
Clownacy
d62ca286f6 Merge branch 'accurate' into portable 2020-04-05 04:18:02 +01:00
Clownacy
f75859b759 Change constant ordering
This was bugging the hell out of me
2020-04-05 03:35:43 +01:00
Clownacy
e39c46fae9 Force glad to be static
Pretty sure it isn't set up to generate a proper DLL, so make sure it
always produces a static library instead.
2020-04-05 03:27:50 +01:00
Clownacy
393359e63f Add some sanity checks 2020-04-05 03:27:04 +01:00
Clownacy
80091c4be5 Simplify some logic 2020-04-05 03:25:58 +01:00
Clownacy
b6398c58b4 Disable GLFW hats in <3.3
Doesn't exist - causes Travis to fail
2020-04-05 03:24:55 +01:00
Clownacy
ee1e7aed11 Fix unfreed memory 2020-04-05 00:58:56 +01:00
Clownacy
67765fd0ad Fix 2020-04-05 00:54:45 +01:00
Clownacy
26de0b6043 Improve the SDL2 controller backend too 2020-04-05 00:31:17 +01:00
Clownacy
c187660904 Hat cleanup 2020-04-05 00:20:41 +01:00
Clownacy
8fdaea5d8b More cleanup and fixes 2020-04-05 00:16:19 +01:00
Clownacy
6bb240d335 Fixes 2020-04-05 00:11:52 +01:00
Clownacy
e0674d8f54 Restore support for joystick axes neutrals
These are useful for PS3 analogue triggers, which are -1.0f by
default, and go up to 1.0f when pressed.
2020-04-05 00:08:29 +01:00
Clownacy
ac533cb35e Add support to the GLFW3 backends as well
Also fix the SDL2 backend wow
2020-04-04 23:22:22 +01:00
Clownacy
08bd2e1e78 Cleanup 2020-04-04 22:57:32 +01:00
Clownacy
2aeda93aeb SDL2 controller backend - support axes and hats
These are now mapped to buttons - will have more of a use in the
enhanced branch.
2020-04-04 22:54:58 +01:00
Clownacy
7c729af36f Add a comment 2020-04-04 20:58:12 +01:00
Clownacy
6ea58290f4 Set SDL2 audio backend to 48000Hz 2020-04-04 20:57:34 +01:00
Clownacy
b3e40b0475 Fix SDL2 audio backend 2020-04-04 20:52:24 +01:00
Clownacy
1ae63bea96 Move window ownership to the window backend 2020-04-04 20:51:07 +01:00
Clownacy
1d665aaab6 Merge branch 'accurate' into portable 2020-04-04 20:40:49 +01:00
Clownacy
630b5e3657 Prevent console from appearing in Makefile builds 2020-04-04 20:40:02 +01:00
Clownacy
cdd69496c4 Fixes 2020-04-04 20:34:51 +01:00
Clownacy
135035bb1a Change 'PlatformBackend' namespace to 'Backend' 2020-04-04 20:31:27 +01:00
Clownacy
daf5d3cc7e Add missing file 2020-04-04 20:25:12 +01:00
Clownacy
4d322be866 Change render backend namespace to RenderBackend_ 2020-04-04 20:24:34 +01:00
Clownacy
8acdcface4 Update CMakeLists.txt 2020-04-04 19:56:57 +01:00
Clownacy
4568d58c77 Cleanup 2020-04-04 19:53:16 +01:00
Clownacy
65325e2b34 Add hotplugging support to SDL2 backend 2020-04-04 19:50:52 +01:00
Clownacy
7ee2e68c2e Fix 2020-04-04 19:28:52 +01:00
Clownacy
87e8a75df4 Rename GLFW3.h/SDL2.h 2020-04-04 19:18:46 +01:00
Clownacy
7f6574117d Clean-up SDL2 controller backend 2020-04-04 19:14:40 +01:00
Clownacy
e00ad1cd78 Shuffle code 2020-04-04 19:04:56 +01:00
Clownacy
d957c40649 Fix bug 2020-04-04 19:04:20 +01:00
Clownacy
659f89ea85 Cleanup and proper deinitialisation 2020-04-04 19:03:19 +01:00
Clownacy
e874b75357 Comment GLFW3 code, restore some vanilla behaviour 2020-04-04 18:55:44 +01:00
Clownacy
0cf1a781b7 Add hotplugging support to the GLFW3 backend
The GLFW windowing backend supports window-resizing, so I don't think
it's wrong to add enhancements to the backend code. It's not like the
SDL2 backend emulates DirectDraw's unstable framerate or anything.
2020-04-04 18:38:56 +01:00
Clownacy
b72b631e95 Simplify GLFW code 2020-04-04 17:47:45 +01:00
Clownacy
39ddfd9791 Abstract-away keyboard input
Now, instead of keyboard input being completely-handled in the
backend, it's merely abstracted, while still otherwise being handled
in the game itself. This will be useful for the enhanced branch's
key-rebinding menu.
2020-04-04 17:42:56 +01:00
Clownacy
c2f6ccdeb6 Merge branch 'accurate' into portable 2020-04-04 01:49:39 +01:00
Clownacy
bd280414ea Cleanup 2020-04-04 00:43:06 +01:00
Clownacy
5d37391882 Document bullets a little 2020-04-04 00:13:20 +01:00
Clownacy
90714cb7a4 Apply some missing BOOL constants 2020-04-03 23:16:40 +01:00
Clownacy
264d555073 Forgot to CTRL-F goddammit 2020-04-03 18:51:43 +01:00
Clownacy
1543521625 Fix more errors x_x 2020-04-03 18:36:48 +01:00