Commit graph

582 commits

Author SHA1 Message Date
Thaddeus Crews
5316d12588
Merge pull request #109346 from bruvzg/win_drv_chk
[Windows] Try reading GPU driver information directly from registry.
2025-09-16 09:48:52 -05:00
Pāvels Nadtočajevs
274f88c5b8
[Windows] Fix color picker on old versions of Windows 10. 2025-08-18 09:23:31 +03:00
Pāvels Nadtočajevs
9f8626ccaa
[Windows] Try reading GPU driver information directly from registry. 2025-08-06 08:01:05 +03:00
Nintorch
0b3496fb4f
Add support for SDL3 joystick input driver
Made possible by EIREXE, xsellier and the SDL team.

This commit includes statically linked SDL3 for Windows, Linux and macOS.
The vendored copy of SDL3 was setup to only build the required subsystems
for gamepad/joystick support, with some patches to be able to make it as
minimal as possible and reduce the impact on binary size and code size.

Co-authored-by: Álex Román Núñez <eirexe123@gmail.com>
Co-authored-by: Xavier Sellier <xsellier@gmail.com>
Co-authored-by: Rémi Verschelde <rverschelde@gmail.com>
2025-06-25 01:28:50 +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
Pāvels Nadtočajevs
98f377d9d0
Use system timer/wait functions for frame delay when screen reader is active. 2025-06-04 13:44:02 +03:00
Pāvels Nadtočajevs
617e12a6b4
[Windows] Drop support for Windows 7/8/8.1. 2025-05-30 17:30:23 +03:00
uno1982
d79258c2e7 Fix: Windows OS.get_unique_id() null termination issue
use ascii for encoding-neutral
check buffer size as well
2025-05-23 15:05:41 -05:00
Pedro J. Estébanez
820380817a Exclude RD creation test functions from templates 2025-05-15 10:12:38 +02:00
Pedro J. Estébanez
53bee4eb56 Windows: Restrict time API use to the desktop flavor 2025-05-15 10:12:16 +02:00
jss2a98aj
2e61c7773b Fix OS_Windows::get_video_adapter_driver_info() 2025-04-18 19:11:40 -04:00
A Thousand Ships
889410dcda
Add String::replace_char(s) methods for performance and convenience 2025-04-10 13:08:45 +02:00
Thaddeus Crews
207a2b6472
Core: Integrate warning suppression macro helpers 2025-04-03 10:13:46 -05:00
bruvzg
48bfe13e4f
Add methods to decode/encode multibyte encodings. 2025-03-28 17:32:34 +02:00
Lukas Tenbrink
a23f630781 Remove String clipping constructors.
Callers should instead call constructors with explicit encoding names, with known length `Span`.
2025-03-15 12:34:44 +01:00
Aaron Franke
97ee05e9b7
Rename version defines to GODOT_VERSION_* to match GDExtension godot-cpp 2025-03-12 11:11:38 -07:00
A Thousand Ships
331a43a9d8
Add String::remove_char(s) methods for performance and convenience 2025-03-10 13:19:28 +01:00
Thaddeus Crews
2324805fdc
Merge pull request #103773 from Calinou/windows-low-processor-mode-sleep-cpu
Use more efficient sleep approach on Windows when low-processor mode is enabled
2025-03-09 09:05:27 -05: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
Hugo Locurcio
03b4e0dd58
Use more efficient sleep approach on Windows when low-processor mode is enabled
This aims to fix the idle CPU utilization regression from 4.3 to 4.4
by reverting to the previous approach, but only when low-processor mode
is enabled.
2025-03-07 18:06:41 +01:00
Pāvels Nadtočajevs
6ed12bfc5d [Linux/BSD] Offload RenderingDevice creation test to subprocess. 2025-03-04 13:18:26 +02:00
Pāvels Nadtočajevs
ddd807ff7d Add (void *) cast directly to GetProcAddress calls. 2025-02-27 12:30:04 +02:00
Pāvels Nadtočajevs
ab717497ef [Windows] Offload RenderingDevice creation test to subprocess. 2025-02-24 19:40:10 +02: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
NOLogicalSense
b38103e95d Windows: Normalize slashes in return of OS.get_temp_dir() 2025-01-30 22:02:20 +01:00
Ricardo Subtil
b77aa473a1 Implement a "Recovery Mode" for recovering crashing/hanging projects during initialization 2025-01-03 10:50:15 +00:00
Thaddeus Crews
9300c2bdc9
Merge pull request #100400 from CrabNickolson/windows-thread-names
Add support for thread naming on windows platform
2024-12-19 19:59:41 -06:00
Hugo Locurcio
928982891e Add OS.get_version_alias() to return a human-readable Windows/macOS version number
Windows 11's major version number is actually 10.x.x, which can be confusing
if you don't know about this quirk. `OS.get_version_alias()` avoids this
by displaying the "branding" version number and the build number as a suffix,
so that individual updates can still be distinguished from each other.

On macOS, `OS.get_version_alias()` returns the version number prepended
with the version name (e.g. Sequoia for macOS 15).

On other operating systems, this returns the same value as `OS.get_version()`.
2024-12-14 18:47:50 +01:00
Ramón Grill
d848835f8c Add support for thread naming on windows platform 2024-12-14 14:42:39 +01:00
Thaddeus Crews
a607bca2fd
Merge pull request #100024 from Ivorforce/optimize-string-single-char
Optimize string single char contains calls.
2024-12-09 14:33:24 -06:00
Lukas Tenbrink
b5c31ebb41 Add contains_char() for single-character 'contains' calls. 2024-12-06 20:23:35 +01:00
Ross Rothenstine
35faf99755 windows: Fix underflow before delay_usec 2024-12-04 23:54:53 -08:00
Thaddeus Crews
156bc92282
Merge pull request #98397 from adamscott/add-tmp-support
Add temp utilities (alias `OS::get_temp_dir()`, `FileAccess::create_temp()`, and `DirAccess::create_temp()`)
2024-12-03 14:40:59 -06:00
Adam Scott
1b3e483899
Add file and dir temporary utilities
Co-authored by @Alex2782 for the Android bindings.
Many thanks to the reviewers also.

Co-authored-by: Alex <alex.hart.278@gmail.com>
2024-12-02 12:08:14 -05:00
mrsaturnsan
b57ceefec1 [Windows] Improve frame pacing by busy waiting as needed 2024-11-29 14:04:18 +01:00
Thaddeus Crews
0045b1a513
Merge pull request #98862 from HuntJSparra/early-projsettings-registration
Register Engine, OS, ProjectSettings, and Time singletons in time for for `INITIZATION_LEVEL_CORE`
2024-11-26 13:04:51 -06:00
Thaddeus Crews
0d88737a9f Merge pull request #99542 from bruvzg/stdin_str
Convert line breaks to `\n` and strip line break from the end of string returned by `OS::read_string_from_stdin`/`OS::get_stdin_string`.
2024-11-25 13:22:30 -06:00
Rémi Verschelde
8e1a6ea431
Revert "Make delay_usec more precise"
This reverts commit df3367f334.

Fixes #99593.
2024-11-25 19:43:21 +01:00
Pāvels Nadtočajevs
e9b57fce82 Convert line breaks to \n and strip line break from the end of string returned by OS::read_string_from_stdin/OS::get_stdin_string. 2024-11-23 15:11:50 +02:00
Hunt J. Sparra
48fbe4172b Register Engine, OS, ProjectSettings, and Time early. 2024-11-21 18:09:03 -05:00
Thaddeus Crews
449d90b64e
Merge pull request #99178 from mrsaturnsan/windows_sleep_precision
Make `delay_usec` more precise on Windows to fix framepacing
2024-11-18 09:23:50 -06:00
Thaddeus Crews
1dcb686325
Merge pull request #99026 from Faless/net/split_ip
[Net] Split Unix/Windows IP implementation
2024-11-18 09:23:43 -06:00
bruvzg
8bb3e5360e Disable Nahimic code injection. 2024-11-18 13:00:55 +02:00
mrsaturnsan
df3367f334 Make delay_usec more precise
Comment fix
2024-11-16 09:15:46 -06:00
Pāvels Nadtočajevs
287b7543a0 Fix 32-bit Windows build. 2024-11-15 15:49:08 +02:00
Thaddeus Crews
179321a0a3
Merge pull request #91201 from bruvzg/con_type
[OS] Add functions to determine standard I/O device type.
2024-11-12 12:13:12 -06:00
Thaddeus Crews
190670d16b
Merge pull request #99107 from RandomShaper/win_less_inheritance
Windows: Avoid child processes inheriting all file handles
2024-11-12 12:13:06 -06:00
Fabio Alessandrelli
168a2a1466 [Net] Split Unix/Windows IP implementation 2024-11-12 17:33:47 +01:00
Thaddeus Crews
cb286da1dd
Merge pull request #99112 from bruvzg/get_model_name
Implement `get_model_name` on macOS and Windows.
2024-11-12 09:27:52 -06:00
Pedro J. Estébanez
7fcf3c491d Windows: Avoid child processes inheriting all file handles 2024-11-12 12:25:28 +01:00