Commit graph

747 commits

Author SHA1 Message Date
Rémi Verschelde 5d8025ec66
Merge pull request #38844 from hbina/patch-5
Avoid copying vector in constructor of PathMD5
2021-02-25 17:49:47 +01:00
Rémi Verschelde 049d654c49
Merge pull request #46354 from reduz/importer-defaults-editor
Added Import Defaults Editor in Project Settings
2021-02-24 13:19:05 +01:00
Rémi Verschelde 5a10f52ee8
Merge pull request #45914 from HenryWConklin/45841-xml-entities
Add support for numeric XML entities to XMLParser
2021-02-24 13:03:46 +01:00
reduz b6fce5d750 Added Import Defaults Editor in Project Settings
-Change importer defaults in project settings.
-Ability to change them or reset them.
2021-02-23 14:18:02 -03:00
Rémi Verschelde 0d1d719178 doc: Sync classref with current source
And fix various bogus bindings following previous PRs.
2021-02-19 14:39:14 +01:00
Rémi Verschelde 310496a89f
Merge pull request #45617 from RandomShaper/modernize_atomics
Modernize atomics (and fix `volatile`)
2021-02-18 19:40:31 +01:00
Pedro J. Estébanez 8e128726f0 Modernize atomics
- Based on C++11's `atomic`
- Reworked `SafeRefCount` (based on the rewrite by @hpvb)
- Replaced free atomic functions by the new `SafeNumeric<T>`
- Replaced wrong cases of `volatile bool` by the new `SafeFlag`
- Platform-specific implementations no longer needed

Co-authored-by: Hein-Pieter van Braam-Stewart <hp@tmm.cx>
2021-02-18 17:12:46 +01:00
reduz 64140eaf42 Reorganize Project Settings
-Advanced Settings toggle also hides advanced properties when disabled
-Simplified Advanced Bar (errors were just plain redundant)
-Reorganized rendering quality settings.
-Reorganized miscelaneous settings for clean up.
2021-02-18 11:23:34 -03:00
Henry Conklin c6a911f037 Add support for numeric XML entities to XMLParser
* Add support for decimal numeric entities to String::xml_unescape
* Add more error checks to String::xml_unescape
* Refactor XMLParser to use String::xml_unescape instead of an internal
implementation
2021-02-14 11:00:25 -06:00
reduz 5ae9051771 Add ability to change Icon Saturation
-Allows for more theme freedom
-Allows for entirely B&W themes.
2021-02-12 12:16:37 -03:00
reduz f8d03b98e7 Improve resource load cache
-Added a new method in Resource: reset_state , used for reloading the same resource from disk
-Added a new cache mode "replace" in ResourceLoader, which reuses existing loaded sub-resources but resets their data from disk (or replaces them if they chaged type)
-Because the correct sub-resource paths are always loaded now, this fixes bugs with subresource folding or subresource ordering when saving.
2021-02-11 15:44:28 -03:00
reduz 1aa2823fa3 Removed _change_notify
-For inspector refresh, the inspector now detects if a property change by polling a few times per second and then does update the control if so. This process is very cheap.
-For property list refresh, a new signal (property_list_changed) was added to Object. _change_notify() is replaced by notify_property_list_changed()
-Changed all objects using the old method to the signal, or just deleted the calls to _change_notify(<property>) since they are unnecesary now.
2021-02-10 19:31:24 -03:00
Gilles Roudière 25c4dacb88 Fixes crash when exiting with --verbose with leaked resources 2021-02-09 17:34:49 +01:00
Rémi Verschelde 5525cd85c6
Merge pull request #45315 from RandomShaper/modernize_thread
Modernize Thread
2021-01-31 15:24:56 +01:00
Pedro J. Estébanez 99fe462452 Modernize Thread
- Based on C++11's `thread` and `thread_local`
- No more need to allocate-deallocate or check for null
- No pointer anymore, just a member variable
- Platform-specific implementations no longer needed (except for the few cases of non-portable functions)
- Simpler for `NO_THREADS`
- Thread ids are now the same across platforms (main is 1; others follow)
2021-01-29 12:02:13 +01:00
Aaron Franke e829b7aee4
Unify URI encoding/decoding and add to C#
http_escape and percent_encode have been unified into uri_encode, and http_unescape and percent_decode have been unified into uri_decode.
2021-01-28 07:45:01 -05:00
Aaron Franke 1be0d6b30e
Type consistencies in core 2021-01-26 13:04:22 -05:00
Pedro J. Estébanez 8ed259b792 Modernize RWLock
- Based on C++14's `shared_time_mutex`
- No more need to allocate-deallocate or check for null
- No pointer anymore, just a member variable
- Platform-specific implementations no longer needed
- Simpler for `NO_THREADS`
2021-01-19 11:53:10 +01:00
Andrii Doroshenko (Xrayez) e94f46dcdb Expose Resource.emit_changed() to script
Also known as `emit_signal("changed")`.
2021-01-13 16:27:58 +02:00
Rémi Verschelde b5334d14f7
Update copyright statements to 2021
Happy new year to the wonderful Godot community!

2020 has been a tough year for most of us personally, but a good year for
Godot development nonetheless with a huge amount of work done towards Godot
4.0 and great improvements backported to the long-lived 3.2 branch.

We've had close to 400 contributors to engine code this year, authoring near
7,000 commit! (And that's only for the `master` branch and for the engine code,
there's a lot more when counting docs, demos and other first-party repos.)

Here's to a great year 2021 for all Godot users 🎆
2021-01-01 20:19:21 +01:00
Marcel Admiraal b4a190e0bc Consistently use normal_map 2020-12-29 08:04:19 +00:00
Marcel Admiraal 5b937d493f Rename empty() to is_empty() 2020-12-28 10:39:56 +00:00
Marcel Admiraal 2df9a8ccad Rename Rect2 and Rect2i clip() to intersection() 2020-12-19 12:59:08 +00:00
Theogen Ratkin 46ea6750b4 Add interpolation parameter to resize_to_po2()
Image::resize_to_po2() now takes an optional p_interpolation parameter
that it passes directly to resize() with default value INTERPOLATE_BILINEAR.
2020-12-18 14:05:07 -04:00
Rémi Verschelde f3dccf5891
Merge pull request #44393 from Calinou/add-stdout-flush-project-setting
Add a project setting to enable stdout flushing in release builds
2020-12-17 10:06:50 +01:00
Andy Savage c65f097ebd Quick fix to incorrect error messages when writing to compressed or encrypted files. 2020-12-15 17:00:39 +00:00
Hugo Locurcio 341b9cf15a
Add a project setting to enable stdout flushing in release builds
This can be used in server builds for journalctl compatibility.
2020-12-15 16:40:52 +01:00
Rémi Verschelde 9263f8eb4b
Image: Rename PVRTC{2,4} to PVRTC1_{2,4}, drop COMPRESS_PVRTC2
We haven't had a proper implementation for COMPRESS_PVRTC2 (which is PVRTC1 2-bpp) in years,
so let's drop it instead of keeping a compress type which doesn't work.

The other enum values were renamed to clarify that our PVRTC2 and PVRTC4 are respectively
PVRTC1 2-bpp and PVRTC1 4-bpp. PVRTC2 2-bpp and 4-bpp are not implemented yet.
2020-12-10 23:14:04 +01:00
Rémi Verschelde 114f97ff11
Merge pull request #44128 from KoBeWi/🧹
Cleanup unused engine code
2020-12-09 13:01:50 +01:00
Tomasz Chabora 2c048ea164 Cleanup unused engine code 2020-12-09 12:12:36 +01:00
Rémi Verschelde 0c5d3b838c
Merge pull request #44199 from bruvzg/pvs_fixes_1
PVS-Studio static analyzer fixes
2020-12-09 10:23:21 +01:00
bruvzg 644f739660
Static analyzer fixes:
Removes unused code in OS.
Fixes return types.
Fixes few typos.
2020-12-09 10:17:53 +02:00
Rémi Verschelde e5e1277ecd
Merge pull request #44161 from Faless/fix/fa_buffered_remove
Remove unused FileAccessBuffered
2020-12-09 09:14:14 +01:00
Hugo Locurcio 4d81776fc9
Tweak log file names for consistency between Mono and non-Mono logs
- Avoid spaces in Mono log file names.
- Use a `.log` extension for Mono logs, just like non-Mono logs.
- Use periods to separate hours/minutes/seconds for non-Mono logs.
2020-12-06 20:17:02 +01:00
Fabio Alessandrelli 781efc26e0 Remove now unused FileAccessBuffered. 2020-12-06 19:37:11 +01:00
reduz 70f5972905 Refactored Mesh internals and formats.
-Changed how mesh data is organized, hoping to make it more efficient on Vulkan and GLES.
-Removed compression, it now always uses the most efficient format.
-Added support for custom arrays (up to 8 custom formats)
-Added support for 8 weights in skeleton data.
-Added a simple optional versioning system for imported assets, to reimport if binary is newer
-Fixes #43979 (I needed to test)

WARNING:

-NOT backwards compatible with previous 4.x-devel, will most likely never be, but it will force reimport scenes due to version change.
-NOT backwards compatible with 3.x scenes, this will be eventually re-added.
-Skeletons not working any longer, will fix in next PR.
2020-12-02 13:07:59 -03:00
Fabio Alessandrelli 828d1ea59e
Merge pull request #40136 from Jummit/multiplayer-root-node-getters
Add root_node as property of MultiplayerAPI
2020-11-27 18:36:07 +01:00
Fabio Alessandrelli 4b6a35c74a Disable SO_REUSEADDR for UDP.
It allows binding multiple sockets to the same ADDR:PORT (unlike TCP,
which still requires different ADDR:PORT combinations).
2020-11-27 14:12:34 +01:00
Rafał Mikrut 7bd03b7188 Initialize class/struct variables with default values in core/ and drivers/ 2020-11-23 17:38:46 +01:00
Aaron Franke 2c53e8b0e9
Use Vector2i instead of Vector2 for Image get_pixelv and set_pixelv
Co-authored-by: Andrii Doroshenko <xrayez@gmail.com>
2020-11-21 02:42:29 -05:00
Pedro J. Estébanez e99cf6bfe5 Fix crash duplicating local-to-scene resources 2020-11-18 23:45:30 +01:00
Rémi Verschelde 386ee52978
Merge pull request #43610 from RandomShaper/fix_res_duplicate
Fix crash in resoure duplicate
2020-11-17 11:21:53 +01:00
Pedro J. Estébanez 9450717571 Fix crash in resoure duplicate 2020-11-17 10:13:41 +01:00
Aaron Franke 02161aad5a
Remove empty lines around braces with the formatting script 2020-11-16 23:38:11 -05:00
Fabio Alessandrelli efe3eaf6a4
Merge pull request #43493 from timothyqiu/request-absolute-authority
Allow HTTPClient to talk to a proxy server
2020-11-16 16:00:26 +01:00
Zae fa3e0bdd73 fix custom loader/saver broken 2020-11-15 22:14:06 +08:00
Haoyu Qiu d92ca6fbb1 Allows HTTPClient to talk to proxy server
* Makes request uri accept absolute URL and authority
* Adds Host header only when missing
2020-11-14 21:25:15 +08:00
reduz 5288ff538d Create Variant built-in functions.
-Moved Expression to use this, removed its own.
-Eventually GDScript/VisualScript/GDNative need to be moved to this.
-Given the JSON functions were hacked-in, removed them and created a new JSONParser class
-Made sure these functions appear properly in documentation, since they will be removed from GDScript
2020-11-10 19:31:10 -03:00
Rémi Verschelde 32464e569f
Merge pull request #40748 from RandomShaper/improve_packed_fs_api
Improve/fix packed data API
2020-11-10 10:59:34 +01:00
Rémi Verschelde 9d2e8f2f27
Variant: Rename Type::_RID to Type::RID
The underscore prefix was used to avoid the conflict between the `RID` class
name and the matching enum value in `Variant::Type`.

This can be fixed differently by prefixing uses of the `RID` class in `Variant`
with the scope resolution operator, as done already for `AABB`.
2020-11-09 16:29:04 +01:00