1
0
forked from 0ad/0ad
Commit Graph

2316 Commits

Author SHA1 Message Date
f0a008c821 Refactor NONCOPYABLE to remove unneeded semicolons. Remove visibility keywords that were hidden in the macro. Patch by echotangoecho.
Reviewed By: Itms
Differential Revision: https://code.wildfiregames.com/D481
This was SVN commit r19626.
2017-05-21 13:11:07 +00:00
7c88529b45 Call std::terminate() instead of throwing in a destructor.
We don't catch this specific exception, so no behavioural change, but we
do no longer violate the implicit noexcept for destructors in C++11.
(Fixes a GCC6 and VS2015 warning.)

Reviewed By: Itms
Differential Revision: https://code.wildfiregames.com/D416
This was SVN commit r19612.
2017-05-19 17:48:43 +00:00
51f7502bb1 Don't move temporaries, so possibly allowing for copy elision.
Pointed out by clang's -Wpessimizing-move.

Reviewed By: wraitii
Differential Revision: https://code.wildfiregames.com/D421
This was SVN commit r19559.
2017-05-11 23:24:54 +00:00
36a16a4576 Remove debug breakpoint that is triggered whenever an unsupported UTF32 character is encountered,
for example when someone would send a lobby chat message containing such
a character, it effectively ended the game of the recipients.

Differential Revision: https://code.wildfiregames.com/D456
Fixes #4433
Reviewed By: leper
Reported and tested by: Hannibal_Barca
This was SVN commit r19540.
2017-05-08 22:29:00 +00:00
c5ab9925d4 Fix possible null dereferences.
Reviewed By: vladislavbelov
Differential Revision: https://code.wildfiregames.com/D420
This was SVN commit r19532.
2017-05-08 02:41:23 +00:00
09e974e1cb Bump year number of files changed this year in the license headers.
This was SVN commit r19503.
2017-05-01 14:28:22 +00:00
6ee830068a Print the name of OpenGL errors when they occur.
Patch by vladislavbelov
Differential Revision: https://code.wildfiregames.com/D313
This was SVN commit r19496.
2017-05-01 07:19:39 +00:00
584ccd690e Remove lib/pointer_typedefs.h. Patch by echotangoecho.
Reviewed By: Itms, leper
Differential Revision: https://code.wildfiregames.com/D83
This was SVN commit r19184.
2017-01-29 00:06:28 +00:00
8fec942e8a Fix Atlas under macOS Sierra.
We were polling SDL messages from two different threads (by mistake),
and Sierra now refuses to do that.
Tested by Stan, Itms, Fatherbushido, and discussed with Philip for the
code change itself.
Fixes #4408.
Differential Revision: https://code.wildfiregames.com/D42
This was SVN commit r19160.
2017-01-21 09:54:08 +00:00
4068f2e14a Fix warning with GCC in our lowlevel PNG texture code.
Ensure a variable is not clobbered by libpng's use of longjmp. Make code
more consistent.

Differential Revision: https://code.wildfiregames.com/D35
This was SVN commit r19111.
2017-01-04 21:05:08 +00:00
417c84870c Actually remove trailing tabs from source/.
This was SVN commit r18991.
2016-11-23 14:09:58 +00:00
6149dd3841 Actually remove trailing whitespace for non-header files as well.
This was SVN commit r18989.
2016-11-23 13:02:58 +00:00
944ba16eb4 End source files with a newline.
This was SVN commit r18988.
2016-11-23 11:27:54 +00:00
b18f74da44 Remove trailing whitespace and whitespace in empty lines of source/ except source/third_party/.
This was SVN commit r18987.
2016-11-23 11:18:37 +00:00
12ad190a51 Allow .Deleted to work on directories. Fixes #2641. Patch by leper.
This was SVN commit r18916.
2016-11-10 22:52:39 +00:00
b9a6d2af16 Use the debugger output on Windows for invalid parameter tests (see bd9bc6db78).
This way, the test output is not polluted by the error messages when
running in debug mode.

This was SVN commit r18608.
2016-08-15 12:15:19 +00:00
bcbf25bfbd Fix line endings of all files in source/ except source/third_party/.
This was SVN commit r18558.
2016-07-25 09:07:45 +00:00
f4e69b7c07 Cleanup of #3255, fixes #3966.
Don't create an empty oos_logs directory when starting the game.
Rename getDateIndexSubdirectory to createDateIndexSubdirectory.
Add a comment for the breakpoint argument of CreateDirectories.

This was SVN commit r18183.
2016-05-16 00:56:07 +00:00
c9cecab0be Remove libjpeg. Fixes #2828.
Based on patch by dalerank, tested on Windows, might need to be amended
for OSX.

This was SVN commit r17870.
2016-03-12 18:15:04 +00:00
a32ed75bff Fix a race-condition when two games have been started simultaneously and attempt to create the same replay directory, refs #3255.
Instead of triggering a debug-breakpoint, print a warning to stdout and
succeed in the N'th retry when having started N processes
simultaneously.
Previously the problem had been addressed by using the processID in the
directory name.

This was SVN commit r17776.
2016-02-19 11:22:32 +00:00
48ba4d9cb4 Updates precompiled win32 SDL libs to 2.0.4 from libsdl.org.
Fixes windows build with SDL 2.0.4, fixes #3138, #3225

This was SVN commit r17658.
2016-01-17 23:11:37 +00:00
c33d1e3741 Remove commented out code and comments invalid since 9542ecdd7e.
This was SVN commit r17647.
2016-01-13 22:39:09 +00:00
89aef0b6eb Cinematic camera core functionality. Patch by Vladislav Belov.
Based on existing code that was still around from an old(not working)
implementation.
Supports basic control from trigger scirpts (queue, start and stop
camera paths) and works in multiplayer.

This was SVN commit r17594.
2016-01-03 12:41:04 +00:00
9a2d0f803e Remove disabled by default SDL1 support.
Refs #2041.

This was SVN commit r17470.
2015-12-14 10:52:21 +00:00
5b2738b0cb Doubles size of sound card string buffers, for users with many sound devices present. Fixes #3660
This was SVN commit r17365.
2015-12-02 22:41:17 +00:00
6f09803e8c TerrainTextureManager file loading rewrite. Fixes #3358.
Add directory callback to vfs::ForEachFile.
Each terrain directory should now have a terrains.xml file,
as using the previous terrains.xml file is unlikely to be what was
intended.

This was SVN commit r17341.
2015-11-30 20:12:12 +00:00
c0b4e78801 Fixes stream serialization bug on OS X 10.8 and older, which caused instant OOS in multiplayer games, fixes #3108.
Fixes test failures on OS X 10.7 and older, refs #3109

This was SVN commit r17133.
2015-10-15 03:31:30 +00:00
36c6b50944 Revert emplace for associative containers. Fixes #3366.
GCC < 4.8.0 does not support emplace for those.
See https://gcc.gnu.org/bugzilla/show_bug.cgi?id=44436.

This was SVN commit r16922.
2015-08-19 03:32:47 +00:00
674f49f1a8 Remove generated test files during clean-workspaces.sh. Patch by otero. Fixes #3275.
Also remove two generated and disabled test files.

This was SVN commit r16921.
2015-08-19 01:30:09 +00:00
217a500d60 Add missing license headers. Fixes #3357.
This was SVN commit r16903.
2015-07-31 11:28:14 +00:00
c5aad60776 Actually stop iterating if retval != INFO::OK. Also fix comments.
This was SVN commit r16900.
2015-07-30 21:50:58 +00:00
15a4c813d6 Add support for AArch64 (ARM64). Patch by tbm. Fixes #3345.
This was SVN commit r16899.
2015-07-30 19:52:55 +00:00
8bfe16cac8 Use in-place construction.
This was SVN commit r16894.
2015-07-29 23:44:17 +00:00
bd53e9d736 Remove unused ah_translate code.
This was SVN commit r16881.
2015-07-27 01:08:15 +00:00
caa8f51c2e Annotate custom assert for clang-analyzer.
This was SVN commit r16800.
2015-06-21 18:46:23 +00:00
e5727980da Adds debug output to display return code of failing SHGetFolderPathW, refs #3267
This was SVN commit r16688.
2015-05-27 02:02:32 +00:00
487d6a1afc When using SDL2 recommend a >= 2.0.2 version to avoid incurring in possible bugs with older versions.
This was SVN commit r16585.
2015-04-27 07:56:34 +00:00
b6bcfdbb2e Fixes missing newlines in debug_printf, patch by elexis, fixes #3056
This was SVN commit r16534.
2015-04-12 19:38:31 +00:00
cf527707da Revert "Improve ARRAY_SIZE." (7afaacda19).
constexpr and noexcept are only supported by VS November 2013 CTP.

This was SVN commit r16508.
2015-04-06 21:24:53 +00:00
7afaacda19 Improve ARRAY_SIZE.
This was SVN commit r16499.
2015-04-05 16:50:26 +00:00
89107d1406 Fixes grayscale PNG handling, there is no need to convert them all to RGB and 4741e896c4 broke special font texture handling. Instead, only grayscale with alpha PNGs will be converted to RGBA (they fail to load otherwise).
Removes warning about converting grayscale textures, refs #1640.

This was SVN commit r16449.
2015-03-19 03:04:01 +00:00
4741e896c4 Improves handling of PNG textures based on GdkPixbuf's setup_png_transformations. The PNG decoder should now support grayscale, RGB or indexed color; bit depth up to 16; and interlacing. Fixes #1640, refs #2823, #3082
This was SVN commit r16439.
2015-03-16 02:28:00 +00:00
b1c4e29ac8 Fixes inconsistencies in spelling of colour/color by preferring "color" (only wxWidgets remains with some API that requires "colour"), fixes #1029.
NOTE: requires update-workspaces and may require correction of some
modded actors/scenarios

This was SVN commit r16438.
2015-03-15 23:59:48 +00:00
e41ec77eb6 Remove unused file.
This was SVN commit r16417.
2015-03-15 04:16:31 +00:00
7fe9eb956f Fixes error in SMBIOS::InitStructures by not warning on invalid header size, fixes #2985
This was SVN commit r16374.
2015-02-22 00:42:11 +00:00
e48e330db7 Sets SDL2 as default and only build option on Windows.
Removes remnants of WSDL. Refs #2041

This was SVN commit r16357.
2015-02-20 05:52:18 +00:00
a5e940430f Suppresses libpng warning "iCCP: known incorrect sRGB profile" by manually handling warning messages (errors still use default handler), fixes #2184
This was SVN commit r16350.
2015-02-17 10:50:19 +00:00
49222a4c6a Fix Windows build
This was SVN commit r16334.
2015-02-14 02:22:22 +00:00
e06a7b37d8 Convert debug_printf to take UTF-8 strings instead of wchar_t.
This fixes the problem where passing a non-ASCII string to
debug_printf(L"%hs", s) caused vswprintf_s to fail on Linux (because it
doesn't know what encoding the char* is meant to have). Now debug
messages will remain as UTF-8 until they reach the OS.

Fixes #3021.

This was SVN commit r16332.
2015-02-14 01:45:13 +00:00
4473ed5c88 glext_funcs: Support glMapBuffer, glMapBufferRange
This was SVN commit r16231.
2015-01-25 16:36:23 +00:00
4c1903500b Switch to std::shared_ptr and std::weak_ptr.
This was SVN commit r16227.
2015-01-25 03:10:58 +00:00
0843100d11 Remove partial emulation of some C++11 features for older compilers.
This was SVN commit r16226.
2015-01-24 20:37:18 +00:00
0261d12727 Remove some checks for usupported VS versions (<2013).
This was SVN commit r16225.
2015-01-24 20:37:16 +00:00
fc902df07c Remove checks for unsupported GCC versions (<4.6).
This was SVN commit r16224.
2015-01-24 20:37:07 +00:00
67956f969e Make ARRAY_SIZE(pointer) complain in GCC, not just in MSVC.
The ArraySizeDeducer trick has worked since at least GCC 4.4, so it's
fine to rely on it now.

This was SVN commit r16218.
2015-01-24 17:35:25 +00:00
de25e536c3 Update NONCOPYABLE to use C++11 "=delete".
This gives slightly better error messages.

This was SVN commit r16217.
2015-01-24 17:33:49 +00:00
3ce38e536e Update cassert to use C++11 static_assert.
This gives clearer error messages, and simplifies the code.

This was SVN commit r16216.
2015-01-24 17:29:19 +00:00
8f0ace2658 Make Android %ls/%hs workaround work on secure_crt as well as wsecure_crt.
Refs #2996.

This was SVN commit r16210.
2015-01-24 00:22:12 +00:00
4d4ddb5978 Add workaround for Android libc++ swprintf bug.
Based on patch by BogDan. Refs #2996.

This was SVN commit r16209.
2015-01-24 00:20:15 +00:00
c9dee72667 GLES doesn't have glDisable(GL_TEXTURE_2D).
Patch by BogDan. Refs #2996.

This was SVN commit r16206.
2015-01-23 20:40:02 +00:00
ad3e330861 Workaround for limitations of Android's vswprintf implementation.
Based on patch by BogDan. Refs #2996.

This was SVN commit r16203.
2015-01-23 20:38:13 +00:00
65cc47f6c0 Deletes unused bundled MSVC runtime libs for old 2005 and 2008 versions.
Removes VC80 manifest info.

This was SVN commit r16199.
2015-01-23 03:21:48 +00:00
f350a24c73 Disable "assignment operator could not be generated" warning globally on Windows, since it's never useful.
This was SVN commit r16192.
2015-01-22 21:09:33 +00:00
d7926eb612 Add basic tests for %s/%hs/%ls in sprintf_s, swprintf_s.
This was SVN commit r16191.
2015-01-22 20:39:53 +00:00
ef2a358f87 Remove sys_vswprintf.
The implementation on Windows was gross. The only user was CLogger,
which no longer uses it.

Also fix vswprintf_s to handle truncated output correctly (by returning
"") on Linux, now that CLogger is no longer relying on the buggy
behaviour.

This was SVN commit r16190.
2015-01-22 20:39:28 +00:00
b90bc147c9 Add Path::string8 (which returns a UTF-8 encoded std::string).
This saves the hassle of writing utf8_from_wstring(path.string()) in
places like log messages, and can be extended to better handle
non-ISO-8859-1 paths on Linux.

This was SVN commit r16185.
2015-01-22 20:33:11 +00:00
49e2ecea63 Automatically convert all CLogger format strings from wchar_t* to char*.
Done with:

  ag -ls 'LOG(MESSAGE|MESSAGERENDER|WARNING|ERROR)' source | xargs sed
-i 's/LOG\(MESSAGE\|MESSAGERENDER\|WARNING\|ERROR\)(L/LOG\1(/g'

This was SVN commit r16183.
2015-01-22 20:31:30 +00:00
dcf5a2667f CLogger: Use cppformat instead of sys_vswprintf.
sys_vswprintf relies on platform-specific printf implementations, which
vary widely between platforms (in handling of truncation, return values,
use of %s/%S/%hs/%ls for mixing char and wchar_t strings, etc) and are
therefore a pain.

Use cppformat's fmt::sprintf instead, which has very similar syntax to
sprintf but is more C++ish and is portable.

Also, wchar_t is stupid, so use char* strings (which are expected to be
UTF-8) in CLogger. This creates a bit of a pain with changing all
callers to convert to char* strings, but that's their fault for not
using UTF-8 already.

Refs #3011.

This was SVN commit r16182.
2015-01-22 20:30:05 +00:00
e1e163b3f7 Improve ogl_WarnIfError() to report the file/line where the error was detected
This was SVN commit r16164.
2015-01-19 20:06:16 +00:00
b74e853144 Fix typo which caused GLES errors
This was SVN commit r16163.
2015-01-19 20:04:46 +00:00
7e0e566346 Fix typo in include. Refs #2086.
This was SVN commit r16018.
2014-12-03 16:43:51 +00:00
759a6701f6 Fix test build.
The parser that extracts the methods to call does not care about
defines.

This was SVN commit r16013.
2014-11-29 21:26:01 +00:00
504e23acb8 Make some things static.
This was SVN commit r15997.
2014-11-20 22:19:33 +00:00
335ac3d0cb Query /proc for the executable path on Linux. Patch by starslayer. Refs #2086.
Factor out unix_ExecutablePathname() which is used by BSDs and Linux (as
a fallback).

This was SVN commit r15996.
2014-11-20 22:19:21 +00:00
f4b5054815 Fix valgrind warning about uninitialized variable. Patch by Echelon9. Fixes #2878.
This was SVN commit r15936.
2014-11-08 00:37:42 +00:00
6334ee3f8b Reverts 03eaf9b461 due to licensing issues (source/lib is MIT licensed) and replaces with compatible FreeBSD/clang-based solution, patch by pstumpf. Refs #2675
This was SVN commit r15890.
2014-10-18 20:45:11 +00:00
03eaf9b461 Fixes cpuid to work with i386 CPUs and PIE/PIC, based on old GCC cpuid.h source and patch by pstumpf, fixes #2675
This was SVN commit r15886.
2014-10-18 03:07:24 +00:00
227d828b67 Updates Windows version strings for 8.1 and 10 (technical preview)
This was SVN commit r15869.
2014-10-14 21:37:19 +00:00
4753a0c1c2 Replace usage of "GUIs" in cxxtest with the command line,
and extend that to support -libdir <dir> and -disabled. Fixes #2488.

This was SVN commit r15795.
2014-09-24 15:35:31 +00:00
d62e3729d5 Improves SDL2 support, includes patch by yashi and fabio, refs #2041:
* Adds SDL color cursor implementation
* Adds config option for choosing preferred display in multimonitor
setup
* Uses text input API to better handle CJK input
* Fixes various hotkey and input bugs

SDL 1.2 is still the default and recommended, to test experimental SDL2
support, pass the --sdl2 flag to update-workspaces

This was SVN commit r15767.
2014-09-20 12:12:35 +00:00
0f0f4f7b03 Fixes crash on OS X if dir_watch_Poll is called during init before dir_watch_Add, refs #2427, #2650
This was SVN commit r15748.
2014-09-14 00:27:38 +00:00
689272d4bd Remove collision in global namespace.
Fixes config/vfs deadlocks on OSX.

This was SVN commit r15504.
2014-07-09 19:16:03 +00:00
343066040f Remove inconsistent checks for pSimulation2 when saving maps and ensure that it is set.
Remove commented out code writing triggers that has nothing to do with
the actual triggers implementation.
Free memory that was allocated for error reporting when when fork()
fails.
Remove dead initialization.

This was SVN commit r15477.
2014-07-01 19:00:41 +00:00
59b2493990 Missed changes from 304a7c1201
This was SVN commit r15458.
2014-06-28 05:50:32 +00:00
190f3b0ce1 Exclude .git dirs when adding subfolders to the VFS.
This was SVN commit r15373.
2014-06-15 17:06:24 +00:00
85e2e72eb7 Fix TestHeaderless failure on GCC 4.9.
Once 'delete' is called on an object, that object no longer exists, and
accessing its member variables is undefined behaviour. GCC 4.9's
optimiser recognises this, and eliminates any writes to member variables
inside the destructor, since it knows they cannot legally be read later.

BoundaryTagManager relied on ~FreedBlock resetting its memory to 0, so
this optimisation broke it. Replace the placement new/delete with plain
non-magic Setup/Reset functions, to avoid the optimisation.

Fixes #2481.

This was SVN commit r15334.
2014-06-11 19:50:38 +00:00
fb0b4572ab Fix Valgrind complaint about delete vs delete[].
This was SVN commit r15267.
2014-06-01 18:46:14 +00:00
59c9ae670f Stop VFS from causing a crash when the AI player isn't found. Patch by Itms. Fixes #2558
This was SVN commit r15254.
2014-05-31 14:55:09 +00:00
85a1f880ab Fix compatibility with LLVM libc++ (used on OS X).
libc++ vector asserts that allocator::value_type is correct, so we have
to pass in the correct types.

This was SVN commit r15231.
2014-05-26 16:48:28 +00:00
d2ecbecf32 Fixes tex_codec typo that broke BMP writing and big screenshots, fixes #2515
This was SVN commit r15107.
2014-05-04 05:49:31 +00:00
8fea36cdd0 Made tinygettext’s debug output optional
You can now enable tinygettext’s output from the user.cfg file
(tinygettext.debug).
This enhancement also solved a warning due to the previous workaround,
which was
to uncomment the output line to avoid the debug messages.

This issue was reported by Yves at Github:
https://github.com/leper/0ad/issues/10

This was SVN commit r15002.
2014-04-26 15:32:18 +00:00
fc793609eb Added API documentation to ‘source/i18n/’
This was SVN commit r14996.
2014-04-26 12:10:15 +00:00
1b3261b8f4 Added third-party libraries for internationalization and localization: ICU and tinygettext
This was SVN commit r14951.
2014-04-20 19:17:32 +00:00
e9e05f4efc Second (main) commit for the SpiderMonkey upgrade.
This commit contains all the required changes to our source files and
build scripts (hopefully).
A next commit will remove the old stuff of SpiderMonkey 1.8.5.

Spcial thanks to:
 - H4writer who helped a lot mainly with the performance issues we
had/have, but also with other problems or questions.
 - Leper for the review.
 - Historic_bruno for implementing the build scripts on Mac OS X and
testing on the Mac.
 - The people from the #jsapi channel and from
mozilla.dev.tech.js-engine who answered a lot of questions and helped
solving problems.
 - All the other people who helped

Refs #1886
Fixes #2442
Fixes #2416

This was SVN commit r14877.
2014-03-28 20:26:32 +00:00
6ab578a6eb Fix out of date comments in Tex and ITexCodec, Fixes #2458.
This was SVN commit r14838.
2014-03-13 19:00:22 +00:00
ef888367aa Cleanup tex_codec, fixes #2456, patch by IronNerd.
This was SVN commit r14836.
2014-03-13 04:16:20 +00:00
a5639631ee Texture system refactoring and cleanup, fixes #2455, patch by IronNerd.
This was SVN commit r14835.
2014-03-13 02:37:05 +00:00
035078c317 Disables checks in os_cpu_LargePageSize Windows implementation, since they failed on Vista SP2 with old Xeon CPU, fixes #2346
This was SVN commit r14731.
2014-02-04 22:30:29 +00:00
0406c89908 Implements GetMonitorSize for OS X, patch by Echelon9, fixes #2390
This was SVN commit r14690.
2014-01-26 23:03:45 +00:00
3746690f82 Define GLX_MESA_query_renderer functions unconditionally. Fixes #2325.
This was SVN commit r14432.
2013-12-29 17:13:55 +00:00
9dcc3ee89e fix always picking the same processor core on some systems. Based on code hits by Philip
This was SVN commit r14391.
2013-12-26 10:05:44 +00:00
42bc5165ab Add compile time flag to disable use of miniupnpc.
This was SVN commit r14384.
2013-12-18 16:08:56 +00:00
8db3ada87f Improves debugging output to help troubleshoot some WSDL bugs, refs #2146, #1733
This was SVN commit r14325.
2013-12-10 18:54:18 +00:00
b1c081e36d Set svn:eol-style=native, fix some inconsistent line endings
This was SVN commit r14299.
2013-12-06 00:42:50 +00:00
8ecfbd0899 Remove unused includes of tr1/unordered_map etc.
They cause build errors with libc++, and we always use
boost::unordered_map instead.

This was SVN commit r14177.
2013-11-14 20:47:59 +00:00
5771bee032 First pass at fixing GLES build - more to come
This was SVN commit r14149.
2013-11-12 01:17:16 +00:00
45a7f577d3 A bunch of OS X SDK-related fixes.
Adds runtime support for 10.5 APIs: display modes, bundle paths, system
paths, pasteboards. Previously this was compile-time support only, which
prevented building on later SDKs while targeting earlier APIs.
Adds hardcoded version for pre-10.6 builds, to avoid messing with
deprecated Gestalt or having to add a 10.5 non-dispatch singleton (Grand
Central Dispatch didn't exist in 10.5)

This was SVN commit r14140.
2013-11-11 00:11:25 +00:00
011cbb5725 Fixes OS X STL incompatibilities when building against later SDKs and targeting 10.5 (fixes stringstream build errors in these conditions)
This was SVN commit r14139.
2013-11-11 00:09:16 +00:00
a96ed190a5 Add GLX_MESA_query_renderer support to hwdetect
This was SVN commit r14130.
2013-11-10 16:24:03 +00:00
d178f32698 Fix Unicode in JS print() on Linux
This was SVN commit r14129.
2013-11-10 16:13:40 +00:00
35d48d2fe8 ...and increase HDATA_USER_SIZE so OglTex actually fits
This was SVN commit r14122.
2013-11-09 18:49:35 +00:00
1ad9d5424a Fix error at startup on 64-bit builds.
OglTex had a size_t added, which pushed it over HDATA_USER_SIZE.
Use u32 instead to minimise the difference between platforms.

This was SVN commit r14121.
2013-11-09 18:39:45 +00:00
9cc172b164 Fixes --without-lobby for MSVC and clang, refs #2249.
Cleans up some whitespace.
Removes obsolete PCH files.

This was SVN commit r14117.
2013-11-09 02:57:10 +00:00
3c47b12cbe Display texture memory usage in profiler's renderer stats
This was SVN commit r14116.
2013-11-09 01:03:23 +00:00
5dfc3746e3 Remove old and unused archive stats.
This was SVN commit r14114.
2013-11-08 17:27:21 +00:00
93cffe9deb Remove the old and no longer used archive builder that rebuilt the archive while the game is running.
This approach isn't used anymore. Now we start the archive building with
parameters to pyrogeneis.

Refs #2241 (the code used g_ScriptingHost which is going to be removed)

This was SVN commit r14102.
2013-11-07 21:06:18 +00:00
bffe917914 Multiplayer lobby based on the XmPP protocol. Special thanks to Philip, alpha123, scythetwirler, and anyone else who has helped build, debug or test the lobby.
This was SVN commit r14098.
2013-11-07 20:07:24 +00:00
b416de9b7c Remove the unused crypto++ library files.
This was SVN commit r14094.
2013-11-07 18:50:52 +00:00
29e4b1a17c Update Android support
This was SVN commit r14068.
2013-11-02 23:05:38 +00:00
2d1be3d47e Improve correctness of hotkeys at low framerates.
SDL queues up all the input events received in a frame. When the hotkey
system saw a key up/down event, it immediately updated its
HotkeyIsPressed state and then pushed a hotkey event onto the end of the
queue.

If the initial queue was e.g. [key-down shift, key-press Z, key-up
shift], the hotkey event triggered by Z would be processed after the
key-up shift had updated the HotkeyIsPressed state, so the handler of
the Z hotkey would not think the shift hotkey was pressed.

If the initial queue was e.g. [key-press Z, mouse-click], the hotkey
triggered by Z would be processed after the mouse-click event, so it
could apply to the wrong building selection.

Fix by pushing the hotkey events onto a special queue that gets
processed before any subsequent SDL input events.

Also update the HotkeyIsPressed status when the HOTKEYDOWN/HOTKEYUP
events are processed, not when they are generated, to guarantee they are
consistent with the DOWN/UP events.

Fixes #1869.

This was SVN commit r14057.
2013-10-30 01:38:32 +00:00
a4cd90ddfc Avoid non-ASCII characters in source code, since tools don't decode them consistently.
Fixes #2198.

This was SVN commit r14035.
2013-10-20 09:27:44 +00:00
5778484a77 Refactor text renderer
Replace unifont with CFont and CFontManager, since the h_mgr interface
was
needlessly inconvenient.

Load the font textures through CTextureManager, to support dynamic
reloading (e.g. when resetting GL state - see #741).

Add CFontMetrics as a convenient wrapper for code that just wants to
measure text.

Fixes #1117.

This was SVN commit r14016.
2013-10-18 15:53:07 +00:00
8799bd98b0 Support 8bpp textures
When textures.xml specifies format="alpha", the input is expected to be
an
8-bit greyscale PNG, and the output will be an 8-bit uncompressed
alpha-only DDS.

Add format override to CTextureProperties, to select between e.g.
GL_ALPHA
and GL_LUMINANCE for 8-bit textures.

This is needed so fonts can use the new texture system.

This was SVN commit r14015.
2013-10-18 15:36:31 +00:00
e24ce51029 Adds DynamicArena allocator that grows by fixed chunk size, fixes #2142.
Changes fixed size arenas to new dynamic arenas with reasonable chunk
sizes (may require tuning), refs #1842

This was SVN commit r13916.
2013-09-30 01:22:44 +00:00
c2583e42da Reduce memory allocations in the renderer
Use an arena allocator in ShaderModelRenderer::Render, to reduce
the allocation cost in STL containers.

Avoid unnecessary copying of std::vectors.

This was SVN commit r13911.
2013-09-29 14:48:11 +00:00
2a613f8236 Removes mostly useless video memory detection, fixes another crash with Nvidia Optimus on Windows, fixes #2145, #2138
This was SVN commit r13891.
2013-09-22 18:07:33 +00:00
9694eec8b8 As per ticket #1707. Some minor improvements to spatial subdivision. Makes way for future changes in RangeManager.
Right now merely improves memory usage.

This was SVN commit r13854.
2013-09-15 14:03:53 +00:00
b1bd61938e add file notification to Mac ticket 514, also change name of class FileInfo to CFileInfo to ease Mac development
This was SVN commit r13821.
2013-09-10 14:17:04 +00:00
04ed87bf28 Display error messages instead of breaking into the debugger when we don't have rights to save a map in Atlas. Fixes #1941.
This was SVN commit r13818.
2013-09-09 23:31:22 +00:00
c1dcbe4176 update TLB table
refs #2074

This was SVN commit r13741.
2013-08-23 06:42:48 +00:00
0a0bd83cf0 Adds L4 cache detection for some new Haswell CPUs, fixes #2074
This was SVN commit r13736.
2013-08-21 23:18:35 +00:00
f947fa6afe Fixes stack overflow in stack dump logic, by special-casing boost::unordered types, fixes #1813.
Adds INIT_HAVE_DISPLAY_ERROR init flag to correctly override
ah_display_error in Atlas (InitVfs was overriding it again), but don't
use it because it's ugly and broken, refs #1729

This was SVN commit r13724.
2013-08-20 21:07:42 +00:00
93abbae435 Fix build issues on ARM. Patch by Josh. Fixes #2049.
This was SVN commit r13634.
2013-08-07 05:00:46 +00:00
d1af7ea0ef Include mod path in the cache path.
This was SVN commit r13546.
2013-07-10 00:08:01 +00:00
8aa016a884 Changes graphics card name detection on Windows to use OpenGL, as a workaround for certain WMI related crashes on Nvidia Optimus and netbook systems. Fixes #1952, #1575
This was SVN commit r13536.
2013-07-06 18:30:29 +00:00
02b98f3acd Fixes build with x11 and SDL2
This was SVN commit r13485.
2013-06-17 01:43:57 +00:00
e75877b52f Adds comment about xorg-x11's glXGetProcAddress not returning NULL for unsupported functions, closes #171
This was SVN commit r13480.
2013-06-14 23:49:20 +00:00
2567fee329 Write mod data correctly. Fixes #1940.
This was SVN commit r13472.
2013-06-11 20:50:09 +00:00
b3391ebe39 Fix build warnings. Patch by Markus. Refs #1851.
This was SVN commit r13469.
2013-06-11 00:05:57 +00:00
d2b0d25457 Fixes macro redefinition of FACILITY_VISUALCPP in VC2012 (it's defined in winerror.h).
Removes obsolete hack for old Boost and VC2005 (broke VC2005 build with
modern Boost).

This was SVN commit r13433.
2013-05-28 01:14:41 +00:00
a8a968d32c Catch exceptions by reference (by convention), based on patch from Markus, refs #1852
This was SVN commit r13421.
2013-05-22 22:27:53 +00:00
284e9cd230 Improves frame rate counter to give smoother results, patch by sbte. Fixes #1016
This was SVN commit r13204.
2013-02-26 21:50:38 +00:00
2f19cf86d3 Fix mod priority. Add user mod support. Fixes #1838.
This was SVN commit r13167.
2013-02-14 00:40:02 +00:00
3e8bdebc6d Add Clang detection and add BSD to the collected stats.
This was SVN commit r13111.
2013-01-23 16:01:17 +00:00
c037e3f78e Add detection of Win8 in wversion, to help stats collection
This was SVN commit r13100.
2013-01-21 20:32:07 +00:00
d65c7751a5 Updates bundled libpng to v1.5.13, built with VC2008 - requires update-workspaces. Refs #864
This was SVN commit r13035.
2013-01-03 17:22:14 +00:00
276f0a41a0 New Year's clean-up.
Throw a warning if a invalid (not present) AI is specified in a map.
Replace the last occurences of jubot with qbot.
Exclude the common siege templates from the Units Demo map.
Fix an error with flying units.
Replace CFG_GET_SYS_VAL with CFG_GET_USER_VAL and rename it to
CFG_GET_VAL to reflect its behaviour better.
Fix linker error with clang 3.2. Refs 1588.
Remove some useless includes.

This was SVN commit r13031.
2013-01-01 18:33:53 +00:00
e91a918164 Fixes race condition in EnsureMonotonic on 32-bit builds, which was causing unreliable timer behavior, fixes #1729
This was SVN commit r12927.
2012-12-03 13:24:12 +00:00
9d0da11eab Fixes compile error introduced in 3787f17e4d
This was SVN commit r12909.
2012-12-01 20:34:35 +00:00
308db6627a fix synchronization of TimerState (refs #1729)
This was SVN commit r12908.
2012-12-01 06:33:30 +00:00
3787f17e4d merge with local codebase: fix PopulationCount
This was SVN commit r12907.
2012-12-01 03:06:24 +00:00
9001cba02c fix: remove unnecessary failure check concerning window class atom. fixes #1729
This was SVN commit r12906.
2012-12-01 02:34:19 +00:00
1fb7889539 Postproc manager
This was SVN commit r12755.
2012-10-15 10:34:23 +00:00
5cff74f4e7 Replaces FAM file monitoring with inotify on Linux, based on patch by noKid. Fixes #1316, refs #1687.
Removes FAM dependency.

This was SVN commit r12726.
2012-10-02 00:03:14 +00:00
fcf09598d9 Temporarily disabling FAM for Alpha 11 because it can cause problems on Ubuntu and hotloading doesn't seem to work anyway at the moment.
Known problems with FAM:
- System hangs at shutdown
- Assertion failure at startup in debug mode

This was SVN commit r12550.
2012-08-29 21:22:57 +00:00
e485fb9e2c Implements copy/paste for OS X using NSPasteboard including pre-10.6 API support. Fixes #1326
This was SVN commit r12464.
2012-08-18 19:47:55 +00:00
011ba8255e New sound system implementation by stwf, refs #1223, #961.
Enables audio on OS X, refs #685, #931.
Fixes music not playing after a game, refs #946.

This was SVN commit r12428.
2012-08-15 00:10:44 +00:00
20d75a3880 Free cursors before shutting down SDL. Fixes #1355.
This was SVN commit r12271.
2012-08-03 16:48:02 +00:00
2c8adb1aea Adds support for Boost.Filesystem v3, the only option in Boost 1.50. Fixes #1527. Refs #1360
This was SVN commit r12229.
2012-07-29 23:04:22 +00:00
574f4db8ab Fixes font texture handling to use format auto-detection when possible, based on patch by Deiz/F00. Fixes #1508
This was SVN commit r12073.
2012-07-05 01:05:09 +00:00
637c09b204 Add support for OpenBSD. Fixes #1463.
Backport os_getversion from premake4.4-beta4 and extend it to support
POSIX-compilant systems.
Add some missing newlines at the end of file as these cause warnings on
OpenBSD.
Update the config paths.

This was SVN commit r11970.
2012-06-13 20:43:56 +00:00
fbc3cbad7c Fix handling of non-ASCII paths on Unix
This was SVN commit r11839.
2012-05-11 14:30:15 +00:00
37a5bedb81 Adds partial support for Debian GNU/kFreeBSD, based on patch by vincent. Refs #1322.
This was SVN commit r11781.
2012-05-07 01:53:35 +00:00
vts
490182ddd0 Wall placement. Closes #786.
This was SVN commit r11760.
2012-05-05 19:22:22 +00:00
ffc89ee1af Adds some OS X availability macros to support 10.5 SDK. Not foolproof but good enough for now.
This was SVN commit r11757.
2012-05-05 03:18:22 +00:00
b101f5ad01 Adds hardware cursors for Linux and OS X. Requires libxcursor on Linux. Fixes #748.
Adds explicit links to frameworks we need on OS X.

This was SVN commit r11596.
2012-04-21 07:53:53 +00:00
769350a3e7 Compute camera height and zoom limits based on smoothed terrain heightmap. Fixes #794, based on patch by Dietger.
This was SVN commit r11556.
2012-04-18 20:39:00 +00:00
ce215cace3 Add support for custom vertex attributes and array-of-matrix uniforms in GLSL.
This was SVN commit r11489.
2012-04-12 14:10:02 +00:00
0fda0019d1 Updates data paths on OS X and Windows. On OS X only write to locations inside ~/Library. On Windows make the distinction between local and roaming appdata, and use folder inside My Documents for user-created data. Fixes #1145.
Adds proper OS X app bundle support.
Updates Windows installer script.

This was SVN commit r11389.
2012-03-22 00:23:31 +00:00
36107cb7e1 GLES compatibility for particles and shadows.
Fix invalid enum errors.
Fix shader texture binding.

This was SVN commit r11372.
2012-03-19 21:10:14 +00:00
8c6231f940 Fix black-square cursor on 16bpp Windows
This was SVN commit r11371.
2012-03-19 20:46:12 +00:00
6fc508f662 Fix non-PCH build.
Fix typo.

This was SVN commit r11327.
2012-03-13 21:39:01 +00:00
2afc4d9d8f Fix #1140 (signedness warning on some platforms).
This was SVN commit r11251.
2012-03-05 17:05:02 +00:00
7fa6afac37 Corrects some Doxygen comments and adds a few others of interest.
This was SVN commit r11209.
2012-03-01 03:55:05 +00:00
5009636e39 Improve Android compatibility.
Basic touchscreen input for testing.
Better GLSL support for map rendering.

This was SVN commit r11155.
2012-02-25 17:29:27 +00:00
4c43d1f9c5 Fixing building with older versions of Boost
This was SVN commit r11083.
2012-02-16 18:01:10 +00:00
7656ffa265 Be more informative about errors in CreateDirectories
This was SVN commit r11082.
2012-02-16 13:50:31 +00:00
832a51da80 GLSL text support
This was SVN commit r11080.
2012-02-15 21:53:13 +00:00
20d23eb340 Sysdep code for Android/ARM
This was SVN commit r11075.
2012-02-15 15:40:31 +00:00
f4625e69af Partial Android compatibility.
Remove unnecessary VM allocation (which seemingly causes problems on
Android due to mmap during static initialization).
Allow building without NVTT.

This was SVN commit r11074.
2012-02-15 13:58:58 +00:00
9972eb8cae Enough GLES compatibility to reach the menu screen
This was SVN commit r11064.
2012-02-13 20:53:24 +00:00
677ccf53e6 Yet more GLES compatibility
This was SVN commit r11061.
2012-02-13 16:41:17 +00:00
a9eca31bad Even more GLES compatibility
This was SVN commit r11060.
2012-02-13 15:06:25 +00:00
4bf59b9a7d More GLES compatibility, mainly around terrain rendering.
This was SVN commit r11059.
2012-02-13 14:02:14 +00:00
baff889321 Fix invalid varargs
This was SVN commit r11054.
2012-02-12 21:05:13 +00:00
531b40578a More GLES compatibility.
Add config option to disable hardware cursors on Windows.

This was SVN commit r11053.
2012-02-12 20:45:31 +00:00
db85833655 More GLES compatibility.
Move more rendering code to shader API.

This was SVN commit r11050.
2012-02-12 13:20:49 +00:00
a3f168b887 Initial support for GLSL generic vertex attributes in shader API, for GLES compatibility.
Specify GLSL version in shader files, for better error detection.

This was SVN commit r11040.
2012-02-09 17:55:25 +00:00
3fab2729b5 Partial SDL2 compatibility
This was SVN commit r11033.
2012-02-06 22:47:35 +00:00
0f4928bd0a Use dummy IO tracer, to avoid overhead of storing data that will never be used. (See #1143.)
This was SVN commit r11007.
2012-02-02 23:12:36 +00:00
41e3bad341 More build fixes for FreeBSD.
Adds BSD sysdep.
Adds support for MAKE variable, overriding make command in our build
scripts.
Fixes more files not ending with newline.

This was SVN commit r10994.
2012-01-31 00:06:56 +00:00
5cdb2ebd70 Fix cursor winding
This was SVN commit r10992.
2012-01-30 12:13:43 +00:00
fc27a5c0ea More FreeBSD build fixes.
Fixes some warnings about files that don't end with newline.

This was SVN commit r10991.
2012-01-30 06:21:11 +00:00
cc5a0fba4e Use shader API for GUI text.
Flip GUI quads so we don't have to disable back-face culling.

This was SVN commit r10989.
2012-01-30 00:27:23 +00:00
8be430eb30 Remove obsolete ogl_shader
This was SVN commit r10984.
2012-01-29 12:23:16 +00:00
adbd7633dd # Initial GLSL rendering support
This was SVN commit r10978.
2012-01-29 01:22:22 +00:00
63e151fbd5 Slightly more Android compatibility
This was SVN commit r10975.
2012-01-28 16:38:21 +00:00
d068c1dd09 Fix build with old versions of Mesa
This was SVN commit r10936.
2012-01-19 18:23:54 +00:00
95e6673ed4 Fixes include in wsdl.
This was SVN commit r10932.
2012-01-18 22:51:49 +00:00
8099388bec final sync with work - add VECTOR_ALIGNED, fix wsdl to match new SDL include path
This was SVN commit r10926.
2012-01-18 15:36:44 +00:00