Commit Graph

4034 Commits

Author SHA1 Message Date
Adam Scott
0d350e7108
Set clang-format RemoveSemicolon rule to true
- Set clang-format `Standard` rule to `c++20`
2024-10-25 13:49:43 -04:00
Yuri Rubinsky
6732a0fd86
Merge pull request #98448 from Chaosus/shader_global_builtins
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
Make `OUTPUT_IS_SRGB/CLIP_SPACE_FAR` shader built-ins global
2024-10-25 13:55:14 +03:00
Clay John
a1c7998d5f
Merge pull request #98305 from cadence-s/fix-ios-audio-driver-error
Fix iOS audio driver attempting to start output too early
2024-10-24 19:40:34 -07:00
Thaddeus Crews
cfc05c5e0f
Merge pull request #85338 from EMBYRDEV/shadow-caster-mask
Add `shadow_caster_mask` to Light3D.
2024-10-24 13:22:59 -05:00
Chaosus
463e81413e Make OUTPUT_IS_SRGB/CLIP_SPACE_FAR shader built-ins global 2024-10-24 12:32:05 +03:00
Thaddeus Crews
7815ccbdd5
Merge pull request #98294 from Calinou/texture-placeholders-use-shared-copy
Use a shared copy of placeholder textures, tweak placeholder appearance
2024-10-21 16:39:29 -05:00
Thaddeus Crews
a14e9e99e5
Merge pull request #98388 from DarioSamo/sync-fixes
Improve synchronization of rendering after changes from transfer queues.
2024-10-21 16:39:21 -05:00
Thaddeus Crews
291e4b78e2
Merge pull request #98237 from dustdfg/os_transitive_image_headers_refactor
Don't include `core/io/image.h` in `core/os/os.h`
2024-10-21 16:39:15 -05:00
Thaddeus Crews
4630cbc487
Merge pull request #98212 from stuartcarnie/sgc/metal_improvements
Metal: Performance improvements and bug fixes
2024-10-21 16:39:09 -05:00
Dario
4ad424234f Improve synchronization of rendering commands after changes from transfer queues.
Fix an error where barriers are expected to be inserted for the swap chain textures.
Add the relevant synchronization stages and accesses to resources between frames.
Fix an error where debug labels weren't finished correctly between frames.
Breadcrumbs are now behind an optional macro as they currently lead to synchronization errors which are harmless.
2024-10-21 11:27:56 -03:00
Stuart Carnie
83ac274e25
Metal: Performance improvements and bug fixes 2024-10-20 11:15:13 +11:00
Cadence
b4fd9d1f38 Fix iOS audio driver attempting to start output too early 2024-10-18 13:05:30 -04:00
Yevhen Babiichuk (DustDFG)
af6d260c17 Don't include core/io/image.h in core/os/os.h
`core/os/os.h` doesn't use `core/io/image.h`. It just brings
transitive dependencies. Lots of dependencies because `core/os/os.h`
is transitively included in almost every file of godot

Also added `core/io/image.h` into files^1 where `Ref<Image>` and `core/os/os.h`
were used to prevent obscure errors involving `Ref<Image>`

^1 except those which include `core/io/image_loader.h` or `core/io/image.h` by
corresponding .h file with the same name

Signed-off-by: Yevhen Babiichuk (DustDFG) <dfgdust@gmail.com>
Co-authored-by: A Thousand Ships <96648715+AThousandShips@users.noreply.github.com>
2024-10-18 19:04:19 +03:00
Hugo Locurcio
35a20fa96a Use a shared copy of placeholder textures, tweak placeholder appearance
This reduces memory usage a bit in case multiple placeholders were
requested, e.g. when using multiple NoiseTextures with no noise property
defined.

The placeholder texture's appearance was also changed from a plain magenta
color to a checkerboard alternating between magenta and black pixels.
This makes it easier to spot when the placeholder texture ends up
being used in a complex scene (usually by accident).
The texture's dimensions remain identical to keep the physical size
identical in 2D.
2024-10-18 14:51:51 +02:00
Dario
8c3e46b13b Move transitions of textures initialized by transfer workers to the main graphics queue.
Also adds a new possible texture layout and API trait to support a particular behavior in D3D12 where only the COMMON layout is supported in copy queues. Fixes #98158.
2024-10-18 09:15:25 -03:00
Thaddeus Crews
bb20444998
Merge pull request #97744 from Nazarwadim/use_local_vector_for_skeleton
Use `LocalVector` for skeleton
2024-10-10 18:13:19 -05:00
Thaddeus Crews
16dfaa5e80
Merge pull request #94952 from alvinhochun/angle-d3d11-flip-y
Optimize ANGLE on D3D11 to remove an extra blit
2024-10-10 18:13:17 -05:00
Thaddeus Crews
a44f691fc7
CI: Add MinGW/GCC build to Windows GHA 2024-10-10 10:10:55 -05:00
Clay John
842f982397
Merge pull request #96819 from clayjohn/GLES3-instance-uniforms
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
Implement instance uniforms in Compatibility renderer
2024-10-07 13:41:47 -06:00
Clay John
e7c39efdb1
Merge pull request #97309 from kroketio/metal-expose-device-handle
Metal: expose MTLDevice
2024-10-07 11:00:53 -06:00
Rémi Verschelde
c46d1e4540
Merge pull request #97552 from dustdfg/drivers/use_dedicated_print_error
Use dedicated `print_error` method for colored output for unsupported drivers
2024-10-04 17:18:14 +02:00
Rémi Verschelde
f032af7453
Merge pull request #97304 from kroketio/metal-return-logical-device-handle
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
Metal: Implement `texture_create_from_extension`
2024-10-04 12:58:38 +02:00
Rémi Verschelde
6e03910578
Merge pull request #97719 from bruvzg/cross_dev_rename
[Linux/BSD] Fix cross-device rename.
2024-10-04 11:21:58 +02:00
Dario
e2c6daf7ef Implement asynchronous transfer queues, thread guards on RenderingDevice. Add ubershaders and rework pipeline caches for Forward+ and Mobile.
- Implements asynchronous transfer queues from PR #87590.
- Adds ubershaders that can run with specialization constants specified as push constants.
- Pipelines with specialization constants can compile in the background.
- Added monitoring for pipeline compilations.
- Materials and shaders can now be created asynchronously on background threads.
- Meshes that are loaded on background threads can also compile pipelines as part of the loading process.
2024-10-02 15:11:58 -03:00
Nazarii
1ba168fcbc Use local vector for skeleton 2024-10-02 20:38:40 +03:00
Rémi Verschelde
2bd0fd8e3d
Merge pull request #97676 from clayjohn/GLES3-sky-quality
Improve the look of radiance map in Compatibility backend
2024-10-02 15:01:20 +02:00
bruvzg
4cc9d2f437
[Linux/BSD] Fix cross-device rename. 2024-10-02 08:57:37 +03:00
Rémi Verschelde
6c133054f7
Merge pull request #97602 from patowen/fix-region-filter-clip-enabled
Fix `region_filter_clip_enabled` to avoid sprite bleeding for interpolated sprite sheets
2024-10-01 17:31:17 +02:00
Gergely Kis
146ba4106f Move Vulkan includes to a central godot_vulkan.h header
Also fixes Vulkan build problem with recent Clang.
2024-09-29 17:53:18 +02:00
Patrick Owen
d720eb80e1 Clamp UV-coordinates to centers of outermost texels when configured to do so
In addition, fix region_filter_clip_enabled documentation to be consistent with AtlasTexture.xml, since that is the option whose behavior was fixed
2024-09-29 05:57:19 -04:00
clayjohn
4f674154d9 Improve the look of radiance map in Compatibility backend 2024-09-29 01:33:14 -07:00
ywmaa
0a9ad8f9de
Implement vertex shading
This adds support in all backends, but the Compatibility renderer works the best.
Mobile and Forward+ can only support one directional light shader (the first in the tree)
While the Compatibility renderer supports any number of shadows.

Co-authored-by: Clay John <claynjohn@gmail.com>
2024-09-29 00:36:09 +02:00
Yevhen Babiichuk (DustDFG)
4c5094a2fe Use dedicated print_error method for colored output for unsupported drivers
Signed-off-by: Yevhen Babiichuk (DustDFG) <dfgdust@gmail.com>
2024-09-27 20:30:51 +03:00
Rémi Verschelde
a4c1804cab
Merge pull request #97483 from akien-mga/clang-format-19.1.0
CI: Update `clang-format` pre-commit hook to 19.1.0
2024-09-26 12:46:04 +02:00
Rémi Verschelde
ef7547384c
Merge pull request #95678 from Hilderin/fix-slow-load-on-large-project-v2
Fix slow editor load on large projects (v2)
2024-09-26 12:45:31 +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
Hilderin
21f7c8a25f Fix slow editor load on large projects (v2) 2024-09-25 17:36:39 -04:00
Thaddeus Crews
9f9ee0c813
SCons: Add unobtrusive type hints in SCons files 2024-09-25 09:34:35 -05:00
Rie
5efa6ba489
Fix incorrect Reinhard tonemap operator 2024-09-25 12:34:23 +02:00
Rémi Verschelde
c3e16cda00
Merge pull request #97379 from clayjohn/webgl-errors
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
Clean up two recently introduced WebGL errors
2024-09-24 12:57:21 +02:00
clayjohn
0305e437ff Clean up two recently introduced WebGL errors 2024-09-23 12:18:33 -07:00
Sander
e9c85be76f Metal: expose DRIVER_RESOURCE_LOGICAL_DEVICE for get_resource_native_handle() 2024-09-22 03:19:06 +03:00
Sander
0ad1820b1a Metal: implement texture_create_from_extension
Parameters p_type, p_format, p_array_layers, p_depth_stencil are
ignored - MTLTexture (and the callee) already have this information
and is only relevant when reinterpreting or remaping the texture in
different ways.
2024-09-22 02:32:37 +03:00
Rémi Verschelde
5f5c690481
Merge pull request #97260 from clayjohn/pixel_snap
Calculate pixel snap in canvas space instead of world space
2024-09-21 11:50:52 +02:00
clayjohn
e75900e1ad Calculate pixel snap in canvas space instead of world space
This ensures that you are actually snapping to pixels in the viewport and not an arbitrary amount
2024-09-20 17:43:33 -07:00
David Snopek
1a6f8512bc Add external texture support (GLES3)
Co-authored-by: Fredia Huya-Kouadio <fhuyakou@gmail.com>
Co-authored-by: Mauricio Narvaez <nvz@meta.com>
2024-09-20 10:48:32 -05:00
Rémi Verschelde
34dd5e0c37
Merge pull request #97217 from stuartcarnie/97185_subpixel_rendering
Metal: Fix subpixel blending; fix inconsistent blend state
2024-09-20 16:07:03 +02:00
Thaddeus Crews
b37fc1014a
Style: Apply new clang-format changes 2024-09-20 08:09:48 -05:00
Stuart Carnie
e826ab9ba9
[2D,Metal]: Fix subpixel blending; fix inconsistent blend state in Metal 2024-09-20 15:16:31 +10:00
Rémi Verschelde
b1b4c5da4b
Merge pull request #96928 from dsnopek/rename-and-expose-texture-create-external
Expose a function to create textures from a native handle in the compatibility renderer
2024-09-19 17:13:27 +02:00