Commit Graph

6174 Commits

Author SHA1 Message Date
Fabio Alessandrelli
395a4fc5f2 [SCons] Remove MAXLINELENGTH override for MSVC
It's not clear what is the actual max value that windows support, but
despite their claim of it being 8191 we have been seeing failure with
just 8150.
2024-09-26 12:06:16 +02:00
Rémi Verschelde
c92a6c7e27
CI: Update clang-format pre-commit hook to 19.1.0 2024-09-26 11:46:12 +02:00
Fredia Huya-Kouadio
77202e08b4 Update the set of excluded permissions for the XR Editor
A few permissions including the `USE_SCENE` permission are being renamed with the launch of the Meta Spatial SDK, so we update the excluded list to avoid requesting them on app start.
2024-09-25 23:22:16 -07:00
Thaddeus Crews
32c83a228d
Style: Add WARNING: as new comment admonition 2024-09-25 09:44:42 -05:00
Thaddeus Crews
9f9ee0c813
SCons: Add unobtrusive type hints in SCons files 2024-09-25 09:34:35 -05:00
David Snopek
36293a2dbf Fix renaming nodes on X11 2024-09-25 09:05:51 -05:00
Rémi Verschelde
648b21b9ba
Merge pull request #96813 from Repiteo/scons/fix-clang-cl-flags
SCons: Fix `clang-cl` link/ar flags
2024-09-23 12:27:59 +02:00
Joaquim Monteiro
c4e4810e93
Fallback to OpenGL 3 if Vulkan isn't available on Wayland 2024-09-21 06:35:35 +01:00
Rémi Verschelde
c2564f42aa
Merge pull request #97142 from SheepYhangCN/master
Fallback to OpenGL 3 if other rendering drivers are not supported
2024-09-20 16:06:35 +02:00
Thaddeus Crews
b37fc1014a
Style: Apply new clang-format changes 2024-09-20 08:09:48 -05:00
SheepYhangCN
3b839347df Added fallback_to_opengl3 2024-09-20 06:10:05 +08:00
Alvin Wong
454251660c Fix using Binutils AR with TEMPFILE on Windows
Set `TEMPFILEARGESCFUNC`[1] to replace backslashes with forward slashes
in paths.

[1]: https://scons.org/doc/production/HTML/scons-user/apa.html#cv-TEMPFILEARGESCFUNC
2024-09-19 22:19:15 +08:00
Rémi Verschelde
804d9775b5
Merge pull request #96407 from alvinhochun/mingw-ar-long-command-tempfile
Remove `ARFLAGS` hack for Windows, replace with `TEMPFILE`
2024-09-18 17:40:53 +02:00
Rémi Verschelde
1d3e9b3688
Merge pull request #96829 from dsnopek/x11-focus-bugs-take-twenty-seven-million-and-four
Fix project manager stealing focus on i3
2024-09-18 11:15:30 +02:00
Rémi Verschelde
2c8ab6e7eb
Merge pull request #94839 from alvinhochun/win-set-console-mode
Combine existing modes when calling SetConsoleMode
2024-09-18 11:15:22 +02:00
kobewi
4023ace08d Add Advanced Settings switch to Editor Settings 2024-09-17 12:20:55 +02:00
Rémi Verschelde
5fc786911f
Merge pull request #96286 from adamscott/add-js_buffer_to_packed_byte_array
Add `JavaScriptBridge` buffer methods
2024-09-17 09:17:42 +02:00
David Snopek
b1871cdabf Fix project manager stealing focus on i3 2024-09-16 16:55:57 -05:00
Adam Scott
a9b934b657
Add JavaScriptBridge buffer methods 2024-09-16 12:13:34 -04:00
Raul Santos
0aa46e19c5
C#: Fallback to CoreCLR/MonoVM hosting APIs when hostfxr/NativeAOT fails
Some platforms don't support hostfxr but we can use the coreclr/monosgen library directly to initialize the runtime.

Android exports now use the `android` runtime identifier instead of `linux-bionic`, this removes the restrictions we previously had:
- Adds support for all Android architectures (arm32, arm64, x32, and x64), previously only the 64-bit architectures were supported.
- Loads `System.Security.Cryptography.Native.Android` (the .NET library that binds to the Android OS crypto functions).
2024-09-16 17:07:03 +02:00
Rémi Verschelde
6daa6a8513
Merge pull request #97063 from rcadena/d97062-unexpected-debugger-line
Some checks are pending
🔗 GHA / 📊 Static checks (push) Waiting to run
🔗 GHA / 🤖 Android (push) Blocked by required conditions
🔗 GHA / 🍏 iOS (push) Blocked by required conditions
🔗 GHA / 🐧 Linux (push) Blocked by required conditions
🔗 GHA / 🍎 macOS (push) Blocked by required conditions
🔗 GHA / 🏁 Windows (push) Blocked by required conditions
🔗 GHA / 🌐 Web (push) Blocked by required conditions
🔗 GHA / 🪲 Godot CPP (push) Blocked by required conditions
Remove debug print from Android `DisplayServer.screen_get_scale` implementation
2024-09-16 13:36:09 +02:00
Rémi Verschelde
f91c1a7b88
Merge pull request #97000 from Hilderin/fix-editor-doc-cache-locked-on-editor-startup
Fix `editor_doc_cache` locked by `adb` process on editor startup
2024-09-16 13:35:46 +02:00
Rémi Verschelde
4215dfdff7
Merge pull request #96973 from Riteo/pointing-the-obvious
Wayland: Simplify cursor code and fix custom cursors
2024-09-16 13:35:35 +02:00
Rémi Verschelde
ebe8f36458
Merge pull request #96970 from bruvzg/macos_lib_path
[macOS] Fix dynamic library lookup for system libraries.
2024-09-16 13:35:32 +02:00
Rémi Verschelde
7174e2192b
Merge pull request #96967 from m4gr3d/update_android_editor_flavors
[Android editor] Update the Android editor flavors
2024-09-16 13:35:28 +02:00
Robert Cadena
42b0e91ee4
Remove debug print from Android DisplayServer.screen_get_scale implementation 2024-09-16 11:17:26 +02:00
Markus Sauermann
60aaa017ff Enable Drag and Drop for SubViewports and Windows
Make Drag and Drop an application-wide operation.
This allows do drop on Controls in other Viewports/Windows.

In order to achieve this, `Viewport::_update_mouse_over` is adjusted to
remember the Control, that the mouse is over (possibly within nested
viewports). This Control is used as a basis for the Drop-operation, which
replaces the previous algorithm, which was only aware of the topmost
Viewport.

Also now all nodes in the SceneTree are notified about the Drag and Drop
operation, with the exception of SubViewports that are not children of
SubViewportContainers.
2024-09-15 01:06:02 +02:00
bruvzg
8d039146d9
[macOS] Fix dynamic library lookup for system libraries. 2024-09-14 18:22:36 +03:00
Hilderin
e064efccbc Fix editor_doc_cache locked on editor startup 2024-09-14 09:37:04 -04:00
Riteo
c15cd3acc4 Wayland: Simplify cursor code and fix custom cursors
Initially the WaylandThread cursor code was supposed to be as stateless
as possible but, as time went on, this wasn't possible.

This expectation made the resulting API quite convoluted, so this patch
aims to simplify it substantially bot in terms of API surface and, most
importantly, in terms of actual implementation complexity.

This patch also fixes custom cursors since I accidentally changed the
mmap flags to MAP_PRIVATE some time ago. This took me hours to notice.
2024-09-13 19:08:53 +02:00
Fredia Huya-Kouadio
741efa632a Update the Android editor flavors to avoid vendor-specific references 2024-09-13 08:53:29 -07:00
A Thousand Ships
dd6443193c
[Editor] Expose more editor settings to documentation
Co-authored-by: Tomasz Chabora <kobewi4e@gmail.com>
2024-09-12 15:34:49 +02:00
Rémi Verschelde
f33a81977b
Merge pull request #96742 from m4gr3d/check_openxr_automatic_permissions_request
[Android editor] Limit when OpenXR runtime permissions are requested
2024-09-12 09:17:51 +02:00
Fredia Huya-Kouadio
3ff95ef12a Only request OpenXR permissions for a XR game running off the Android editor when the xr/openxr/extensions/automatically_request_runtime_permissions project setting is enabled 2024-09-11 14:47:08 -07:00
Riteo
343ea9c6f7 Wayland: clear button mask on pointer leave
While experimenting with the recent "extent to title" PR, I noticed that
it's not guaranteed for a "button released" event to be emitted when
the pointer leaves the main surface, leaving some buttons stuck.

Not doing this for tablets since the spec makes this behavior clear and
explicit, so we (hopefully) shouldn't have this issue there.
2024-09-10 20:53:53 +02:00
Thaddeus Crews
df0a88b128
SCons: Fix clang-cl link/ar flags 2024-09-10 13:48:53 -05:00
bruvzg
2c991a727b [Windows] Only use long executable path when necessary, fix broken apksigner detection. 2024-09-10 10:34:44 +03:00
Rémi Verschelde
9fb54b7d1d
Merge pull request #96747 from bruvzg/fix_ar_det
[MinGW] Fix GCC ar detection.
2024-09-09 17:51:56 +02:00
Rémi Verschelde
07c395191c
Merge pull request #96697 from devloglogan/long-press-fix
Disable some android editor settings by default on XR devices
2024-09-09 17:51:49 +02:00
devloglogan
16e1d8a81b Disable some editor settings by default in the XR Editor 2024-09-09 07:15:15 -05:00
bruvzg
b1f9271e49
[MinGW] Fix GCC ar detection. 2024-09-09 11:01:29 +03:00
Rémi Verschelde
d0dc3896ad
Merge pull request #96714 from Riteo/dont-ask-me-why-they-are-different
Some checks are pending
🔗 GHA / 📊 Static checks (push) Waiting to run
🔗 GHA / 🤖 Android (push) Blocked by required conditions
🔗 GHA / 🍏 iOS (push) Blocked by required conditions
🔗 GHA / 🐧 Linux (push) Blocked by required conditions
🔗 GHA / 🍎 macOS (push) Blocked by required conditions
🔗 GHA / 🏁 Windows (push) Blocked by required conditions
🔗 GHA / 🌐 Web (push) Blocked by required conditions
🔗 GHA / 🪲 Godot CPP (push) Blocked by required conditions
Wayland: Make primary selection logic consistent with main clipboard
2024-09-08 23:22:26 +02:00
Rémi Verschelde
c948541b14
Merge pull request #96669 from bruvzg/win_app
Reenable macOS .app export from Windows, add warnings about Unix permissions.
2024-09-08 23:22:08 +02:00
Riteo
26d89bc8e9 Wayland: make primary selection logic consistent with main clipboard 2024-09-08 16:48:41 +02:00
bruvzg
1f0b1220d2
Reenable macOS .app export from Windows, add warnings about Unix permissions. 2024-09-07 01:12:10 +03:00
Rémi Verschelde
0e9950bde1
Merge pull request #96624 from m4gr3d/android_editor_improvements
[Android editor] Improve support for XR projects
2024-09-06 22:38:50 +02:00
bruvzg
10f3c1f587
Add support for non-blocking IO mode to OS.execute_with_pipe. 2024-09-06 14:16:39 +03:00
Rémi Verschelde
2c733cbf1c
Merge pull request #95885 from bruvzg/macos_arch
[macOS] Use per-architecture min. OS version for export.
2024-09-06 11:11:01 +02:00
Fredia Huya-Kouadio
9dc0543da7 Improve support for XR projects 2024-09-06 00:35:50 -07:00
Rémi Verschelde
82799d7687
Merge pull request #96526 from bruvzg/win_env
[Windows] Use the same API for all `OS_Windows::*_environment` functions.
2024-09-04 18:55:46 +02:00
Rémi Verschelde
4ab358481b
Merge pull request #96340 from m4gr3d/update_pip_mode_options
[Android Editor] Update the options for launching the Play window in PiP mode
2024-09-04 18:55:35 +02:00
Rémi Verschelde
3cc99d3e31
Merge pull request #95983 from bruvzg/win_fd_opt_fix
[Windows] Emit native file dialog callback from event loop, fix selected options not saved.
2024-09-04 17:11:57 +02:00
Rémi Verschelde
9abf86f4fe
Merge pull request #96540 from hunterkepley/fix-wayland-middlemouse-paste
Wayland: Fix primary clipboard handling
2024-09-04 11:16:42 +02:00
Rémi Verschelde
8eff04192b
Merge pull request #91780 from Riteo/falling-with-style
Improve UX when falling back between Display Servers
2024-09-04 11:16:08 +02:00
hunterkepley
7949585aad Wayland: Fix primary clipboard handling 2024-09-03 22:39:54 -04:00
Rémi Verschelde
13a90e938f
Merge pull request #70096 from rune-scape/stringname-dict
StringName Dictionary keys
2024-09-03 17:38:06 +02:00
bruvzg
319bfa9965
[Windows] Use the same API for all OS_Windows::*_environment functions. 2024-09-03 16:02:35 +03:00
Rémi Verschelde
657dc363ef
Merge pull request #96182 from dsnopek/java-class-wrapper
Fix `JavaClassWrapper` so it actually works
2024-09-03 11:43:35 +02:00
Rémi Verschelde
262c8da104
Merge pull request #95887 from bruvzg/sysinfo_drv
Update rendering driver name on fallbacks. Fix rendering driver/method in the editor system info.
2024-09-03 11:43:12 +02:00
David Snopek
78883a52c6 Fix JavaClassWrapper so it actually works 2024-09-02 08:54:23 -05:00
Rémi Verschelde
109fafc7a4
Merge pull request #96383 from dsnopek/gdextension-pdb-missing-error
GDExtension: Show warning on missing PDB file, rather than error
2024-09-02 12:13:34 +02:00
Rémi Verschelde
0b19125b18
Merge pull request #96365 from m4gr3d/fix_android_build_with_openxr_disabled
Fix Android builds when OpenXR is disabled
2024-09-02 12:13:26 +02:00
Rémi Verschelde
527c716784
Merge pull request #92167 from BlueCube3310/file-access-the-final-season-part3-ep2
Reduce code duplication in FileAccess
2024-09-02 12:12:42 +02:00
bruvzg
c273786758
Update rendering driver name on fallbacks. Fix rendering driver/method in the editor system info. 2024-09-01 18:22:40 +03:00
BlueCube3310
205a10e0ae Reduce code duplication in FileAccess 2024-09-01 12:39:32 +02:00
Alvin Wong
28b95ff550 Remove ARFLAGS hack for Windows, replace with TEMPFILE
TEMPFILE is the built-in way of SCons to use a response file for command
lines that are too long.
2024-09-01 04:10:30 +08:00
Alvin Wong
35a8ff9284 mingw: Only use ar --thin on supported versions
The flag is supported since Binutils 2.38 [1] or LLVM 14 [2].

[1]: https://sourceware.org/bugzilla/show_bug.cgi?id=28759
[2]: dd6e7e0d57
2024-09-01 02:13:31 +08:00
David Snopek
760099ca6f GDExtension: Show warning on missing PDB file, rather than error 2024-08-31 07:45:06 -05:00
Fredia Huya-Kouadio
92ffa93c58 Fix Android builds when OpenXR is disabled 2024-08-30 23:11:50 -07:00
Fredia Huya-Kouadio
11d4df4bc3 Update the options for launching the Play window in PiP mode 2024-08-30 10:31:33 -07:00
Rémi Verschelde
b128e71383
Merge pull request #96208 from m4gr3d/cleanup_immersive_logic
Restore fullscreen toggle menu for the Android editor and clean up the immersive mode logic
2024-08-30 09:59:27 +02:00
Rémi Verschelde
0897d830fe
Merge pull request #96204 from bruvzg/fd_no_case
[Linux] Make file filters case insensitive.
2024-08-30 09:59:23 +02:00
Rémi Verschelde
66dd06837c
Merge pull request #90782 from bruvzg/export_platform_extension
Allow adding custom export platforms using scripts / GDExtension.
2024-08-30 09:58:52 +02:00
rune-scape
154049ce17 StringName Dictionary keys
also added 'is_string()' method to Variant
and refactored many String type comparisons to use it instead
2024-08-29 13:39:27 -07:00
Rémi Verschelde
526b35c929
Merge pull request #96254 from raulsntos/android/keyStore.isEmpty()
[Android] Check if `keyStore` path is empty
2024-08-29 10:36:49 +02:00
Rémi Verschelde
cb96fc95c3
Merge pull request #92316 from alula/msvc-clang
Add support for compiling with VS clang-cl toolset
2024-08-29 10:36:17 +02:00
Alula
346cbc7f1f
Add support for compiling with VS clang-cl toolset 2024-08-28 13:30:44 -05:00
bruvzg
d528f28275 [Windows] Fix OS.open_dynamic_library 2024-08-28 20:12:09 +03:00
Fredia Huya-Kouadio
923b0f2e56 Restore 'Toggle fullscreen' menu for the Android editor and clean up the immersive mode logic 2024-08-28 09:50:34 -07:00
Raul Santos
efe5f988e0
[Android] Check if keyStore path is empty
In `godot-build-scripts`, the default `config.sh` sets `GODOT_ANDROID_SIGN_KEYSTORE` to an empty string but we were only checking if it's null.
2024-08-28 17:24:54 +02:00
Rémi Verschelde
60765bebe4
Merge pull request #95700 from m4gr3d/add_pip_support_to_game_window
[Android Editor] Add support for launching the Play window in PiP mode
2024-08-28 13:14:23 +02:00
Rémi Verschelde
2730d703a8
Merge pull request #94747 from alvinhochun/mingw-llvm-build-flags
Some improvements for MinGW and LLVM build on Windows
2024-08-28 13:14:19 +02:00
Alvin Wong
2d300a0bdc MinGW: Use thin archives to reduce disk space 2024-08-28 18:20:16 +08:00
Alvin Wong
b5258b42c0 Enable Clang color output on Windows 2024-08-28 18:20:16 +08:00
Alvin Wong
e9b6c1baf8 Windows/detect.py: Detect llvm-mingw GCC wrappers and set use_llvm 2024-08-28 18:20:16 +08:00
Fredia Huya-Kouadio
961394a988 Add support for launching the Play window in PiP mode 2024-08-28 03:18:51 -07:00
Alvin Wong
3a0837b74b Windows/detect.py: Simplify try_cmd function 2024-08-28 17:20:27 +08:00
bruvzg
ae334e069c
[Windows] Always use absolute UNC paths and long path aware APIs, add "long path aware" flag to the application manifest. 2024-08-28 11:15:57 +03:00
bruvzg
ace603bcb9
[Linux] Make file filters case insensitive. 2024-08-28 11:13:47 +03:00
Rémi Verschelde
108c603f91
Merge pull request #96203 from bruvzg/fd_all_filter
Some checks are pending
🔗 GHA / 📊 Static checks (push) Waiting to run
🔗 GHA / 🤖 Android (push) Blocked by required conditions
🔗 GHA / 🍏 iOS (push) Blocked by required conditions
🔗 GHA / 🐧 Linux (push) Blocked by required conditions
🔗 GHA / 🍎 macOS (push) Blocked by required conditions
🔗 GHA / 🏁 Windows (push) Blocked by required conditions
🔗 GHA / 🌐 Web (push) Blocked by required conditions
🔗 GHA / 🪲 Godot CPP (push) Blocked by required conditions
[Linux] Fix "all files" filter in the native file dialog.
2024-08-28 09:45:47 +02:00
Rémi Verschelde
96159ebc5d
Merge pull request #96192 from dsnopek/windows-gdext-adddlldirectory
Windows: Call `AddDllDirectory()` with an absolute path
2024-08-28 09:45:35 +02:00
bruvzg
07e986f728
Allow adding custom export platforms using scripts / GDExtension. 2024-08-28 10:29:01 +03:00
bruvzg
7b4e3e021a
[Linux] Fix "all files" filter in the native file dialog. 2024-08-28 10:14:01 +03:00
David Snopek
e8bd385f53 Windows: Call AddDllDirectory() with an absolute path 2024-08-27 17:38:30 -05:00
Rémi Verschelde
db24ed4ead
Merge pull request #94995 from Repiteo/scons/raw-cstrings
Some checks are pending
🔗 GHA / 📊 Static checks (push) Waiting to run
🔗 GHA / 🤖 Android (push) Blocked by required conditions
🔗 GHA / 🍏 iOS (push) Blocked by required conditions
🔗 GHA / 🐧 Linux (push) Blocked by required conditions
🔗 GHA / 🍎 macOS (push) Blocked by required conditions
🔗 GHA / 🏁 Windows (push) Blocked by required conditions
🔗 GHA / 🌐 Web (push) Blocked by required conditions
🔗 GHA / 🪲 Godot CPP (push) Blocked by required conditions
SCons: Add method to generate raw cstrings
2024-08-28 00:12:47 +02:00
Rémi Verschelde
73acb2a5b8
Merge pull request #94845 from alvinhochun/llvm-mingw-sanitizers
Windows: Add sanitizers for llvm-mingw, increase stack for ASan
2024-08-28 00:12:30 +02:00
Rémi Verschelde
330fca1ffd
Merge pull request #93985 from alvinhochun/windows-gpu-pref
Respect integrated GPU preference in Windows Settings
2024-08-28 00:11:45 +02:00
Rémi Verschelde
431c5839fe
Merge pull request #96168 from CreatedBySeb/remove-user-prefix
Remove confusing USER prefix from script-logged errors
2024-08-27 17:52:40 +02:00
Sébastien Dunne Fulmer
c3ed8a842c
Remove confusing USER prefix from script-logged errors 2024-08-27 15:00:48 +01:00
bruvzg
9a2977fef1 [Windows] Hide cursor before moving. 2024-08-27 08:44:05 +03:00
Fredia Huya-Kouadio
6a9c060883 Add support to the Android editor for signing and verifying Android apks
- Apk signing and verification is enabled using the apksig library from ac5cbb07d8
2024-08-26 11:38:49 -07:00
Fredia Huya-Kouadio
a5897d579b Update the GodotHost interface to support signing and verifying Android apks
Update the export logic to enable apk generation and signing for Android editor builds

Note: Only legacy builds are supported. Gradle builds are not supported at this point in time.
2024-08-26 11:16:38 -07:00
Fredia Huya-Kouadio
794ea99240 Update the storage access handler logic to support accessing / retrieving contents with the assets:/ prefix 2024-08-26 11:16:37 -07:00
Rémi Verschelde
b4f268fae8
Merge pull request #91018 from Daylily-Zeleen/daylily-zeleen/optionally_postinitialization_for_extension_owner
Allow ClassDB to create a Object without postinitialization for GDExtension.
2024-08-26 10:51:17 +02:00
Rémi Verschelde
28a72fa434
Merge pull request #95934 from bruvzg/win_ang_fb
Enable fallback from ANGLE to native and improve ANGLE error messages.
2024-08-25 22:51:38 +02:00
Rémi Verschelde
1d3bdfcd06
Merge pull request #95862 from adamscott/fix-pitch-scale-before-play
Honor `pitch_scale` value before playing audio sample
2024-08-25 22:24:17 +02:00
bruvzg
f8a6c0e8ab
Enable fallback from ANGLE to native and improve ANGLE error messages. 2024-08-25 21:19:54 +03:00
Joel Winarske
6ce71f0fb0 Use wayland-egl-core.h instead of wayland-egl.h
-avoid use of transitive wayland include

-resolves https://github.com/godotengine/godot/issues/95830

Signed-off-by: Joel Winarske <joel.winarske@gmail.com>
2024-08-23 14:16:37 -07:00
bruvzg
ea252675aa [Windows] Emit native file dialog callback from event loop, fix selected options not saved. 2024-08-23 09:53:16 +03:00
Hilderin
6cbadcf606 Fix mouse move over an unfocused window 2024-08-22 21:36:01 -04:00
Rémi Verschelde
568589c9d8
Merge pull request #90993 from darksylinc/matias-TheForge
Add debug utilities for Vulkan
2024-08-22 00:38:22 +02:00
Rémi Verschelde
37ae2a2900
Merge pull request #95921 from akien-mga/scons-validate-opt-in-drivers
SCons: Better validation for platform-specific opt-in drivers
2024-08-22 00:10:56 +02:00
Rémi Verschelde
100fbb51ab
Merge pull request #95665 from Hilderin/fix-drag-drop-between-window
Fix drag&drop between window on Windows
2024-08-22 00:10:35 +02:00
Rémi Verschelde
78f47abe2b
Merge pull request #94022 from Riteo/a-fraction-of-the-work
Wayland: Switch pointer position handling to doubles
2024-08-22 00:10:31 +02:00
Matias N. Goldberg
364f916f3f
Add debug utilities for Vulkan
Features:
- Debug-only tracking of objects by type. See
get_driver_allocs_by_object_type et al.
 - Debug-only Breadcrumb info for debugging GPU crashes and device lost
 - Performance report per frame from get_perf_report
- Some VMA calls had to be modified in order to insert the necessary
memory callbacks

Functionality marked as "debug-only" is only available in debug or dev
builds.

Misc fixes:
 - Early break optimization in RenderingDevice::uniform_set_create

============================

The work was performed by collaboration of TheForge and Google. I am
merely splitting it up into smaller PRs and cleaning it up.
2024-08-21 23:48:08 +02:00
Rémi Verschelde
6e9bcc0f18
SCons: Better validation for platform-specific opt-in drivers
This replaces cryptic compilation errors with a clear error message
and early build termination.
2024-08-21 22:53:34 +02:00
Riteo
33e414cf75 Wayland: report when video drivers can't be loaded or found
This brings it to parity with the X11 backend.
2024-08-21 07:15:08 +02:00
bruvzg
3034d32429
[macOS] Use per-architecture min. OS version for export. 2024-08-21 07:51:39 +03:00
Riteo
c01f9361b1 X11: Alert only when video drivers fail initialization
Before, they would always complain even if there was no attempt at
initializing them (e.g. because there's no X11 display).

While we're at it, this patch also adds a specific message for OpenGL ES
and rewords "OpenGLES" to "OpenGL ES" in an error, for consistency
(AFAIK we either say "GLES" or "OpenGL ES").
2024-08-21 06:31:19 +02:00
Adam Scott
aaafd163b2
Honor pitch_scale value before playing audio sample 2024-08-20 10:29:32 -04:00
Daylily-Zeleen
3d575801ce Allow ClassDB to create a Object without postinitialization for GDExtension. 2024-08-20 20:19:02 +08:00
Stuart Carnie
2d0165574d
Add Metal support for macOS (arm64) and iOS 2024-08-20 12:11:06 +02:00
Stuart Carnie
41875d8aef
macOS/iOS: Fix various warnings when targeting newer SDKs 2024-08-20 11:55:21 +02:00
Rémi Verschelde
a07f20b3e5
Merge pull request #95794 from bruvzg/win_fd_thread
[Windows] Run native file dialogs in thread to make it non-blocking.
2024-08-19 14:34:34 +02:00
Rémi Verschelde
d1424135d1
Merge pull request #90352 from Faless/web/serve_fix_browser_order
[Web] Fix browser opening too early with `serve.py`
2024-08-19 14:33:26 +02:00
bruvzg
66832e9968 [Windows] Run native file dialogs in thread to make it non-blocking. 2024-08-19 12:58:16 +03:00
Micky
b8f78b14be Fix miscellaneous oddities around the class reference 2024-08-18 23:18:44 +02:00
Rémi Verschelde
a0d549fe93
Merge pull request #95272 from akien-mga/applicalifragilisticexpialidocious
iOS: Fix typo in GodotApplicationDelegate
2024-08-17 00:46:47 +02:00
Hilderin
0987a9dc06 Fix drag&drop between window on Windows 2024-08-16 18:40:46 -04:00
Rémi Verschelde
82adfebcf8
Merge pull request #94799 from m4gr3d/memory_allocation_cleanup_and_optimizations
Android memory cleanup and optimizations
2024-08-16 23:45:39 +02:00
Fredia Huya-Kouadio
a57a99f5bc Memory cleanup and optimizations
- Returns an empty list when there's not registered plugins, thus preventing the creation of spurious iterator objects

- Inline `Godot#getRotatedValues(...)` given it only had a single caller. This allows to remove the allocation of a float array on each call and replace it with float variables

- Disable sensor events by default. Sensor events can fired at 10-100s Hz taking cpu and memory resources. Now the use of sensor data is behind a project setting allowing projects that have use of it to enable it, while other projects don't pay the cost for a feature they don't use

- Create a pool of specialized input `Runnable` objects to prevent spurious, unbounded `Runnable` allocations

- Disable showing the boot logo for Android XR projects

- Delete locale references of jni strings
2024-08-16 09:27:41 -07:00
bruvzg
f72e74f395
[Windows/Linux] Check custom export templates architecture. 2024-08-16 15:52:12 +03:00
Rémi Verschelde
de44c20514
Merge pull request #95498 from LeonardoDemartino/fix_macos_dylibsigning
macOS: Only set entitlements for main binaries, fixing C# signing issues
2024-08-16 14:35:06 +02:00
Rémi Verschelde
f2fb3353cb
Merge pull request #95197 from yahkr/95128-audio-fix
Fix AudioStreamPlayer `get_playback_position()` for web build
2024-08-16 14:33:05 +02:00
Rémi Verschelde
b084b6a8bb
Merge pull request #94971 from bruvzg/drv_msgs
[Windows] Improve video driver error messages.
2024-08-16 14:32:50 +02:00
Rémi Verschelde
6042c66663
Merge pull request #94720 from noidexe/fix-gamepad-triggers
Fix gamepad triggers not working on web exports
2024-08-16 14:32:27 +02:00
Rémi Verschelde
a7598679cf
Merge pull request #95586 from m4gr3d/fix_last_modified_time_unit
Update the Android `fileLastModified` method to return values in seconds instead of milliseconds
2024-08-16 10:36:56 +02:00
Rémi Verschelde
a8bbb09bd5
Merge pull request #95143 from TV4Fun/fix_non_windows_library_load
Fix reload of GDExtension libraries in framework package on macOS
2024-08-16 10:35:19 +02:00
Rémi Verschelde
690c5669e2
Merge pull request #91271 from m4gr3d/clean_gradle_build_setup
Clean up the gradle build logic used to generate the Godot Android binaries
2024-08-16 10:33:19 +02:00
Fredia Huya-Kouadio
cde873b406 Update the Android fileLastModified method to return values in seconds instead of milliseconds 2024-08-15 12:24:58 -07:00
Alvin Wong
16a563b9ac DisplayServerWindows: Fix logic when creating with transient parent 2024-08-15 04:10:15 +08:00
Lisandro Lorea
9dd372f316 Fix gamepad triggers not working on web exports
Fixes #81758

DisplayServerWeb::process_joypads handles buttons 6 and 7 of the
HTML5 Standard Gamepad as a special case by doing:
`input->joy_axis(idx, (JoyAxis)b, s_btns[b]);`

This doesn't work because there is no JoyAxis 6 or 7 in the enum

To fix this we use JoyAxis::TRIGGER_LEFT and TRIGGER_RIGHT for button 6
and 7

However since we are now lying to input->joy_axis we also need to lie in
the mappings for the standard gamepad in godotcontrollersdb.txt,
otherwise input->joy_axis will try to find a mapping to axis 4(LT) and
axis 5(RT) that's not defined.

Therefore we set lefttrigger to +a4 and righttrigger to +a5 in the
mapping, to match what we are actually sending.

A cleaner, and more involved fix to this would be modifying
input->joy_button so that it can handle analog buttons and map them to
axes preserving their value instead of converting to boolean
2024-08-14 16:13:16 -03:00
Leonardo Demartino
0a57dd4682 Only main binaries require entitlements. This fixes signing issues on macOS. 2024-08-13 16:55:27 -03:00
Rémi Verschelde
edc0571c96
Merge pull request #95425 from bruvzg/macos_joypad_queue
[macOS] Fix wrong object type in joypad queue.
2024-08-12 18:18:19 +02:00
Rémi Verschelde
4ab4613f90
Merge pull request #95331 from Riteo/seat-tight-this-is-weird
Wayland: Avoid recreating input objects on capability change
2024-08-12 14:10:07 +02:00
bruvzg
d1047f4c46
[macOS] Fix wrong object type in joypad queue. 2024-08-12 14:09:18 +03:00
Rémi Verschelde
d0fc7f73df
Merge pull request #95323 from bruvzg/ios_dyl
[iOS] Fix dylib GDExtension convertion.
2024-08-09 23:25:12 +02:00
Riteo
0d1826e084 Wayland: Avoid recreating input objects on capability change
Before, multiple capability events would instantiate the same object
over and over as long as its bit was set. This caused issues with
hotplug and device suspension.
2024-08-09 15:42:23 +02:00
bruvzg
824324e7c4
[iOS] Fix dylib GDExtension convertion. 2024-08-09 12:44:48 +03:00
Yahkub-R
bcd776e441 Fix AudioStreamPlayer get_playback_position() for web build 2024-08-08 15:58:25 -04:00
bruvzg
9949d5a089
[macOS] Remove kill override. 2024-08-08 21:39:00 +03:00
Joel Croteau
f44d6a235f Fix reload of GDExtension libraries in framework package on macos
`GDExtension::open_library` has a check in it to see if the library was loaded
from a temp file, and if it was to restore the original name as that is the one
we actually care about. This check is breaking extension reloading on Mac when
the library path is to a framework folder, as the file inside the framework
will not generally be the same name as the folder.

This check also shouldn't be necessary even on Windows, which is the only
platform that uses `generate_temp_files`, since disposal of the created temp
file is handled within `OS_Windows::open_dynamic_library`, and
`GDExtension::open_library` (which is the only function to call
`open_dynamic_library` with a `p_data` argument) only cares about the original
library file path and has to do extra work to remove the name of the temp file.
Instead, I have removed that check and set `OS_Windows::open_dynamic_library`
to return the name of the original file and not the name of the copy.

This fixes GDExtension reloading on macOS. I do not have a Windows machine
available to test that it still works properly on Windows, so someone should
check that before merging this.
2024-08-08 08:31:49 -06:00
Rémi Verschelde
1938d170aa
iOS: Fix typo in GodotApplicationDelegate
Fixes #90714.
2024-08-08 10:06:36 +02:00
bruvzg
2bd21b588e
[macOS] Load OpenGL.framework by path to avoid issues with non-Latin executable names. 2024-08-07 11:57:27 +03:00
Rémi Verschelde
4577b37036
Merge pull request #95191 from bruvzg/macos_term
[macOS] Attempt to terminate process normally before using `forceTerminate`.
2024-08-06 12:32:22 +02:00
Rémi Verschelde
8ba212f188
Merge pull request #95189 from bruvzg/fix_mono_bundle
[macOS] Fix `generate_bundle` build flag for .NET builds.
2024-08-06 12:32:18 +02:00
Rémi Verschelde
e693ff814a
Merge pull request #95155 from bruvzg/win_pen_checks
[Windows] Reject `WM_POINTER(UP/DOWN)` messages for non pen pointer type.
2024-08-06 12:32:02 +02:00
Rémi Verschelde
e54ffd21e2
Merge pull request #95046 from timothyqiu/typos
Fix several typos in the documentation
2024-08-06 12:31:12 +02:00
Rémi Verschelde
2b65ff9249
Merge pull request #95009 from bruvzg/win_transp_checks
[Windows] Check if transparency is enabled in the project setting before applying DWM blur.
2024-08-06 12:30:56 +02:00
bruvzg
393741a7e2
[macOS] Attempt to terminate process normally before using forceTerminate. 2024-08-06 12:45:56 +03:00
bruvzg
1f53c71df5
[macOS] Fix generate_bundle build flag for .NET builds. 2024-08-06 10:55:24 +03:00
bruvzg
e5efde9481
[Windows] Reject WM_POINTER(UP/DOWN) messages for non pen pointer type. 2024-08-04 20:07:14 +03:00
Haoyu Qiu
7cf9ed5f65 Fix several typos in the documentation 2024-08-02 08:42:20 +08:00
bruvzg
27474c9563
[Windows] Check if transparency is enabled in the project setting before applying DWM blur. 2024-08-01 10:30:46 +03:00
bruvzg
99b0100a06
[X11] Use motion event button state instead of async state. 2024-08-01 10:07:07 +03:00
Fabio Alessandrelli
470a35832f [Web] Fix browser opening too early with serve.py 2024-08-01 05:38:36 +02:00
Thaddeus Crews
0163705640
SCons: Add method to generate raw cstrings 2024-07-31 14:22:04 -05:00
bruvzg
1dfcbccfe6
[macOS] Fix is_process_running and kill for bundled apps. 2024-07-31 16:54:53 +02:00
Rémi Verschelde
1d57b81d26
Merge pull request #94976 from bruvzg/win_app_name
[Windows] Improve editor grouping, set friendly name registry key for exported projects.
2024-07-31 16:13:21 +02:00
bruvzg
3f8cc6678b [Windows] Improve editor grouping, set friendly name registry key for exported projects. 2024-07-31 15:04:00 +03:00
Rémi Verschelde
8d9a394f63
Merge pull request #94958 from adamscott/fix-missing-web-nullcheck-source
Add missing null check before disconnecting source
2024-07-31 11:37:47 +02:00
Rémi Verschelde
3fce516155
Merge pull request #94428 from alvinhochun/windows-angle-resize-sync
Windows: Update ANGLE surface size when window is resized
2024-07-31 11:37:37 +02:00
bruvzg
68ae413893 [Windows] Improve video driver error messages. 2024-07-31 11:16:38 +03:00
Adam Scott
1776258b1c
Add missing null check before disconnecting source 2024-07-30 15:00:58 -04:00
Pierce Brooks
e3482a9336
Android: Ensure cleanup of all subobjects in the OpenSL audio driver 2024-07-30 17:20:46 +02:00
Rémi Verschelde
3e0c10d393
Merge pull request #94943 from bruvzg/arm64_gl_switch
[Windows] Improve OpenGL/ANGLE switching on ARM64.
2024-07-30 12:29:13 +02:00
Rémi Verschelde
862d881843
Merge pull request #94923 from m4gr3d/fix_crash_on_android_terminate
Fix crash that occurs on termination of the Godot engine on Android
2024-07-30 12:29:10 +02:00
Rémi Verschelde
a92d7ed19f
Merge pull request #94887 from m4gr3d/fix_generate_apk_for_dev_build
Automatically enable `doNotStrip` for dev builds
2024-07-30 12:29:01 +02:00
bruvzg
ad0ab2f396
[Windows] Improve OpenGL/ANGLE switching on ARM64. 2024-07-30 10:11:58 +03:00
Fredia Huya-Kouadio
30d63e8ab9 Fix the crash that occurs on termination of the Godot engine on Android 2024-07-29 09:20:50 -07:00
Fredia Huya-Kouadio
c1acddfeb4 Fix the generate_apk logic when dev_build or debug_symbols are enabled
Co-authored-by: Rémi Verschelde <rverschelde@gmail.com>
2024-07-29 06:48:49 -07:00
A Thousand Ships
61c4ce272c
[Web] Gracefully handle non-finite audio volumes 2024-07-29 15:48:06 +02:00
Rémi Verschelde
9a8f18b9bf
Merge pull request #94796 from kus04e4ek/backfall
Windows: Fall back to D3D12 if Vulkan is not supported and vice versa
2024-07-29 15:17:26 +02:00
Rémi Verschelde
65e046159b
Merge pull request #94836 from bruvzg/win7_angle
[Windows] Remove libSynchronization
2024-07-28 17:46:59 +02:00
Rémi Verschelde
8239eac5d9
Merge pull request #94809 from ChrisBase/fix_keytool_for_android_export_not_found
Fix Android export failing with custom keystores and no JDK setup in the OS environment
2024-07-28 17:46:42 +02:00
Rémi Verschelde
1d8373a300
Merge pull request #92859 from Summersay415/do-not-strip
Android: Change the way `doNotStrip` is set
2024-07-28 17:46:31 +02:00
Alvin Wong
25270d5907 Allow llvm-mingw sanitizers only on x86_32/x86_64 2024-07-28 17:21:35 +08:00
Alvin Wong
0cda0b935d Windows: Add sanitizers for llvm-mingw, increase stack for ASan
ASan and UBSan are supported by llvm-mingw. They can be enabled by
passing `use_asan=yes use_ubsan=yes` to scons.
2024-07-28 04:32:18 +08:00
Alvin Wong
28c60a5ff9 Combine existing modes when calling SetConsoleMode
Otherwise the default modes will be cleared, which causes long lines to
be truncated in some terminals (e.g. Windows Terminal).
2024-07-28 00:32:40 +08:00
bruvzg
5d5d51937f [Windows] Remove libSynchronization 2024-07-27 17:12:27 +03:00
Kusok
d30c1e6a8f Fall back to D3D12 if Vulkan is not supported and vice versa 2024-07-27 16:17:20 +08:00
Chris
7afefe6469 Fixed Android export failing when no JDK is setup in the OS environment and custom keystores have been set in the export dialog. 2024-07-27 01:33:59 +02:00
Rémi Verschelde
607b230ffe
Merge pull request #94789 from Faless/web/fix_thread_cc_with_workaround
[Web] Fix closure compiler builds, enable it in CI.
2024-07-26 13:44:25 +02:00
Rémi Verschelde
44342c385c
Merge pull request #94735 from aitorciki/nvdrs-memset-initialization
[Windows] Use default aggregate initialization for NVAPI settings
2024-07-26 13:44:13 +02:00
Rémi Verschelde
13c6c0cdb7
Merge pull request #94706 from alvinhochun/window-set-transient-parent-on-create
Pass window exclusive and transient properties for subwindow creation
2024-07-26 13:44:03 +02:00
Fabio Alessandrelli
96feb924e8 [Web] Enable the closure compiler in CI
Also fixes some JSDoc annotations in GodotAudio
2024-07-26 13:27:52 +02:00
Fabio Alessandrelli
26f17c33a5 [Web] Add workaround for missing export in threaded builds
The offending symbol gets stripped away by wasm-dce but it's used on the
JavaScript side and causes and undefined symbol which also causes the
closure compiler to throw an error.
2024-07-26 12:28:36 +02:00
Aitor Guevara
21f3e69a24 [Windows] Use default aggregate initialization for NVAPI settings
Using the member initialization encouraged in NVAPI documentation for
NVDRS_SETTING results in builds enabling `dev_mode` breaking. Default
aggregate initialization results in a clean build though.
2024-07-25 14:41:46 +02:00
alvinhochun
24e02d56cb
Remove unneeded call in DisplayServerX11
X11 does not need setting exclusive flag (it is not implemented).

Co-authored-by: bruvzg <7645683+bruvzg@users.noreply.github.com>
2024-07-25 17:11:15 +08:00
Fredia Huya-Kouadio
4d0da74014 Fix the cleanup logic for the Android render thread
On Android the exit logic goes through `Godot#onDestroy()` who attempts to cleanup the engine using the following code:

```
runOnRenderThread {
	GodotLib.ondestroy()
	forceQuit()
}
```

The issue however is that by the time we ran this code, the render thread has already been paused (but not yet destroyed), and thus `GodotLib.ondestroy()` and `forceQuit()` which are scheduled on the render thread are not executed.

To address this, we instead explicitly request the render thread to exit and block until it does. As part of it exit logic, the render thread has been updated to properly destroy and clean the native instance of the Godot engine, resolving the issue.
2024-07-24 10:17:46 -07:00