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

1605 Commits

Author SHA1 Message Date
Thaddeus Crews
be429eb404 SCons: Make builders prettier, utilize constexpr 2025-03-11 18:31:20 -05:00
Thaddeus Crews
c8ddbfbd38 Merge pull request #102940 from bruvzg/tab_ed
Add editor setting to override tablet driver.
2025-03-11 14:00:51 -05:00
Pāvels Nadtočajevs
d990f594a0 Sync display/window/size/initial_position_type and Window::WINDOW_INITIAL_POSITION_ enum. 2025-03-11 08:33:02 +02:00
A Thousand Ships
466590d0ec Use get_slicec instead of get_slice for single character splitters 2025-03-08 20:36:37 +01:00
Ricardo Subtil
d776682741 Fix recovery mode lock file not being cleared on import/export 2025-03-08 10:58:09 +00:00
Thaddeus Crews
324512e11c Style: Replace header guards with #pragma once 2025-03-07 17:33:47 -06:00
Thaddeus Crews
67d4a245d8 Merge pull request #103267 from YeldhamDev/reality_got_too_extended
Allow to compile the engine without XR support
2025-03-07 15:12:54 -06:00
Thaddeus Crews
3c43508ed7 Merge pull request #102427 from AThousandShips/fix_substr
Clean up some uses of `String::substr`
2025-03-07 15:12:33 -06:00
Thaddeus Crews
c937b6d180 Merge pull request #102419 from Ivorforce/std-size
Use `std::size` instead of `sizeof(a) / sizeof(a[0])` pattern throughout the codebase.
2025-03-07 15:12:25 -06:00
A Thousand Ships
5113022dfe Clean up some uses of String::substr
Cases where the end position is either equvalent to the default or past
the end of the string.
2025-03-07 14:50:38 +01:00
Pāvels Nadtočajevs
6ed12bfc5d [Linux/BSD] Offload RenderingDevice creation test to subprocess. 2025-03-04 13:18:26 +02:00
Haoyu Qiu
7c8f81f1d0 Set editor's translation domain at root node 2025-03-02 08:52:27 +08:00
Michael Alexsander
aea559b39a Allow to compile the engine without XR support 2025-02-25 17:07:21 -03:00
Pāvels Nadtočajevs
ab717497ef [Windows] Offload RenderingDevice creation test to subprocess. 2025-02-24 19:40:10 +02:00
Rémi Verschelde
b77423370a Fix cross-platform configuration of rendering driver settings
Simpler alternative to #103026 which avoids breaking compatibility.

Instead of introducing a new `auto` default value, we ensure that all
supported drivers are registered regardless of the editor's host platform,
and that the defaults are the intended ones.

This solves the following issues:
- macOS exports are meant to default to Metal in 4.4, but they would
  default to Vulkan if exported from Linux, Windows, or Android editors.
- Windows exports couldn't be made with Direct3D 12 from Linux, macOS, or
  Android editors, as the option couldn't be selected outside Windows.

Unlike #103026, it doesn't solve the issue of not always saving the
rendering drivers to `project.godot`, but now the defaults are at least
consistent between editor platforms.

Co-authored-by: Pāvels Nadtočajevs <7645683+bruvzg@users.noreply.github.com>
2025-02-23 12:28:59 +01:00
Rémi Verschelde
11f56d8265 Revert "Always allow selecting any rendering driver in the settings, add "auto" option."
This reverts commit dea20c4a9b.

This had unforeseen consequences for editor code that relies on querying these settings,
and possibly thirdparty code that would do the same. In hindsight, it's a bit too late
in the release cycle to make such a compatibility breaking change.
2025-02-23 12:19:20 +01:00
Pāvels Nadtočajevs
dea20c4a9b Always allow selecting any rendering driver in the settings, add "auto" option. 2025-02-19 12:05:04 +02:00
Pāvels Nadtočajevs
b3c0eaeeb8 Add editor setting to override tablet driver. 2025-02-15 23:16:58 +02:00
bruvzg
3f2a29cd9d [Windows] Read Wacom config to check if Windows Ink is disabled and auto switch to WinTab. 2025-02-13 15:10:16 +02:00
Thaddeus Crews
f45d2f8f6c Merge pull request #96926 from Dowsley/user-provided-arguments-fix
Ignore `--test` flag when it is an user-provided argument
2025-02-12 12:56:41 -06:00
Hilderin
9457666bba Fix accessing UID before first scan 2025-02-08 20:04:32 -05:00
Lukas Tenbrink
e34f1f504c Use std::size instead of sizeof(a) / sizeof(a[0]) pattern throughout the codebase. 2025-02-07 14:57:48 +01:00
J. F. Dowsley
d481669c50 Ignore --test flag when it is an user-provided argument 2025-02-06 12:25:50 -03:00
Thaddeus Crews
86002e1a3c Merge pull request #100882 from smix8/node_navmesh_geo_parsers
Make nodes handle their respective navigation source geometry
2025-01-16 17:18:01 -06:00
Thaddeus Crews
97fa4bdfdc Merge pull request #101540 from akien-mga/vulkan-disable-layer-bandicam
Vulkan: Force disable broken `VK_LAYER_bandicam_helper` layer in editor
2025-01-16 17:17:57 -06:00
Pāvels Nadtočajevs
934668a69a Fix project manager window size when EDSCALE is not 1.0. 2025-01-15 12:39:02 +02:00
Rémi Verschelde
210e9d733f Vulkan: Force disable broken VK_LAYER_bandicam_helper layer in editor
Fixes #101480.
2025-01-14 21:28:21 +01:00
smix8
0ed2cb0439 Make nodes handle their respective navigation source geometry
Makes nodes handle their respective navigation source geometry.
2025-01-12 13:14:46 +01:00
Rémi Verschelde
33fb876ebb Merge pull request #101321 from YeldhamDev/project_manager_warn_silence
Change print warnings to config ones for popups that need transparency
2025-01-11 22:29:48 +01:00
Hugo Locurcio
cc86322d8d Increase the project manager's default window size
This makes the project manager feel less cramped when many
projects are imported, or when browsing templates in the asset library.

On displays smaller than 1152x800 (e.g. 1366x768), window height is
automatically limited by DisplayServer when setting the window size.

This also tweaks splash screen size when starting the project manager
to match the project manager's default window size, and allows the
`--resolution` and `--position` CLI arguments to affect the project
manager.

Lastly, this increases the minimum width slightly to prevent the UI
from being cut off with the default theme.
2025-01-11 18:25:24 +01:00
Pāvels Nadtočajevs
65f94b163a Fallback to primary screen if no window layout is saved in project metadata. 2025-01-10 09:06:28 +02:00
Michael Alexsander
5c63646e87 Change print warnings to config ones for popups that need transparency 2025-01-09 15:59:56 -03:00
Aarni Koskela
f134769506 Fix various typos
* Add TODO notes for typos that should be fixed for 5.0

Co-authored-by: Rémi Verschelde <rverschelde@gmail.com>
2025-01-08 14:47:42 +02:00
AThousandShips
a6c70576be [Main] Fix missing performance data
Also future-proof entries to ensure size.
2025-01-07 20:04:26 +01:00
Pāvels Nadtočajevs
3d60ce9389 [Export] Allow using ICU data from export templates instead of editor embedded data. 2025-01-07 08:15:09 +02:00
Ricardo Subtil
b77aa473a1 Implement a "Recovery Mode" for recovering crashing/hanging projects during initialization 2025-01-03 10:50:15 +00:00
Rémi Verschelde
b34adf29dc Remove unused OS _display_driver_id member 2025-01-03 01:52:25 +01:00
Rémi Verschelde
0d710da96c Merge pull request #98554 from Calinou/add-property-hint-ranges
Add more property hint ranges for project settings
2025-01-03 00:47:59 +01:00
A Thousand Ships
a1846b27ea Improve use of Ref.is_null/valid
Use `is_null` over `!is_valid` and vice versa.
2024-12-23 16:35:02 -05:00
Hugo Locurcio
62c17911ea Add more property hint ranges for project settings
- Tweak property hint ranges for some networking settings to ensure
  the minimum values don't break the debugger entirely.
- Ensure shader time rollover is set to at least 1, as 0 causes a division by
  zero to occur.

All relevant project settings are now covered by a range hint.
2024-12-23 18:22:32 +01:00
Rémi Verschelde
fd5548a8b7 Merge pull request #100634 from YYF233333/iwyu2
Remove unused headers in servers
2024-12-20 23:57:09 +01:00
Rémi Verschelde
a11364d1e6 Merge pull request #99010 from Hilderin/embedding-game-process
Embed game process in editor
2024-12-20 23:56:43 +01:00
Yufeng Ying
e88e30c273 Remove unused headers in servers.
Co-authored-by: bruvzg <7645683+bruvzg@users.noreply.github.com>
2024-12-20 18:51:01 +08:00
Hilderin
9d2a4c03be Embedding game process in editor 2024-12-18 17:52:42 -05:00
Yufeng Ying
be86ce3103 Apply iwyu suggestion in core. 2024-12-19 00:43:47 +08:00
kobewi
62d4928e86 Improve UID support for main scene 2024-12-16 19:58:16 +01:00
Rémi Verschelde
d1b683d413 Merge pull request #97140 from BastiaanOlij/xr_action_map_enhancements
OpenXR: Add support for binding modifiers
2024-12-12 14:09:41 +01:00
Thaddeus Crews
23afda44e4 Merge pull request #100257 from darksylinc/matias-minimize-leak
Keep processing Graphics if there are pending operations
2024-12-11 17:35:35 -06:00
Bastiaan Olij
0a61ebdcea OpenXR: Add support for binding modifiers 2024-12-12 09:46:19 +11:00
Matias N. Goldberg
acf439e96d Keep processing Graphics if there are pending operations
Fixes #90017
Fixes #90030
Fixes #98044

This PR makes the following changes:

# Force processing of GPU commands for frame_count frames

The variable `frames_pending_resources_for_processing` is added to track
this.

The ticket #98044 suggested to use `_flush_and_stall_for_all_frames()`
while minimized.

Technically this works and is a viable solution.

However I noticed that this issue was happening because Logic/Physics
continue to work "business as usual" while minimized(\*). Only Graphics
was being deactivated (which caused commands to accumulate until window
is restored).

To continue this behavior of "business as usual", I decided that GPU
work should also "continue as usual" by buffering commands in a double
or triple buffer scheme until all commands are done processing (if they
ever stop coming). This is specially important if the app specifically
intends to keep processing while minimized.

Calling `_flush_and_stall_for_all_frames()` would fix the leak, but it
would make  Godot's behavior different while minimized vs while the
window is presenting.

\* `OS::add_frame_delay` _does_ consider being minimized, but it just
throttles CPU usage. Some platforms such as Android completely disable
processing because the higher level code stops being called when the app
goes into background. But this seems like an implementation-detail that
diverges from the rest of the platforms (e.g. Windows, Linux & macOS
continue to process while minimized).

# Rename p_swap_buffers for p_present

**This is potentially a breaking change** (if it actually breaks
anything, I ignore. But I strongly suspect it doesn't break anything).

"Swap Buffers" is a concept carried from OpenGL, where a frame is "done"
when `glSwapBuffers()` is called, which basically means "present to the
screen".

However it _also_ means that OpenGL internally swaps its internal
buffers in a double/triple buffer scheme (in Vulkan, we do that
ourselves and is tracked by `RenderingDevice::frame`).

Modern APIs like Vulkan differentiate between "submitting GPU work" and
"presenting".

Before this PR, calling `RendererCompositorRD::end_frame(false)` would
literally do nothing. This is often undesired and the cause of the leak.
After this PR, calling `RendererCompositorRD::end_frame(false)` will now
process commands, swap our internal buffers in a double/triple buffer
scheme **but avoid presenting to the screen**.

Hence the rename of the variable from `p_swap_buffers` to `p_present`
(which slightly alters its behavior).
If we want `RendererCompositorRD::end_frame(false)` to do nothing, then
we should not call it at all.

This PR reflects such change: When we're minimized **_and_**
`has_pending_resources_for_processing()` returns false, we don't call
`RendererCompositorRD::end_frame()` at all.

But if `has_pending_resources_for_processing()` returns true, we will
call it, but with `p_present = false` because we're minimized.

There's still the issue that Godot keeps processing work (logic,
scripts, physics) while minimized, which we shouldn't do by default. But
that's work for follow up PR.
2024-12-11 14:13:29 -03:00