Commit Graph

462 Commits

Author SHA1 Message Date
Ryan C. Gordon
0b24c2f06c Merge pull request #50 from Manuel-K/gcc-6.1.1-fix
fix compilation errors with gcc 6.1.1 on Arch Linux
2016-05-24 00:55:35 -04:00
Ryan C. Gordon
be4c22f7e2 Merge pull request #44 from DanielGibson/misc-impr
Fix tons of compiler warnings
2016-05-24 00:54:46 -04:00
Manuel K
ba8d82efaf fix compilation errors with gcc 6.1.1 on Arch Linux 2016-05-22 01:17:19 +02:00
Daniel Gibson
7b470d30ab Elemental.es/Computer.cpp changes according to @SLAwww's suggestions 2016-05-11 19:04:01 +02:00
Daniel Gibson
7e7ab3e70e remove FIXMEs in GameMP/Computer.cpp
and replace the corresponding conditions with more readable (but
equivalent) ones.
2016-05-09 18:51:04 +02:00
Daniel Gibson
b64df456b6 Fix TFE warnings and lots of unused variable warnings
.. still, didn't look at unused variable warnings from *.es because
so many are generated.
2016-05-09 18:51:04 +02:00
Daniel Gibson
de4f96d208 Remove FIXMEs/silence Fish.es warnings
Thanks to @SLAwww's explanations it's clear now :)
2016-05-09 18:51:04 +02:00
Daniel Gibson
8106aedd9f Use at least 16bit for Depth-Buffer (fixes #37)
Seems like on Windows 0 bits is handled as "Let Windows/Driver decide",
so handle that case by setting a reasonable value of 16.
2016-05-09 18:51:03 +02:00
Daniel Gibson
40213b3e03 Ignore some more files (build dirs and generated) 2016-05-09 18:51:03 +02:00
Daniel Gibson
1bfc6d5d81 Fix "unused but set variable" warnings from GCC 2016-05-09 18:51:03 +02:00
Daniel Gibson
dbe524f0b2 Fix more warnings, mostly about logical op parenthesis (TSE only)
except for EntitiesMP/Fish.es which I'm not sure about, and in
Computer.cpp the weird "if (_iActiveMessage < _acmMessages.Count()==0)"
construct whichs intention I didn't fully grasp, either.
2016-05-09 18:51:03 +02:00
Daniel Gibson
72edf1c720 Commented out unused functions and variables
many unused functions and variables are now commented out

You'll still get tons of warnings, which should mostly fall in one of
the following categories:
1. Unnecessary variables or values generated from .es scripts
2. Pointers assigned to from functions with side-effects: DO NOT REMOVE!
   Like CEntity *penNew = CreateEntity_t(...); - even if penNew isn't
   used, CreateEntity() must be called there!
2016-05-09 18:51:03 +02:00
Daniel Gibson
bee4102374 Fix several warnings, warn if not using depth buffer
Fixed -Wreorder warnings (hopefully the last?), also several potentially
uninitialized variables.

In SetupPixelFormat_OGL() Assert if gap_iDepthBits ends up being 0.

Small adjustments to cmake warning settings for gcc/clang
2016-05-09 18:48:39 +02:00
Daniel Gibson
c58328d881 RSBinToGroups() use __builtin_clz() instead of manual bsr if available
should be faster.
2016-05-09 18:48:39 +02:00
Daniel Gibson
46353ffc5d make BYTESWAP*_unsigned() macros inline functions, use GCC builtins
the builtins are only used when using GCC or clang, of course, otherwise
the usual shifting is done.

Them being inline functions instead of macros increases type safety
and gets rid of problems with signed shifts.

Changed two places in the code that swapped bytes in 32bit ints to use
BYTESWAP32_unsigned() instead - in case of PrepareTexture() this has
probably even fixed issues with signed shifts
2016-05-09 18:48:39 +02:00
Ryan C. Gordon
a8c6c77309 Merge pull request #47 from notaz/asm_rework
Asm rework
2016-05-09 12:03:16 -04:00
Tan Wang Leng
577373f91e Fix casing for ModExt.txt
Some file systems are case-sensitive, so use proper casing.
2016-05-05 13:47:02 +08:00
Tan Wang Leng
b42612e8fb Remove ModExt.txt symlink
Does not work on Mac and Windows, and git unable to deal with
file thrashing with another file of similar name.
2016-05-05 13:38:57 +08:00
notaz
ce46bd1e99 make cpuid work on x86_64
not that it's used for anything, just for the logs
2016-04-25 00:14:30 +03:00
notaz
ff57a29e0f make separate option for using nasm asm
Other asm is now enabled by default again, since asm blocks are now
smarter and won't fail to compile on non-i386 platforms.
2016-04-25 00:14:29 +03:00
notaz
1f70d4e242 rework asm to always fall back to portable C code
with this there is no need to worry about x86 asm switch for other
platforms.
2016-04-25 00:14:29 +03:00
notaz
78b26698ac only enable __GNU_INLINE_X86_32__ for x86/IA32
also don't error out if both __MSVC_INLINE__ and __GNU_INLINE_X86_32__
are not set, we have C fallbacks now
2016-04-25 00:14:10 +03:00
notaz
4b5cc03bf0 rename __GNU_INLINE__ to __GNU_INLINE_X86_32__
There is not only x86 in this world.
Simple sed job.
2016-04-25 00:13:37 +03:00
Joshua Scoggins
056d77f479 Assume OSX if we have defined __APPLE__ (#46) 2016-04-23 20:04:45 -04:00
ptitSeb
3e0171ea1b Tried some asynchronus input method, but doesn't seems to works 2016-04-23 19:13:55 +02:00
ptitSeb
45429a88d8 Some Pandora fine-tunning 2016-04-23 19:13:54 +02:00
ptitSeb
16d6cb99fa Added some Failsafe. Fixed a crash in the new game intro cinematic (when Boss of TFE die and Sam goes to the UFO) on the Pandora 2016-04-23 19:13:53 +02:00
ptitSeb
6bb2f81134 fix Inverted Right and Middle button on certain case with SDL 2016-04-23 19:13:52 +02:00
ptitSeb
86ef2fee09 Restrict the Eps precision change only to Pandora platform 2016-04-23 19:13:44 +02:00
ptitSeb
07e64e787e Don't regulate Framerate on Pandora 2016-04-23 19:13:17 +02:00
Tan Wang Leng
4db3022cbd Fix mouse wheel for switching weapons
This fixes #32. Strictly follows the Win32 version.
2016-04-23 19:12:28 +02:00
ptitSeb
b6d54121a5 Restrict the Eps precision change only to Pandora platform 2016-04-23 18:56:18 +02:00
ptitSeb
90e408e02c Don't regulate Framerate on Pandora 2016-04-23 18:55:14 +02:00
Tan Wang Leng
65d8d44f0e Fix mouse wheel for switching weapons
This fixes #32. Strictly follows the Win32 version.
2016-04-23 10:49:07 -04:00
ptitSeb
dca5b7a6ac Merge branch 'master' of https://github.com/ptitSeb/Serious-Engine
Conflicts:
	Sources/Engine/Base/Types.h
	Sources/Engine/Engine.h
2016-04-22 23:04:19 +02:00
ptitSeb
bbb184aad7 More macro for UNIPTR_MAX 2016-04-22 22:03:07 +02:00
ptitSeb
df3592c88c Need __STDC_LIMIT_MACROS macro here too 2016-04-22 22:03:06 +02:00
ptitSeb
c15a2ce2b3 Nedd __STDC_LIMIT_MACROS for *_MAX constant to be defined 2016-04-22 22:03:06 +02:00
ptitSeb
c6415f84b5 Don't regulate Framerate on Pandora 2016-04-22 22:03:05 +02:00
ptitSeb
e1921174d4 Restrict the Eps precision change only to Pandora platform 2016-04-22 22:03:05 +02:00
ptitSeb
c32b7cc829 fix Inverted Right and Middle button on certain case with SDL 2016-04-22 22:03:04 +02:00
ptitSeb
b4e43fac95 Lower Epsilonon Pandora 2016-04-22 22:03:03 +02:00
Joshua Scoggins
88a0ec269b Use stdint.h everywhere since Serious Engine requires MSVC 2013 or greater (#40) 2016-04-22 13:57:32 -04:00
Rohit Nirmal
cb3f3bf521 Use those other averages. (#41) 2016-04-22 13:57:04 -04:00
Ryan C. Gordon
7213794459 Merge pull request #38 from DanielGibson/fix-FloatToInt
Fix for FloatToInt
2016-04-21 23:00:03 -04:00
Ryan C. Gordon
10395909e8 Merge pull request #39 from notaz/asm_fixes
Asm fixes
2016-04-21 22:46:07 -04:00
Daniel Gibson
1f23f37b36 CMakeLists.txt: suppress some warnings also for gcc, not only clang
also, check for AppleClang, not only Clang.
2016-04-22 04:27:29 +02:00
Daniel Gibson
c74fa69bf6 gcc told me copysignf() in FloatToInt() didn't do anything. oops.
sometimes using GCC *does* find problems clang didn't :)
2016-04-22 04:27:29 +02:00
notaz
52c178718c fix SoundMixer asm
SoundMixer386.asm forgot to save some callee-save registers too
2016-04-22 02:29:47 +03:00
notaz
b1837c2e58 fix Graphics asm
same stuff as in previous commit
2016-04-22 02:29:30 +03:00