Commit Graph

3425 Commits

Author SHA1 Message Date
kimci86
0d6a5f7fbe Make the new doxygen clipboard feature work and look good
CSS rules copied from doxygen default stylesheet generated with:
    doxygen -w html new_header.html new_footer.html new_stylesheet.css
2024-05-09 09:41:07 +02:00
kimci86
7f27cad9ae Fix search.js "Uncaught ReferenceError: Cookie is not defined" 2024-05-09 09:41:07 +02:00
Lukas Dürrenberger
66c5fae7c1 Fix XHTML Doxygen docs inconsistencies 2024-05-09 09:41:07 +02:00
Lukas Dürrenberger
891e567346 Fix missing namespace and file references 2024-05-09 09:41:07 +02:00
Lukas Dürrenberger
8d88e633e5 Update doxygen input file for doxygen 1.10.0 2024-05-09 09:41:07 +02:00
Lukas Dürrenberger
d95f99acf1 Fix configuration conflict in doxygen 1.10.0 2024-05-09 09:41:07 +02:00
Chris Thrasher
0777ce5ead Update to Catch2 v3.6.0 2024-05-07 17:02:47 +00:00
vittorioromeo
415668cb82 Update 'stb_image' to 2.29 2024-05-07 09:52:29 +02:00
Chris Thrasher
67fae8a301 Work around stalled Android CI job 2024-05-07 08:13:34 +02:00
vittorioromeo
ae269e1149 Make 'Event.inl' self-contained 2024-05-06 04:44:28 +00:00
Chris Thrasher
2d9cc54242 Work around failing network test on Android x86_64 API 24 2024-05-06 03:16:05 +00:00
binary1248
2386653bd3 Add GitHub actions support for running x86, x86_64 and arm64-v8a Android tests using an Android emulator. 2024-05-04 17:22:12 +00:00
binary1248
4daeac6459 Fall back to stdio when performing file input on Android without an activity. 2024-05-04 17:22:12 +00:00
trustytrojan
ca0a231b35 Add operator bool() to sf::Event for checking if the event type is not Empty 2024-05-03 22:50:59 +00:00
Andrei
9534c000f6 Added missing \param field from sf::Keyboard::getDescription(Scancode code) in docs 2024-05-03 07:25:50 +00:00
Chris Thrasher
b7c526efc2 Fix API documentation bugs 2024-05-03 01:36:55 +00:00
Chris Thrasher
59447dd8e5 Rewrite sf::Event API to improve type safety
This new API is built on top of std::variant. This allows us to
store many different event types in a space-efficient way and access
the active event type in a type-safe manner that eliminates the
categories of UB that are possible with unions.

Co-authored-by: kimci86 <kimci86@hotmail.fr>
2024-05-01 18:00:58 +00:00
Andrei
b447d41c6e Updated readme to point to SFML 2.6.1 2024-04-30 00:46:27 +00:00
Chris Thrasher
73126c93a3 Use std::optional to express functions that may not return a value 2024-04-29 19:09:39 +00:00
kimci86
71395e746e Define SoundStream::NoLoop as constexpr instead of enum 2024-04-28 16:36:57 +00:00
kimci86
bdd348c142 Make Sound::Status a scoped enumeration 2024-04-28 16:36:57 +00:00
Chris Thrasher
04c36fdd1a Improve const correctness 2024-04-27 23:33:52 +00:00
Chris Thrasher
1d95c65526 Prohibit use of malloc 2024-04-27 21:46:06 +00:00
Chris Thrasher
eb9c84309f Unify TODO comment style for better searchability
Continuing precedent set in b199cc6
2024-04-27 19:21:14 +00:00
Chris Thrasher
249caa2fb2 Require that variables are initialized 2024-04-27 19:20:52 +00:00
Lorenzooone
174448f5fa Fix joystickButton being used for Joystick(Dis)Connected event 2024-04-26 15:13:29 +02:00
Chris Thrasher
5da286487a Address clang-tidy-18 warnings on Linux 2024-04-26 00:07:27 +00:00
binary1248
c0ca39ed21 Added Sound Effects example. 2024-04-25 10:24:11 +02:00
binary1248
34fde883b9 Replaced OpenAL with miniaudio.
Co-authored-by: Chris Thrasher <chrisjthrasher@gmail.com>
Co-authored-by: kimci86 <kimci86@hotmail.fr>
Co-authored-by: vittorioromeo <mail@vittorioromeo.com>
2024-04-25 10:24:11 +02:00
binary1248
b0e45cfaba Moved libatomic linking to upper level CMakeLists.txt since it applies to multiple modules.
Co-authored-by: Chris Thrasher <chrisjthrasher@gmail.com>
2024-04-25 10:24:11 +02:00
Chris Thrasher
ebf916edf8 Refactor ternary into early-returning conditionals
Continuing precedent set in ef5ee38
2024-04-23 10:57:44 -06:00
Chris Thrasher
a05daa62b7 Use more C++17 inline variables 2024-04-23 09:35:46 -06:00
Chris Thrasher
f5a9def56e Silence new clang-tidy-18 checks 2024-04-23 09:49:36 +02:00
Chris Thrasher
4315c3d290 Revert change to Drawable::draw function signature
This change was made in 359fe90 due to recommendations from tooling.
On its face this change makes sense since it removes a copy that
isn't always necessary. In practice it caused ergonomic issues due
to now being forced to make a copy of the render states when needed.

The performance gains of eliding this copy are unsubstantiated. We
have not done any profiling to measure its impact. For lack of such
measurements I'd rather err on the side of improved user experience.
If future benchmarks prove this copy is rather expensive then we
can reconsider removing it with that evidence in mind.
2024-04-18 13:18:49 +02:00
Chris Thrasher
d6e1961112 Ensure struct data members are given an initial value
While I don't suspect there are any uninitialize variable bugs
present, it's still good to err on the side of safety and provide
an initial value nonetheless.
2024-04-16 19:14:38 -06:00
Chris Thrasher
95a23c2d05 Add type trait tests for sf::SoundFileWriter
Other Audio module types get this same treatment so we ought to
also have a .test.cpp for this header.
2024-04-16 17:05:42 -06:00
Chris Thrasher
cb651c063c Add tests for sf::SoundFileReader 2024-04-16 17:05:42 -06:00
Chris Thrasher
7bb97a85b1 Compile unit tests for iOS and Android
While you can't easily run these unit tests, it's easy enough to
still compile them so we don't need to go out of way to prohibit
this. CMake has some support for running tests on the target OS
so perhaps in the future we find a compelling way to run the test
suite on a mobile OS.
2024-04-13 11:49:45 -06:00
Chris Thrasher
30fcb3523c Use loadIntoMemory 2024-04-12 11:49:11 -06:00
Lukas Dürrenberger
8ccf534993 Revert disabling brew update 2024-04-12 10:25:35 -06:00
binary1248
7e1765717a Fixed coverage data not being collected for MinGW builds because OpenCPPCoverage relies on pdb data being available. 2024-04-11 17:32:24 -06:00
Chris Thrasher
b17150d3c0 Disable code coverage upload in forks 2024-04-11 16:08:32 -06:00
Chris Thrasher
efcfaf06fb Improve test coverage 2024-04-11 12:59:06 -06:00
Chris Thrasher
d31dad8300 Define sf::Shader move operations for OpenGL ES backend 2024-04-11 12:59:06 -06:00
binary1248
90fb07066b Replaced Codecov with Coveralls. 2024-04-11 10:46:27 -06:00
Chris Thrasher
6eaf300918 constexpr-fy sf::priv::Vector4 2024-04-11 09:05:28 -06:00
Chris Thrasher
f1bdacb57f Add tests for sf::Glsl types 2024-04-10 20:39:20 -06:00
Lukas Dürrenberger
e3b7d87373 Update Catch2 to v3.5.4 2024-04-10 19:17:11 -06:00
Lukas Dürrenberger
a742b2158f Allow failure of coverage uploads due to rate limits 2024-04-10 23:40:32 +02:00
Lukas Dürrenberger
2b6194a632 Switch back to Codecov GitHub Action with our own token 2024-04-10 23:40:32 +02:00