summaryrefslogtreecommitdiffstats
path: root/core/os
Commit message (Collapse)AuthorAgeFilesLines
* Merge commit godotengine/godot@711c725cf1b641d05d6cc988a64601622e48fe4aSpartan3222024-11-153-41/+61
|\
| * Change warning muting so it affects all levels, but locallyPedro J. Estébanez2024-09-051-0/+9
| | | | | | | | (cherry picked from commit 9cbc3f14198c30c14315cabf72b0e3e3438b2f61)
| * WorkerThreadPool (plus friends): Overhaul unlock allowance zonesPedro J. Estébanez2024-09-053-41/+52
| | | | | | | | | | | | This fixes a rare but possible deadlock, maybe due to undefined behavior. The new implementation is safer, at the cost of some added boilerplate. (cherry picked from commit f4d76853b9d921e3645295f9bebc39eb73661e67)
* | Fix copyright headers referring to GodotSpartan3222024-10-2727-54/+54
| |
* | Rebrand preambles to RedotSpartan3222024-10-1327-0/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (cherry picked from commit e8542b06acca3c1bdeee4b528411771f0819f084) Credits: Co-authored-by: Skogi <skogi.b@gmail.com> Co-authored-by: Spartan322 <Megacake1234@gmail.com> Co-authored-by: swashberry <swashdev@pm.me> Co-authored-by: Christoffer Sundbom <christoffer_karlsson@live.se> Co-authored-by: Dubhghlas McLaughlin <103212704+mcdubhghlas@users.noreply.github.com> Co-authored-by: McDubh <103212704+mcdubhghlas@users.noreply.github.com> Co-authored-by: Dubhghlas McLaughlin <103212704+mcdubhghlas@users.noreply.github.com> Co-authored-by: radenthefolf <radenthefolf@gmail.com> Co-authored-by: John Knight <80524176+Tekisasu-JohnK@users.noreply.github.com> Co-authored-by: Adam Vondersaar <adam.vondersaar@uphold.com> Co-authored-by: decryptedchaos <nixgod@gmail.com> Co-authored-by: zaftnotameni <122100803+zaftnotameni@users.noreply.github.com> Co-authored-by: Aaron Benjamin <lifeartstudios@gmail.com> Co-authored-by: wesam <108880473+wesamdev@users.noreply.github.com> Co-authored-by: Mister Puma <MisterPuma80@gmail.com> Co-authored-by: Aaron Benjamin <lifeartstudios@gmail.com> Co-authored-by: SingleError <isaaconeoneone@gmail.com> Co-authored-by: Bioblaze Payne <BioblazePayne@gmail.com>
* | Rebrand Godot 4.3 to RedotTrashguy2024-10-131-1/+1
|/
* Fix Game window stops responding when debugger pausesJamie Pate2024-07-101-2/+0
| | | | | | | | | | | | | | | | | | | | | Fixes #73374 As of godot 4 On windows/osx the game window will be frozen and will not be updated. In the debugger loop it calls OS::get_singleton()->process_and_drop_events(); which allows windows/osx to handle system events. If the window doesn't handle these events then both systems will judge the window to be 'not responding' (osx beachball cursor) When the event processing code was migrated from OS to DisplayServer the process_and_drop_events() logic was moved to DisplayServer, but the call inside the remote debugger pause loop was not updated to call the DisplayServer version, there are currently no implementations of OS::process_and_drop_events() so i removed it and switched to the new DisplayServer::force_process_and_drop_events() method.
* Prevent folder names with trailing periods from being used automaticallyHugo Locurcio2024-06-261-1/+4
| | | | | | | | | Folder names ending with one or more `.` characters are not allowed on Windows, so this would break writing logs, shader cache and other project-specific files. Trailing periods are now stripped in this case. On non-Windows platforms, this change still applies in the interest of portability.
* Move MIDI parsing up from ALSA driver to platform independent driver.Ibrahn Sahir2024-06-252-67/+200
| | | | | | | | | | | | | | | | | Aims for more consistent MIDI support across Windows, MacOS, Linux and to provide a base for adding MIDI drivers for other platforms. Reworks the MIDIDriverALSAMidi MIDI parsing implementation as a platform independent version in MIDIDriver::Parser. Uses MIDIDriver::Parser to provide running status support in MacOS MIDIDriverCoreMidi. Collects connected input names at open, ensuring devices indices reported in events match names in array returned from get_connected_inputs. Fixes #77035. Fixes #79811. With code review changes by: A Thousand Ships (she/her) <96648715+AThousandShips@users.noreply.github.com>
* Add `nothreads` feature tag to signify lack of `THREADS_ENABLED`Mikael Hermansson2024-06-241-0/+4
|
* Implement `amplitude` to Input.vibrate_handheldRadiant2024-05-021-1/+1
| | | | | Co-authored-by: A Thousand Ships <96648715+AThousandShips@users.noreply.github.com> Co-authored-by: m4gr3d <m4gr3d@users.noreply.github.com>
* Add separate feature tags for editor runtimekobewi2024-04-262-0/+6
|
* Collapse the gdextension arguments into the `GDExtensionData` structFredia Huya-Kouadio2024-04-191-1/+8
| | | | This is used to reduce the number of arguments to `OS::open_dynamic_library(...)`.
* Fix loading GDExtension dependencies on AndroidFredia Huya-Kouadio2024-04-192-1/+52
|
* Add get_process_exit_code() methodkobewi2024-04-161-0/+1
|
* Merge pull request #87117 from DmitriySalnikov/rename_pdbRémi Verschelde2024-04-111-1/+1
|\ | | | | | | Add renaming of PDB files to avoid blocking them
| * Add renaming of PDB files to avoid blocking themDmitriySalnikov2024-04-051-1/+1
| |
* | Update lingering `do/while(0)` definesThaddeus Crews2024-04-041-2/+3
|/
* Implement `OS.execute_with_pipe` method to run process with redirected stdio.bruvzg2024-03-271-0/+1
| | | | Implement `pipe://*` path handling for creation of named pipes.
* Merge pull request #89229 from akien-mga/main-refactor-os-exit-codeRémi Verschelde2024-03-241-1/+2
|\ | | | | | | Refactor OS exit code to be `EXIT_SUCCESS` by default
| * Refactor OS exit code to be `EXIT_SUCCESS` by defaultRémi Verschelde2024-03-081-1/+2
| | | | | | | | | | | | | | | | | | | | | | - `Main::setup` early exits (failure or `--help`/`--version`) now consistently return `EXIT_FAILURE` or `EXIT_SUCCESS` on all platforms, instead of 255 on some and a Godot Error code on others. - `Main::start` now returns the exit code, simplifying the handling of early failures. - `Main::iteration` needs to explicit set the exit code in OS if it errors out. - Web and iOS now properly return `OS::get_exit_code()` instead of 0.
* | Fixed Timestep Interpolation (2D)Ricardo Buring2024-03-231-0/+1
| | | | | | | | | | | | | | Adds fixed timestep interpolation to the rendering server (2D only). Switchable on and off with a project setting (default is off). Co-authored-by: lawnjelly <lawnjelly@gmail.com>
* | Enforce template syntax `typename` over `class`Thaddeus Crews2024-03-073-11/+11
|/
* Merge pull request #86620 from fbcosentino/midi_device_idRémi Verschelde2024-02-192-2/+3
|\ | | | | | | Add MIDI controller device index to `InputEventMIDI.device` property.
| * Add MIDI controller device index to InputEventMIDI.device property.Fernando Cosentino2024-02-192-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | It is possible to query the OS for the connected MIDI controllers, but the event messages' device field was not being used. This implements controller index being sent in InputEventMIDI messages in the device property, matching the index from OS.get_connected_midi_inputs(). Based on the work done by @ramdor. Closes godotengine/godot-proposals#7733 Co-authored-by: Richie <richie_github@grange-lane.co.uk>
* | Add const lvalue ref to core/* container parametersMuller-Castro2024-02-144-15/+15
| |
* | Merge pull request #87635 from rune-scape/manage-time-singletonRémi Verschelde2024-02-121-3/+0
|\ \ | | | | | | | | | Manage time singleton in `register_core_types`
| * | Manage time singletonrune-scape2024-02-111-3/+0
| | |
* | | [Core] Improve `CowData` and `Memory` metadata alignment.bruvzg2024-02-052-22/+37
| | |
* | | Merge pull request #87871 from vittorioromeo/use_v_shorthandRémi Verschelde2024-02-051-4/+4
|\ \ \ | | | | | | | | Use `_v` shorthand for type traits and `if constexpr` where appropriate
| * | | Use '_v' shorthand for type traits and 'if constexpr' where appropriatevittorioromeo2024-02-021-4/+4
| | | |
* | | | Extract 'SafeBinaryMutex' to separate headervittorioromeo2024-02-042-80/+124
|/ / / | | | | | | | | | | | | | | | 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`.
* | | Merge pull request #87393 from stuartcarnie/bugfixRémi Verschelde2024-01-291-0/+21
|\ \ \ | | | | | | | | | | | | Use `os_unfair_lock` on Apple platforms
| * | | Use `os_unfair_lock` on Apple platformsStuart Carnie2024-01-211-0/+21
| | | |
* | | | Add InputEventKey.location to tell left from rightMel Collins2024-01-261-0/+6
| |/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | This adds a new enum `KeyLocation` and associated property `InputEventKey.location`, which indicates the left/right location of key events which may come from one of two physical keys, eg. Shift, Ctrl. It also adds simulation of missing Shift KEYUP events for Windows. When multiple Shifts are held down at the same time, Windows natively only sends a KEYUP for the last one to be released.
* | | Add THREADS_ENABLED macro in order to compile Godot to run on the main threadAdam Scott2024-01-177-6/+148
| | |
* | | Merge pull request #86587 from RandomShaper/wtp_enhanceRémi Verschelde2024-01-112-3/+7
|\ \ \ | |/ / |/| | | | | Enhance & fix `WorkerThreadPool`
| * | WorkerThreadPool: Overhaul scheduling and synchronizationPedro J. Estébanez2024-01-082-3/+7
| |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 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.
* / Add const references detected by clang-tidyWilson E. Alvarez2023-12-161-2/+2
|/
* Improve engine startup/shutdown benchmarksYuri Sizov2023-12-082-15/+34
| | | | | | | | | - Add contexts to give a better sense of benchmarked areas. - Add missing benchmarks and adjust some begin/end points. - Clean up names. - Improve Android's internal benchmarks in a similar manner. Co-authored-by: Fredia Huya-Kouadio <fhuya@meta.com>
* Use mingw-std-threads in MinGW buildsPedro J. Estébanez2023-11-188-27/+69
|
* [iOS, GDExtension] Fix loading and exporting static libraries and xcframeworks.bruvzg2023-11-091-0/+6
|
* Web: Clarify that `OS.get_unique_id` is not supportedRémi Verschelde2023-09-271-1/+1
| | | | | | | | Remove the base error message in `OS`, we no longer really error out this way for not implemented methods. Instead, each platform should override them to provide the context they want. Fixes #82439.
* [Core] Replace `ERR_FAIL_COND` with `ERR_FAIL_NULL` where applicableA Thousand Ships2023-09-113-11/+11
|
* Extract ScriptInstance to simplify includesYuri Sizov2023-09-061-1/+0
| | | | | | | | | This allows to include script_instance.h directly in the generated gdvirtual.gen.inc, and remove excessive includes from the codebase. This should also allow Resource to use GDVIRTUAL macros, which wasn't possible previously due to a circular dependency.
* Godot Android plugin re-architectureFredia Huya-Kouadio2023-09-031-0/+4
|
* Add missing YEN, SECTION and OPENURL names to keycode mappingsAttackButton2023-08-282-0/+5
|
* [macOS] Implement optional native file selection dialog support for ↵bruvzg2023-07-122-0/+7
| | | | sandboxed apps.
* Merge pull request #70771 from kleonc/main-loop-set-after-resolvedYuri Sizov2023-07-122-12/+0
|\ | | | | | | Ensure `MainLoop` and its custom script is set right after it's resolved
| * Ensure MainLoop and its custom script is set right after it's resolvedkleonc2022-12-312-12/+0
| |