Rémi Verschelde
172b254687
Merge pull request #88664 from RandomShaper/res_load_modes
...
Enhance cache modes in resource loading
2024-02-29 13:54:07 +01:00
Rémi Verschelde
7462b1a0b2
Merge pull request #88561 from RandomShaper/res_load_safer
...
Improve thread safety of resource loading
2024-02-29 13:53:58 +01:00
Pedro J. Estébanez
84b85d894c
Improve thread safety of resource loading
2024-02-28 15:19:22 +01:00
Pedro J. Estébanez
5e144022e7
Enhance cache modes in resource loading
...
- Unify documentation, hoping to clear misconcepctions about about propagation of the cache mode across dependant loads.
- Clarify in docs that `CACHE_MODE_REPLACE` now also works on the main resource (from #87008 ).
- Add two recursive modes, counterparts of `CACHE_MODE_REPLACE` and `CACHE_MODE_IGNORE`, since it seems some need them (see #59669 , #82830 ).
- Let resources, even loaded with one of the ignore-cache modes, get a path, which is useful for tools.
2024-02-26 14:59:04 +01:00
Pedro J. Estébanez
851f1d49d7
Remove spammy dev-mode message about load deadlock prevention
2024-02-23 14:54:03 +01:00
Rémi Verschelde
eac054f1cc
Merge pull request #87971 from bruvzg/font_no_image_dup
...
[TextServer / Font] Do not duplicate images to prevent unnecessary embedding.
2024-02-15 17:35:36 +01:00
Muller-Castro
a8bc9f3e78
Add const lvalue ref to core/* container parameters
2024-02-14 11:20:36 -03:00
Rémi Verschelde
dc99c8d4a4
Merge pull request #87008 from KoBeWi/cache_mode_replace_fixes²
...
Fix² behavior of ResourceFormatLoader `CACHE_MODE_REPLACE`
2024-02-13 23:43:18 +01:00
Rémi Verschelde
b457a30311
Merge pull request #87628 from YuriSizov/assets-bigger-better-errors
...
Improve error reporting in the asset library and in related types
2024-02-09 18:09:16 +01:00
A Thousand Ships
684752e75b
Replace error checks against `size` with `is_empty`
2024-02-09 12:50:15 +01:00
bruvzg
19f1d5afa9
[TextServer / Font] Do not duplicate images to prevent unnecessary embedding.
2024-02-05 10:38:32 +02:00
vittorioromeo
71e0082ab0
Extract 'SafeBinaryMutex' to separate header
...
This change simply extracts 'SafeBinaryMutex' from 'mutex.h' to
'safe_binary_mutex.h', in an effort to reduce the compilation
speed impact of including `mutex.h`.
2024-02-04 16:59:54 +01:00
scgm0
2dae53c316
Explicitly initialize all of `FileAccess::create_func[ACCESS_MAX]`
2024-01-31 10:46:14 +01:00
Rémi Verschelde
3dfedd69ea
Merge pull request #87711 from matthew1006/threaded-loading-progress-fix
...
Fix `ResourceLoader.load_threaded_get_status` returning `[0]` constantly in exported projects.
2024-01-30 17:48:11 +01:00
Rémi Verschelde
b65c495d6e
Merge pull request #86845 from RandomShaper/no_load_regress
...
Avoid regressing in progress reporting in resource load
2024-01-29 21:33:00 +01:00
Matthew Edwards
7565d1f3ab
Push p_original_path into load_paths_stack and sub_tasks instead of p_path.
2024-01-29 17:27:57 +00:00
Yuri Sizov
815038962f
Improve error reporting in the asset library and in related types
...
This also makes errors related to asset image loading
verbose-only, because, frankly, users can't do much about
those errors. Spamming them with error messages
about some assets on the frontend being broken
is pointless.
2024-01-26 20:33:22 +01:00
ACB
2561f6fc52
Fix FileAccessMemory off by one error in eof_reached
2024-01-25 10:35:51 +01:00
Rémi Verschelde
0bcc0e92b3
Merge pull request #86730 from reduz/64-bit-cowdata
...
Promote CowData to 64 bits
2024-01-19 18:46:11 +01:00
Juan Linietsky
24fe0715b5
Promote CowData to 64 bits
...
Fixes a lot of bugs, please help me fill the list.
2024-01-19 17:41:10 +01:00
Rémi Verschelde
26b1fd0d84
Merge pull request #87029 from bruvzg/info_plist_keys
...
[macOS/iOS export] Add option to set custom Info.plist data.
2024-01-11 20:46:02 +01:00
bruvzg
491077239c
[macOS/iOS export] Add option to set custom Info.plist data.
2024-01-11 21:05:35 +02:00
RedMser
608b5d2e07
Fix recursive resource local to scene
...
Any resource that contains other local to scene resources inside of
arrays or dictionaries will now be duplicated and configured.
The case where a scene's node has an exported array/dictionary
property containing local to scene resources is NOT handled here.
2024-01-11 20:02:14 +01:00
Rémi Verschelde
ed0be57bff
Merge pull request #87062 from aaronfranke/exr-grayscale-false
...
Give EXR saving methods a default value of false like the bindings
2024-01-11 17:43:02 +01:00
Rémi Verschelde
dc79e956b6
Merge pull request #86587 from RandomShaper/wtp_enhance
...
Enhance & fix `WorkerThreadPool`
2024-01-11 17:38:09 +01:00
Aaron Franke
a120f11c1e
Give EXR saving methods a default value of false like the bindings
2024-01-10 15:53:40 -06:00
kobewi
2e09985c0d
Fix² behavior of ResourceFormatLoader CACHE_MODE_REPLACE
2024-01-09 16:01:37 +01:00
Rémi Verschelde
9ca3d3ec83
Revert "Fix behavior of ResourceFormatLoader `CACHE_MODE_REPLACE`"
2024-01-09 10:49:14 +01:00
Pedro J. Estébanez
9444d297ed
WorkerThreadPool: Overhaul scheduling and synchronization
...
This commits rewrites the sync logic in a way that the
`use_system_threads_for_low_priority_tasks` setting, which was added due to
the lack of a cross-platform wait-for-multiple-objects functionality, can be
removed (it's as if it was effectively hardcoded to `false`).
With the new implementation, we have the best of both worlds: threads don't
have to poll, plus no bespoke threads are used.
In addition, regarding deadlock prevention, since not every possible case of
wait-deadlock could be avoided, this commits removes the current best-effort
avoidance mechanisms and keeps only a simple, pessimistic way of detection.
It turns out that the only current user of deadlock prevention, ResourceLoader,
works fine with it and so every possible situation in resource loading is now
properly handled, with no possibilities of deadlocking. There's a comment in
the code with further details.
Lastly, a potential for load tasks never being awaited/disposed is cleared.
2024-01-08 12:45:42 +01:00
Pedro J. Estébanez
f5ca58d32f
Avoid regressing in progress reporting in resource load
2024-01-05 19:33:58 +01:00
Rémi Verschelde
d1b7c60afc
Merge pull request #77712 from nklbdev/Fix_lossless_formats_in_PortableCompressedTexture2D
...
Fix lossless formats in PortableCompressedTexture2D
2024-01-05 12:02:14 +01:00
nklbdev
47d991678d
Fix lossless formats in PortableCompressedTexture2D
...
Update scene/resources/portable_compressed_texture.cpp
Co-authored-by: Rémi Verschelde <rverschelde@gmail.com>
2024-01-05 00:11:01 +05:00
Rémi Verschelde
0fa767beff
Merge pull request #84508 from jsjtxietian/clean-copy
...
Clean unnecessary copy detected by clang-tidy
2024-01-04 14:25:58 +01:00
Rémi Verschelde
6c390b620d
Merge pull request #84445 from Rubonnek/add-const-references-clang-tidy
...
Add const references detected by clang-tidy
2024-01-04 14:25:33 +01:00
Yuri Sizov
6fc92e1d05
Merge pull request #84611 from AThousandShips/encode_invalid
...
Prevent encoding/decoding objects that cannot be instantiated
2023-12-19 20:32:42 +01:00
Yuri Sizov
d8a65b3f46
Merge pull request #85464 from KoBeWi/only_say_verbose_when_not_verbose
...
Improve message about resources in use at exit
2023-12-19 13:01:59 +01:00
A Thousand Ships
c1b8b87736
Prevent encoding/decoding objects that cannot be instantiated
2023-12-18 22:06:08 +01:00
Yuri Sizov
a9a50938c0
Merge pull request #85991 from jsjtxietian/fix-bad-pos-state
...
Fix `FileAccessPack::get_buffer` updating position past the length of file
2023-12-18 18:18:01 +01:00
Wilson E. Alvarez
a3cb1b096f
Add const references detected by clang-tidy
2023-12-16 13:36:44 -05:00
kobewi
397f0b31e4
Fix file disappearing when renaming dependencies
2023-12-14 22:28:48 +01:00
Rémi Verschelde
b952b007b1
Merge pull request #84782 from rsburke4/image-fix
...
Prevent crash on conversion of invalid data in `Image`
2023-12-12 00:17:42 +01:00
rsburke4
dec2269bca
Added error to catch conversion on invalid image
2023-12-10 15:06:22 -05:00
jsjtxietian
68a6fe81ab
Fix FileAccessPack::get_buffer will update pos past the length of file
2023-12-10 16:21:16 +08:00
Yuri Sizov
2e94be2ea4
Merge pull request #84167 from SaracenOne/cache_mode_replace_fixes
...
Fix behavior of ResourceFormatLoader `CACHE_MODE_REPLACE`
2023-12-08 15:23:13 +01:00
kobewi
f8f8fe0615
Improve message about resources in use at exit
2023-11-28 14:01:08 +01:00
Yuri Sizov
bc1949d797
Correctly check scripts that must inherit `EditorPlugin`
...
Also updates some error messages related to this kind of check
across the codebase.
2023-11-23 16:24:43 +01:00
Saracen
f392a9c4f8
Fix CACHE_MODE_REPLACE
2023-11-15 18:55:20 +00:00
Rémi Verschelde
2bcc2a3cd0
Merge pull request #84791 from akien-mga/fix-translation-remapping-check
...
Fix translation remapping check for imported resources
2023-11-12 23:00:08 +01:00
Rémi Verschelde
2729a78fd7
Fix translation remapping check for imported resources
...
Fixes #81660 .
2023-11-12 13:17:12 +01:00
kobewi
a3627b6e37
Assign temporary path to preloaded resources
2023-11-10 00:43:30 +01:00