1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-04 12:00:25 +00:00
Commit Graph

1158 Commits

Author SHA1 Message Date
Thaddeus Crews
acdb8667b5 Core: Sidestep GCC false-positive 2025-10-17 18:57:34 -05:00
Thaddeus Crews
d1d28c0bcf Merge pull request #111223 from Ivorforce/remove-iterator-include
Replace `std::size` usage with `std_size` to avoid `<iterator>` include.
2025-10-06 09:06:49 -05:00
Lukas Tenbrink
ad600125df Rewrite HashMapHasherDefault based on type traits - it is now possible to declare a default hashing function for any type.
Remove cross-project includes from `hashfuncs.h`.
Improve hashing function for `Color` (based on values instead of `String`).
Move `Variant` comparison from `hash_map.h` to `dictionary.cpp` (`VariantComparatorDictionary`), where it's used.
Remove now unnecessary `HashableHasher`.
2025-10-05 01:49:11 +02:00
Lukas Tenbrink
1db0a60dc0 Replace std::size usage with std_size to avoid <iterator> include. 2025-10-05 00:26:11 +02:00
Thaddeus Crews
06827c91c6 Merge pull request #107839 from Rudolph-B/Occlusion-Culling-Optimization
Minor Optimization to Occlusion Culling
2025-10-03 12:01:13 -05:00
Thaddeus Crews
00f8f62be7 Merge pull request #106084 from Kaleb-Reid/fix-geometry-3d
Fix ghost collisions in segment_intersects_convex()
2025-10-03 12:01:02 -05:00
Mounir Tohami
081cebb2f7 Geometry2D minor optimization 2025-09-16 21:33:53 +03:00
Thaddeus Crews
c39edeca6d Merge pull request #109744 from Repiteo/core/math-constants-semantic
Core: Integrate semantic constants in math structs
2025-09-16 11:44:49 -05:00
Kaleb Reid
a2b9fc08e3 Fix ghost collisions in segment_intersects_convex() 2025-08-22 22:49:56 -07:00
Thaddeus Crews
84c0ec04f3 Core: Integrate semantic constants in math structs
- Excludes self-explanatory constants (ZERO, ONE, etc)
2025-08-19 10:15:08 -05:00
Rudolph Bester
56e04635a7 Minor Optimization to Occlusion Culling 2025-08-14 20:00:58 +02:00
Arti Chhabra
6a288c9275 Corrected the order of DiagonalMode in Add Property 2025-08-01 14:59:59 -07:00
Chaosus
610712a269 Add a way to filter neighbor points to AStar2D/3D 2025-07-28 13:25:02 +03:00
jsjtxietian
6f094856e7 Make get_id_path return empty when first point is disabled 2025-06-16 01:42:13 +02:00
Rémi Verschelde
6eb6e3e6e0 Merge pull request #107457 from akien-mga/improve-error-message-call-single-argument
Improve error messages for method calls expecting only 1 argument
2025-06-12 22:49:36 +02:00
Rémi Verschelde
d1083c9722 Improve error messages for method calls expecting only 1 argument 2025-06-12 17:02:59 +02:00
Lukas Tenbrink
b13a0e1834 Rename String::resize to resize_uninitialized, to better communicate to callers that new characters must be initialized. 2025-06-11 18:13:02 +02:00
Lukas Tenbrink
ed836df150 Make conversions from math types to String explicit, to avoid accidental conversions. 2025-06-09 01:58:18 +02:00
Zi Ye
b957cf73ef Optimized and exposed Basis::scaled_local. 2025-06-05 13:06:46 -05:00
retrotails
ae06a2de48 Revert some instances of Math::INF back to 1e20 2025-06-05 09:32:40 -04:00
Rémi Verschelde
61639d9574 Merge pull request #106996 from Ivorforce/no-oa-hashmap
Core: Remove `OAHashMap`, in favour of `AHashMap`
2025-06-05 13:12:34 +02:00
Aaron Franke
f6f1df7d73 Add 64-bit versions of core power of 2 functions 2025-06-01 23:11:12 -07:00
Lukas Tenbrink
963c20565b Remove OAHashMap, in favour of AHashMap.
The two types had (mostly) the same decisions, but `AHashMap` is a faster implementation, and is more consistent with `HashMap`.
2025-05-31 15:50:10 +02:00
Lukas Tenbrink
37415530d7 Un-support force_trivial parameter for LocalVector. Instead, users are reformatted to use resize_uninitialized to make it explicit that the resize does not initialize missing elements. 2025-05-27 18:43:36 +02:00
Lukas Tenbrink
ea6fbd6687 Use OkHSV for rainbow labels. 2025-05-22 22:53:32 +02:00
Thaddeus Crews
6c2d288ef1 Merge pull request #106337 from TokageItLab/arc-tolerance
Fix Quaternion arc constructor tolerance
2025-05-19 08:01:37 -05:00
Thaddeus Crews
5538850d87 Core: Convert Pair/KeyValue to constexpr 2025-05-15 10:37:41 -05:00
Silc Lizard (Tokage) Renew
37aca09b23 Fix Quaternion arc constructor tolerance 2025-05-14 07:15:12 +09:00
aaronp64
8fb3697916 Avoid single character String allocations when appending characters
Removed calls to String::chr() when appending characters to Strings in Expression, Resource, and VariantParser, to avoid creating temporary Strings for each character.  Also updated the Resource case to resize String up front, since size is known.
2025-05-12 17:35:42 -04:00
aaronp64
1089f61868 Fix RandomPCG::random(int, int) overflow bug
- Use int64_t for subtraction before converting to uint32_t
- Don't add one to uint32_t max value for rand() bounds
2025-05-06 17:54:12 -04:00
Thaddeus Crews
01fc9aee6c Core: Modernize C headers with C++ equivalents 2025-05-02 08:23:01 -05:00
Thaddeus Crews
3947cbe3b2 Merge pull request #104386 from Repiteo/core/cpp-math
Core: Replace C math headers with C++ equivalents
2025-04-27 19:21:22 -05:00
Lukas Tenbrink
7c37188ca1 Smoke test: In collections, log an error if reserve() is called with a number smaller than the current size. Don't log an error if it is called with a number smaller than the current capacity. 2025-04-23 16:47:47 +02:00
Thaddeus Crews
ad40939b6f Core: Replace C math headers with C++ equivalents
- Minor restructuring to ensure `math_funcs.h` is the central point for math functions
2025-04-16 15:49:02 -05:00
Marc Gilleron
5e6df6a196 Use Math::abs to avoid ambiguity with integer abs 2025-04-16 20:41:36 +02:00
Thaddeus Crews
29dcead192 Merge pull request #105394 from Zylann/quaternion_abs
Use Math::abs to avoid ambiguity with integer abs
2025-04-15 12:28:41 -05:00
Thaddeus Crews
53608e3376 Merge pull request #104239 from Ivorforce/optimize-undenormalize
Optimize reverb by removing stray `volatile` from the `undenormalize` function signature.
2025-04-14 19:39:46 -05:00
Marc Gilleron
40b5468c6d Use Math::abs to avoid ambiguity with integer abs 2025-04-14 23:54:07 +02:00
Thaddeus Crews
94282d88f9 Core: Use Math namespace for constants 2025-04-10 16:29:30 -05:00
MewPurPur
45b1071e7c Optimize Color.html() 2025-04-05 14:00:30 +03:00
Thaddeus Crews
207a2b6472 Core: Integrate warning suppression macro helpers 2025-04-03 10:13:46 -05:00
Thaddeus Crews
9f222d500d Merge pull request #104375 from YYF233333/is_empty
Replace `size() == 0` with `is_empty()`
2025-04-02 07:37:31 -05:00
Yufeng Ying
4f4031a675 Replace size() == 0 with is_empty(). 2025-04-02 19:18:43 +08:00
smix8
f2197a1013 Expose TriangleMesh api functions wrapped for scripting
Adds script wrapped TriangleMesh api functions to create and query the triangle BVH tree.
2025-04-02 09:52:35 +02:00
Thaddeus Crews
21956851ac Merge pull request #104885 from MewPurPur/html-validation-optimization
Optimize Color HTML validation
2025-04-01 19:53:32 -05:00
MewPurPur
250cc58388 Optimize HTML color validation 2025-04-01 21:26:21 +03:00
Aaron Franke
c1acc839a8 Directly use segment points in Geometry2D/3D function parameters 2025-03-30 16:25:59 -07:00
Thaddeus Crews
3b1a481f13 Merge pull request #97843 from detomon/optimize-a-star-grid-2d-solve
Reduce allocations when solving path in `AStarGrid2D`
2025-03-30 09:06:02 -05:00
Zae
e7f7823236 Fix reversed hex order in Color::to_html 2025-03-29 06:06:09 +08:00
Rémi Verschelde
10799d0b44 Merge pull request #104389 from Ivorforce/color-string-append
Optimize `Color::to_html` by allocating less.
2025-03-28 14:32:54 +01:00