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

4279 Commits

Author SHA1 Message Date
Stuart Carnie
6e298f2b95 Renderer: Fix Metal handling of cube textures; assert equal dimensions
(cherry picked from commit e2066298d9)
2025-03-19 12:58:21 +01:00
Pāvels Nadtočajevs
aede60bdc7 [macOS/iOS] Ensure only one axis change event is produced during single process_joypads() call.
(cherry picked from commit a797c7b8e2)
2025-03-19 12:56:07 +01:00
BlueCube3310
1a379d1805 BasisUniversal: Ensure ASTC's HDR variant is supported when transcoding
(cherry picked from commit 4d46ef8e8e)
2025-03-14 00:18:49 +01:00
Evan Todd
a241eb32d4 Fix particle jitter when scene tree is paused.
(cherry picked from commit 87efa4d210)
2025-03-12 14:59:03 +01:00
Grublady
b7952c3f01 Swap Nintendo face buttons on macOS
(cherry picked from commit cdcee78fcb)
2025-03-12 14:59:03 +01:00
Frank Becker
d624c8e420 Fix gles3 gaussian_blur mipmap setup.
Extend max level to include i for writing and so fb is complete and avoid resulting errors like:
"Framebuffer is incomplete: Attachment level is not in the [base level, max level] range".

(cherry picked from commit e9bbe6fc78)
2025-03-12 14:59:03 +01:00
kleonc
2ea417648b Fix 2D quad primitive missing lighting data in GLES3 renderer
(cherry picked from commit b3769129cb)
2025-03-12 14:59:03 +01:00
Matias N. Goldberg
34ed66ec1a Add ASTC HDR format variants
(cherry picked from commit fcd785ace2)
2025-03-12 14:59:03 +01:00
Matias N. Goldberg
68d1e1052b Fix incorrect parameters passed to VMA
If the allocation is small enough that it enters the

if (p_size <= SMALL_ALLOCATION_MAX_SIZE) {} block, Godot would call
vmaFindMemoryTypeIndexForBufferInfo with the wrong parameters.

This can cause vmaFindMemoryTypeIndexForBufferInfo to potentially
misbehave on some cards or drivers.

Fixes regression introduced in #102830
Might potentially reopen #101850 (I doubt it, but it's possible)

Must be backported to 4.4

(cherry picked from commit c543c5615c)
2025-03-12 14:59:02 +01:00
Pāvels Nadtočajevs
56ba35a431 [Windows] Fix get_modified_time on locked files.
(cherry picked from commit 6597fa24a9)
2025-03-12 14:59:02 +01:00
Stuart Carnie
5312811c4d Metal: Fix SPIR-V → MSL compilation on iOS targets 2025-02-27 10:22:39 +11:00
Stuart Carnie
818afcb327 Metal: Compile MTLLibrary on demand when pipeline is created
This changes the default shader loading strategy, implemented in the
Metal driver, to compile the `MTLLibrary` on demand when the pipeline
is created, which reduces cold startup time on IPHONE target OSs.

Normally, the `MTLLibrary` is compiled from Metal source asynchronously
when Godot calls
`RenderingDeviceDriverMetal::shader_create_from_bytecode`; however, this
changes this behaviour on mobile platforms to do it on demand when the
pipeline is created, as noted in #96052, Godot will ask to create
many more shaders from bytecode than are initially required. Mobile
OSs like iOS are limited to compiling to shader libraries concurrently,
which results in a significant bottleneck.

This is not the default for macOS, as it can concurrently compile many
shaders at once, resulting in faster startup times for the Godot editor.
2025-02-25 05:32:38 +11:00
Alex
ee0cebeaad Fix modified_time on Android 2025-02-20 17:13:41 +01:00
Rémi Verschelde
cd72d26518 Merge pull request #102830 from clayjohn/vma-memory-fix
Restore using VMA to create buffers and images
2025-02-17 09:47:47 +01:00
Thaddeus Crews
b607110ad2 Merge pull request #102792 from clayjohn/varying-crash
Validate varying count when compiling shaders
2025-02-14 08:25:39 -06:00
clayjohn
d93ac5ee0c Restore using VMA to create buffers and images when we don't need to extra gpu memory tracking.
VMA handles memory allocation on certain devices better than our custom VK code, so we might as well use it

Co-authored-by: Matias N. Goldberg <dark_sylinc@yahoo.com.ar>
2025-02-13 17:40:42 -08:00
clayjohn
35100396e4 Validate varying count when compiling shaders
This avoids crashing on devices when a number of varyings greater than the device limit is used.

For now this accurately prints an error when compiling the shader, but the error text only pops up in the editor if the number of user varyings is above the limit.
2025-02-13 15:07:15 -08:00
bruvzg
f0ac8294cb [Windows] Add missing opened file check. 2025-02-13 11:18:46 +02:00
Pāvels Nadtočajevs
d5865cb962 [Unix] Fix deleting symlinks. 2025-02-07 18:57:22 +02:00
BlueCube3310
8714b36171 Fix rendering material when UV2 is compressed 2025-02-06 20:24:46 +01:00
Rémi Verschelde
50b847992d Merge pull request #101602 from stuartcarnie/metal_gpu_address
Metal: Enable GPU buffer address support
2025-02-05 11:33:50 +01:00
Thaddeus Crews
ea2770eb4f Merge pull request #101947 from Rudolph-B/Issue-101750
Add Heightfield mask to GPUParticlesCollisionHeightField3D
2025-02-04 09:04:11 -06:00
Rudolph Bester
b162c59097 Fix GPUParticlesCollisionHeightField3D adding collisions excluded by its layer_mask
Co-authored-by: Yahia Zakaria <yahiazakaria13@gmail.com>
2025-02-04 08:02:44 +02:00
Pāvels Nadtočajevs
e6e108d091 Implement get_length() for pipes. 2025-02-03 16:50:00 +02:00
bruvzg
baa33d49b1 [Windows] Fix build with MinGW 8.0.0-1. 2025-01-31 20:39:31 +02:00
Chaosus
570e59df3d Fix shader uniforms has null as default value 2025-01-31 07:35:51 +03:00
Thaddeus Crews
3ba6ac0f66 Merge pull request #102143 from MathdudeMan/shader-error
Fix: Mass property particle shader bug
2025-01-29 17:45:13 -06:00
Stuart Carnie
0a9cd5ede9 2D: Fix clip children and rendering artefacts
Fixes both GLES3 and RendererRD implementations

Closes #102147
2025-01-30 07:19:47 +11:00
MathdudeMan
964cd6525e Fix: Mass property particle shader error 2025-01-28 21:00:26 -05:00
Thaddeus Crews
808c25f453 Merge pull request #102089 from adamscott/fix-curve-texture-web
Add check for float texture linear filtering support
2025-01-28 09:03:39 -06:00
Adam Scott
60913170c6 Add check for float texture linear filtering support
Co-authored-by: Clay John <claynjohn@gmail.com>
2025-01-27 22:12:08 -05:00
Thaddeus Crews
82199a83ce Merge pull request #101998 from stuartcarnie/2d_buffer_overwrite
2D: Fix rendering artifacts when using `BackBufferCopy`.
2025-01-27 09:46:22 -06:00
Julian Todd
b5622e9f78 Initialize pa_buffer_attr.maxlength to -1 2025-01-27 07:57:57 +00:00
Stuart Carnie
2510fefebd 2D: Fix rendering artefacts when using BackBufferCopy.
Fixes both GLES3 and RendererRD implementations
2025-01-25 10:22:07 +11:00
Thaddeus Crews
802cb0fed8 Merge pull request #101909 from BlueCube3310/compat-rgtc-arr
WebGL2: Fix 2D array textures with RGTC compression not rendering
2025-01-24 09:05:36 -06:00
Matias N. Goldberg
c30eff5986 Fix performance regression introduced in #90993
PR #90993 needed to get rid of VMA_MEMORY_USAGE_AUTO_PREFER_HOST because
we no longer used vmaCreateBuffer so we could specify the allocation
callbacks.

This however resulted in the wrong memory pool being chosen, causing
signficant performance slowdown.

Indicate additional preferred flags to help VMA select the proper pool.

Fixes #101905
2025-01-24 00:08:29 -03:00
BlueCube3310
2221f6ed13 WebGL2: Fix 2D array textures with RGTC compression not rendering 2025-01-22 20:41:20 +01:00
Thaddeus Crews
604e3ab91f Merge pull request #101730 from clayjohn/GLES3-emission-half
Bake UV2 emission using half float in the compatibility backend
2025-01-20 10:05:39 -06:00
Thaddeus Crews
0d4696b472 Merge pull request #101515 from allenwp/agx-negative-optimizations
Optimize AgX tonemapper's handling of negative values
2025-01-20 10:05:38 -06:00
Thaddeus Crews
dcf4996276 Merge pull request #101159 from brandon515/compatibility_particle_shader_fix
Fix inverted `GPUParticlesCollisionHeightField3D` in compatibility renderer.
2025-01-20 10:05:24 -06:00
Brandon Haley
990612040a Implemented fix from #91219 in compatibility renderer by reversing the z
axis in the particle shader.
2025-01-18 13:32:10 -05:00
clayjohn
441fc1cba3 Baked UV2 emission using half float in the compatibility backend
The Lightmapper expects a half float image anyway, so this is both more efficient and correct
2025-01-17 16:46:31 -08:00
clayjohn
b8252196df Avoid leaking ninepatch state to other draw commands in GLES backend 2025-01-17 10:13:04 -08:00
Stuart Carnie
01b4fd3522 Metal: enable GPU buffer address support 2025-01-16 06:10:50 +11:00
Matias N. Goldberg
7b2f1e1d09 Fix union order to simplify empty initializers
This is a followup to PR #101344 (commit
0e06eb80bc).

Some of them were not an issue because Godot was initializing all
members, but they were "fixed" just in case since it could become a
problem in the future.

Valgrind was specifically complaining about HashMapData &
GlobalPipelineData.
2025-01-14 19:05:01 -03:00
Rémi Verschelde
9d2798d4aa Merge pull request #100116 from allenwp/prevent-wasapi-error-spam
Prevent WASAPI error spam when device cannot be initialized.
2025-01-14 18:29:25 +01:00
Rémi Verschelde
85b066aa78 Merge pull request #99455 from Bonkahe/IndirectMultimeshImplementation
Add indirect draw functionality to `MultiMesh`
2025-01-14 15:05:42 +01:00
thimenesup
3d92f406b2 Implement Buffer Device Address for Rendering Device Vulkan and DirectX12 2025-01-13 22:43:29 -08:00
Rémi Verschelde
643a6f15f3 Merge pull request #101510 from scgm0/OpenGL3-renderer-supports-transparent-boot-splash
OpenGL3 renderer supports transparent boot splash
2025-01-14 00:22:21 +01:00
Allen Pestaluky
c5cf73a2e7 Optimize AgX tonemapper's handling of negative values
This change improves performance of the AgX tonemapper by allowing two matrix multiplications to be combined into one. This comes at the cost of loss of color information that could be correctly interpreted as positive RGB values in the Rec. 2020 color space. Additionally, an insignificant amount of error is intentionally introduced to the input color value to prevent the need for a second max function call before log2. The final negative color clipping has been removed to allow the tonemapper to return negative RGB values, similar to other tonemappers in Godot.
2025-01-13 17:35:35 -05:00