Clownacy
76e4fb5e8a
Improve MSVC6 hacks
2020-03-14 14:08:25 +00:00
Clownacy
c6b77fb015
Move the windows.h include to the right place
2020-03-14 13:25:25 +00:00
Clownacy
8a3b5c1f7a
Use macros instead of __stdcall
...
Wow Microsoft's documentation sucks: it constantly omits these,
making you think they're just plain `__cdecl`.
2020-03-14 13:22:36 +00:00
Clownacy
4e0a168533
Move the MSVC6 hacks to WindowsWrapper.h
...
Now the wrapper has a purpose again, and it keeps things neat.
2020-03-14 12:55:22 +00:00
Clownacy
05fb5cf106
Fix build error with MinGW
2020-03-13 22:01:02 +00:00
Clownacy
406ff18909
Add CMakeLists.txt and Visual Studio 6 support
...
The CMake file allows you to compile the accurate branch with
whatever version of Visual Studio you have lying around, without
having to clumbsily convert the VS2003 project.
I've tested this with VS2019, VS2003, and VS6. VS6 is goofy - it's
missing a few types and constants, and it's not smart enough to
realise that ints and longs are the same in ILP32 data models. I've
added a few small hacks to address this. Might undo them. Who knows.
For now, I want to support VS6 because Mint compiled CSE2 with it
before, and because VS6 uses `msvcrt.dll` as its C runtime, which
apparently comes pre-installed in Windows, as opposed to all those
other annoying runtime versions that require they be installed
separately (which is why MinGW targets it specifically).
Also, VS6 *should* give us Win95-compatible builds. The internet says
MSVC2003 is Win95-compatible too, but Mint claims the vanilla EXE
doesn't run on there. I imagine it has something to do with its
static runtime library (VS2003 links the static one by default for
some reason).
2020-03-13 21:35:51 +00:00
Clownacy
39c1d92947
CMakeLists.txt - Wrap paths in ""
2020-03-05 15:16:17 +00:00
Clownacy
27d82e9762
Set STB_IMAGE_STATIC
...
Reduce global namespace clutter.
...Man, I wish other single-header-file libs had an option like this
- this is a big part of why the new miniaudio backend's been causing
so many problems lately.
2020-03-05 00:04:47 +00:00
Clownacy
d57850d937
Fix Windows miniaudio build... again
2020-03-04 21:51:22 +00:00
Clownacy
9af25f7c67
Hopefully fixed miniaudio backend on Windows
...
Stupid BOOL type
2020-03-04 21:02:17 +00:00
Clownacy
156c01e672
Rename RENDERER and AUDIO_BACKEND
...
Now they're BACKEND_RENDERER and BACKEND_AUDIO
2020-02-29 18:33:32 +00:00
Clownacy
72672e142d
Makefile/CMakeLists.txt fixes
2020-02-29 18:19:06 +00:00
Clownacy
15bf7e095a
Add AUDIO_BACKEND option to readme
2020-02-29 18:19:06 +00:00
Clownacy
af24d010a5
Clean-up miniaudio backend a little
...
Really need to figure out the best way to abstract-away the software
mixer...
2020-02-29 18:19:06 +00:00
Clownacy
a943e80b1a
Add miniaudio audio backend to Makefile
...
Also made the CMake file link the libs miniaudio needs
2020-02-29 18:19:06 +00:00
Clownacy
14735caac3
Mark CMake target thingies as private
2020-02-29 18:19:06 +00:00
Clownacy
8ec8a8d990
Added unfinished miniaudio audio backend
...
Currently only works with CMake
2020-02-29 18:18:59 +00:00
Clownacy
934054806e
Merge branch 'accurate' into portable
2020-02-25 17:56:17 +00:00
Clownacy
e4a20a983e
Similar fixes
2020-02-20 15:59:04 +00:00
Clownacy
ed97e374f8
Fix screen centering in wide/tallscreen
...
Previously, it would misbehave if the screen is slightly wider than the level
(because it wasn't accounting for the fact that the game hides half of the
border tiles)
2020-02-20 13:11:39 +00:00
Gabriel Ravier
b238bcee03
Remove random lines mistakenly added by merge
2020-02-14 08:27:07 +01:00
Gabriel Ravier
d59df30005
Removed OpenMP stuff
2020-02-13 19:55:39 +01:00
Gabriel Ravier
5bd70eb2db
Removed ATTRIBUTE_OPTIMIZE from MakePixelWaveData
...
Signed-off-by: Gabriel Ravier <gabravier@gmail.com>
2020-02-13 19:55:39 +01:00
Gabriel Ravier
5d61641415
Added ATTRIBUTE_HOT to Backend_ColourFill
...
Signed-off-by: Gabriel Ravier <gabravier@gmail.com>
2020-02-13 19:55:39 +01:00
Gabriel Ravier
f43bd4f876
Removed bad omp (it doesn't actually improve anything, i did my measurements wrong)
2020-02-13 19:55:39 +01:00
Gabriel Ravier
2adfef0035
Got Backend_Blit to go from 17% CPU usage to 11% :
...
- used __builtin_expect to get a 8.5% performance improvement
- used #pragma omp for to get a 30% performance improvement
Signed-off-by: Gabriel Ravier <gabravier@gmail.com>
2020-02-13 19:55:39 +01:00
Gabriel Ravier
e8ec6a8ffb
Optimize Backend_Blit a bit
2020-02-13 19:55:39 +01:00
Gabriel Ravier
6ccfe063ce
Made MakePixelWaveData use ffast-math
2020-02-13 19:55:39 +01:00
Gabriel Ravier
65db12baaa
Started trying to optimize MakePixelWaveData
2020-02-13 19:55:39 +01:00
Clownacy
a7f1d80a06
Fix compilation with modern Visual Studio
2020-02-13 18:16:01 +00:00
Clownacy
a767c16d83
Un-un-const a few things
2020-02-09 18:55:41 +00:00
Clownacy
f82a53d336
Prevent errors encountered by MSVC
2020-02-09 18:47:50 +00:00
Clownacy
d4004fe99a
Store glyph pixels as chars, not floats
...
Smaller memory footprint, and probably-insignificant performance
impact.
2020-02-09 13:56:45 +00:00
Clownacy
bb11cd567d
Software renderer cleanup
2020-02-09 13:44:02 +00:00
Clownacy
60d3cc2ed6
Update cute_spritebatch.h
2020-02-09 12:40:35 +00:00
Clownacy
8edca4fb2e
Style tweak
2020-02-09 12:35:38 +00:00
Gabriel Ravier
81d672e158
Fixed a bunch of npc->cond = 0 bugs
2020-02-06 11:52:49 +01:00
Clownacy
f0206600b1
Travis: Exclude macOS Make OpenGLES2 build too
...
OpenGLES2 is also apparently in a different location
2020-02-06 09:21:45 +00:00
Clownacy
0902b9e35d
Merge branch 'accurate' into portable
...
I'm not going to add the FIX_BUGS and JAPANESE thing yet because we
have too many Travis jobs as it is.
2020-02-05 21:07:34 +00:00
Clownacy
fd19806eaf
Travis: Add FIX_BUGS and JAPANESE to matrix
...
Also changed it to only produce release builds
2020-02-05 21:05:20 +00:00
Clownacy
2b2965721f
Group jobs by build system
2020-02-05 21:01:07 +00:00
Clownacy
4737a7cbca
Travis: Only create release builds
2020-02-05 20:59:08 +00:00
Clownacy
6bbe0c977f
Explain the macOS OpenGL job exclusion
2020-02-05 20:52:30 +00:00
Clownacy
1478d2510b
Shut up a Travis warning
2020-02-05 20:45:44 +00:00
Clownacy
fe5291bce5
Uhh... now?
2020-02-05 20:41:11 +00:00
Clownacy
1575fbf908
Er... does this make it work?
2020-02-05 20:37:18 +00:00
Clownacy
f06b78bd38
Exclude macOS OpenGL3 Make builds from Travis
...
Apparently Apple handles OpenGL in a completely non-standard way.
2020-02-05 19:06:37 +00:00
Clownacy
425051a3cf
Make Travis build every rendering backend
...
I wonder if GLES2 is available on MacOS...
2020-02-05 16:02:44 +00:00
Clownacy
59a8c2617f
Tweak some variable naming
...
The enhanced branch calls them the 'internal *screen* width/height',
which I think is more appropriate.
2020-02-05 15:52:43 +00:00
Clownacy
d9e7ebac38
Correct a typo
2020-02-05 15:47:26 +00:00